PonyPlayer
DecoderImpl< Video >类 参考

#include <forward.hpp>

类 DecoderImpl< Video > 继承关系图:
DecoderImpl< Common > DecoderContext IDemuxDecoder

Public 成员函数

 DecoderImpl (AVStream *vs, TwinsBlockQueue< AVFrame * > *queue)
 
VideoFrameRef getPicture () override
 
 ~DecoderImpl () override
 
- Public 成员函数 继承自 DecoderImpl< Common >
 DecoderImpl (AVStream *vs, TwinsBlockQueue< AVFrame * > *queue)
 
PONY_THREAD_SAFE double duration () override
 
 PONY_GUARD_BY (DECODER) bool accept(AVPacket *pkt
 
 PONY_GUARD_BY (DECODER) void flushFFmpegBuffers() override
 
 if (ret< 0)
 
 while (ret >=0 &&!interrupt)
 
PONY_THREAD_SAFE VideoFrameRef getPicture () override
 
PONY_THREAD_SAFE AudioFrame getSample () override
 
PonyAudioFormat getInputFormat () override
 
void setOutputFormat (const PonyAudioFormat &format) override
 
PONY_THREAD_SAFE qreal viewFront () override
 
PONY_THREAD_SAFE int skip (const std::function< bool(qreal)> &predicate) override
 
PONY_THREAD_SAFE void setEnable (bool b) override
 
- Public 成员函数 继承自 DecoderContext
 DecoderContext (AVStream *vs)
 
 ~DecoderContext ()
 
- Public 成员函数 继承自 IDemuxDecoder
virtual bool accept (AVPacket *pkt, std::atomic< bool > &interrupt)=0
 
virtual void flushFFmpegBuffers ()=0
 
virtual ~IDemuxDecoder ()=default
 
virtual void setFollower (IDemuxDecoder *follower)
 
virtual void pushFrameStack ()
 
virtual qreal getLastPts ()
 
virtual void clearFrameStack ()
 
virtual void setStart (qreal secs)
 
virtual qreal nextSegment ()
 

额外继承的成员函数

- Public 类型 继承自 IDemuxDecoder
enum class  DecoderType { Audio , Video , Common }
 
- Public 属性 继承自 DecoderImpl< Common >
std::atomic< bool > &interrupt override
 
int ret
 
return false
 
- Public 属性 继承自 DecoderContext
AVCodec * codec = nullptr
 
AVStream * stream = nullptr
 
AVCodecContext * codecCtx = nullptr
 
AVFrame * frameBuf = nullptr
 
- Protected 属性 继承自 DecoderImpl< Common >
TwinsBlockQueue< AVFrame * > * frameQueue
 

详细描述

视频解码器实现

构造及析构函数说明

◆ DecoderImpl()

DecoderImpl< Video >::DecoderImpl ( AVStream *  vs,
TwinsBlockQueue< AVFrame * > *  queue 
)
inline

◆ ~DecoderImpl()

DecoderImpl< Video >::~DecoderImpl ( )
inlineoverride

成员函数说明

◆ getPicture()

VideoFrameRef DecoderImpl< Video >::getPicture ( )
inlineoverridevirtual

获取视频帧并从队列中删除, 仅当当前解码器是视频解码器时有效

参数
b是否阻塞
返回
视频帧, 请用 isValid 判断是否有效

实现了 IDemuxDecoder.


该类的文档由以下文件生成: