支持功能:
1. 视频播放速度调整
2. 视频声音调整
3. 视频当前播放帧截帧(用的ffmpeg 怎么装自己百度去,截取准确度很高,QT自带的截帧那玩意信号不触发,不好使)
4. 视频暂停文章来源地址https://www.toymoban.com/news/detail-595904.html
# !/usr/bin/env python3
# -*- coding: UTF-8 -*-
"""
@author : v_jiaohaicheng@baidu.com
@des :
"""
import uuid
import sys
import subprocess
import traceback
from PyQt5.QtCore import QUrl
from PyQt5.QtGui import QImage, QPainter, QPixmap
from PyQt5.QtWidgets import QApplication, QMainWindow, QWidget, QVBoxLayout, QHBoxLayout, QLabel, QSlider, QPushButton, \
QFileDialog
from PyQt5.QtMultimedia import QMediaPlayer, QMediaContent
from PyQt5.QtMultimediaWidgets import QVideoWidget
class VideoPlayer(QMainWindow):
def __init__(self):
super().__init__()
self.setWindowTitle("视频播放器")
self.setGeometry(100, 100, 800, 600)
self.player = QMediaPlayer(self)
self.video_widget = QVideoWidget(self)
self.speed_con = 1
self.player.setVideoOutput(self.video_widget)
main_layout = QVBoxLayout()
controls_layout = QHBoxLayout()
self.play_button
文章来源:https://www.toymoban.com/news/detail-595904.html
到了这里,关于ChatGpt+人工修正 PyQt5 实现简易视频播放器的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!