Miam-Player  0.8.0
A nice music player
QtAV::SubtitleFilter Class Reference

The SubtitleFilter class draw text and image subtitles Subtitle load priority: user specified file (setFile(...)) > auto load external (autoLoad() must be true) > embedded subtitle. More...

#include <SubtitleFilter.h>

Inheritance diagram for QtAV::SubtitleFilter:
QtAV::VideoFilter QtAV::SubtitleAPIProxy QtAV::Filter

Public Slots

void setAutoLoad (bool value)
 
- Public Slots inherited from QtAV::Filter
void setEnabled (bool enabled=true)
 

Signals

void rectChanged ()
 
void fontChanged ()
 
void colorChanged ()
 
void autoLoadChanged (bool value)
 
void fileChanged ()
 
void canRenderChanged ()
 
void loaded (const QString &path)
 
void codecChanged ()
 
void enginesChanged ()
 
void fuzzyMatchChanged ()
 
void contentChanged ()
 
void dirsChanged ()
 
void suffixesChanged ()
 
void supportedSuffixesChanged ()
 
void engineChanged ()
 
void delayChanged ()
 
void fontFileChanged ()
 
void fontsDirChanged ()
 
void fontFileForcedChanged ()
 
- Signals inherited from QtAV::Filter
void enabledChanged (bool)
 

Public Member Functions

 SubtitleFilter (QObject *parent=0)
 
void setPlayer (AVPlayer *player)
 
bool isSupported (VideoFilterContext::Type ct) const Q_DECL_OVERRIDE
 
void setFile (const QString &file)
 setFile Load user selected subtitle. More...
 
QString file () const
 
bool autoLoad () const
 autoLoad Auto find and load a suitable external subtitle if file() is not empty. More...
 
void setRect (const QRectF &r)
 
QRectF rect () const
 
void setFont (const QFont &f)
 
QFont font () const
 
void setColor (const QColor &c)
 
QColor color () const
 
- Public Member Functions inherited from QtAV::VideoFilter
 VideoFilter (QObject *parent=0)
 
VideoFilterContextcontext ()
 
bool installTo (AVPlayer *player)
 installTo Install filter to player can process every frame before rendering. More...
 
bool installTo (AVOutput *output)
 installTo The process() function is in rendering thread. More...
 
void apply (Statistics *statistics, VideoFrame *frame=0)
 
bool prepareContext (VideoFilterContext *&ctx, Statistics *statistics=0, VideoFrame *frame=0)
 
- Public Member Functions inherited from QtAV::Filter
virtual ~Filter ()
 
bool isEnabled () const
 
void setOwnedByTarget (bool value=true)
 setOwnedByTarget If a filter is owned by target, it's not safe to access the filter after it's installed to a target. More...
 
bool isOwnedByTarget () const
 
bool uninstall ()
 
- Public Member Functions inherited from QtAV::SubtitleAPIProxy
 SubtitleAPIProxy (QObject *obj)
 
void setSubtitle (Subtitle *sub)
 
void setCodec (const QByteArray &value)
 setCodec set subtitle encoding that supported by QTextCodec. More...
 
QByteArray codec () const
 
bool isLoaded () const
 
void setEngines (const QStringList &value)
 
QStringList engines () const
 
QString engine () const
 
void setFuzzyMatch (bool value)
 
bool fuzzyMatch () const
 
void setDirs (const QStringList &value)
 
QStringList dirs () const
 
QStringList supportedSuffixes () const
 
void setSuffixes (const QStringList &value)
 
QStringList suffixes () const
 
bool canRender () const
 
qreal delay () const
 
void setDelay (qreal value)
 
QString fontFile () const
 
void setFontFile (const QString &value)
 
QString fontsDir () const
 
void setFontsDir (const QString &value)
 
bool isFontFileForced () const
 
void setFontFileForced (bool value)
 

Protected Member Functions

void process (Statistics *statistics, VideoFrame *frame) Q_DECL_OVERRIDE
 
- Protected Member Functions inherited from QtAV::VideoFilter
 VideoFilter (VideoFilterPrivate &d, QObject *parent=0)
 
- Protected Member Functions inherited from QtAV::Filter
 Filter (FilterPrivate &d, QObject *parent=0)
 

Properties

QByteArray codec
 
QStringList engines
 
QString engine
 
bool fuzzyMatch
 
QStringList dirs
 
QStringList suffixes
 
QStringList supportedSuffixes
 
bool canRender
 
qreal delay
 
bool autoLoad
 
QString file
 
QRectF rect
 
QFont font
 
QColor color
 
QString fontFile
 
QString fontsDir
 
bool fontFileForced
 
- Properties inherited from QtAV::Filter
bool enabled
 

Detailed Description

The SubtitleFilter class draw text and image subtitles Subtitle load priority: user specified file (setFile(...)) > auto load external (autoLoad() must be true) > embedded subtitle.

Constructor & Destructor Documentation

◆ SubtitleFilter()

QtAV::SubtitleFilter::SubtitleFilter ( QObject *  parent = 0)
explicit

Member Function Documentation

◆ autoLoad()

bool QtAV::SubtitleFilter::autoLoad ( ) const

autoLoad Auto find and load a suitable external subtitle if file() is not empty.

◆ autoLoadChanged

void QtAV::SubtitleFilter::autoLoadChanged ( bool  value)
signal

◆ canRenderChanged

void QtAV::SubtitleFilter::canRenderChanged ( )
signal

◆ codecChanged

void QtAV::SubtitleFilter::codecChanged ( )
signal

◆ color()

QColor QtAV::SubtitleFilter::color ( ) const

◆ colorChanged

void QtAV::SubtitleFilter::colorChanged ( )
signal

◆ contentChanged

void QtAV::SubtitleFilter::contentChanged ( )
signal

◆ delayChanged

void QtAV::SubtitleFilter::delayChanged ( )
signal

◆ dirsChanged

void QtAV::SubtitleFilter::dirsChanged ( )
signal

◆ engineChanged

void QtAV::SubtitleFilter::engineChanged ( )
signal

◆ enginesChanged

void QtAV::SubtitleFilter::enginesChanged ( )
signal

◆ file()

QString QtAV::SubtitleFilter::file ( ) const

◆ fileChanged

void QtAV::SubtitleFilter::fileChanged ( )
signal

◆ font()

QFont QtAV::SubtitleFilter::font ( ) const

◆ fontChanged

void QtAV::SubtitleFilter::fontChanged ( )
signal

◆ fontFileChanged

void QtAV::SubtitleFilter::fontFileChanged ( )
signal

◆ fontFileForcedChanged

void QtAV::SubtitleFilter::fontFileForcedChanged ( )
signal

◆ fontsDirChanged

void QtAV::SubtitleFilter::fontsDirChanged ( )
signal

◆ fuzzyMatchChanged

void QtAV::SubtitleFilter::fuzzyMatchChanged ( )
signal

◆ isSupported()

bool QtAV::SubtitleFilter::isSupported ( VideoFilterContext::Type  ct) const
inlinevirtual

Reimplemented from QtAV::VideoFilter.

◆ loaded

void QtAV::SubtitleFilter::loaded ( const QString &  path)
signal

◆ process()

void QtAV::SubtitleFilter::process ( Statistics statistics,
VideoFrame frame 
)
protectedvirtual

Implements QtAV::VideoFilter.

◆ rect()

QRectF QtAV::SubtitleFilter::rect ( ) const

◆ rectChanged

void QtAV::SubtitleFilter::rectChanged ( )
signal

◆ setAutoLoad

void QtAV::SubtitleFilter::setAutoLoad ( bool  value)
slot

◆ setColor()

void QtAV::SubtitleFilter::setColor ( const QColor &  c)

◆ setFile()

void QtAV::SubtitleFilter::setFile ( const QString &  file)

setFile Load user selected subtitle.

The subtitle will not change unless you manually setFile(QString()).

◆ setFont()

void QtAV::SubtitleFilter::setFont ( const QFont &  f)

◆ setPlayer()

void QtAV::SubtitleFilter::setPlayer ( AVPlayer player)

◆ setRect()

void QtAV::SubtitleFilter::setRect ( const QRectF &  r)

◆ suffixesChanged

void QtAV::SubtitleFilter::suffixesChanged ( )
signal

◆ supportedSuffixesChanged

void QtAV::SubtitleFilter::supportedSuffixesChanged ( )
signal

Property Documentation

◆ autoLoad

bool QtAV::SubtitleFilter::autoLoad
readwrite

◆ canRender

bool QtAV::SubtitleFilter::canRender
read

◆ codec

QByteArray QtAV::SubtitleFilter::codec
readwrite

◆ color

QColor QtAV::SubtitleFilter::color
readwrite

◆ delay

qreal QtAV::SubtitleFilter::delay
readwrite

◆ dirs

QStringList QtAV::SubtitleFilter::dirs
readwrite

◆ engine

QString QtAV::SubtitleFilter::engine
read

◆ engines

QStringList QtAV::SubtitleFilter::engines
readwrite

◆ file

QString QtAV::SubtitleFilter::file
readwrite

◆ font

QFont QtAV::SubtitleFilter::font
readwrite

◆ fontFile

QString QtAV::SubtitleFilter::fontFile
readwrite

◆ fontFileForced

bool QtAV::SubtitleFilter::fontFileForced
readwrite

◆ fontsDir

QString QtAV::SubtitleFilter::fontsDir
readwrite

◆ fuzzyMatch

bool QtAV::SubtitleFilter::fuzzyMatch
readwrite

◆ rect

QRectF QtAV::SubtitleFilter::rect
readwrite

◆ suffixes

QStringList QtAV::SubtitleFilter::suffixes
readwrite

◆ supportedSuffixes

QStringList QtAV::SubtitleFilter::supportedSuffixes
read

The documentation for this class was generated from the following file: