MythTV  master
Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes | List of all members
VideoDisplayProfile Class Reference

#include <videodisplayprofile.h>

Collaboration diagram for VideoDisplayProfile:
Collaboration graph
[legend]

Public Member Functions

 VideoDisplayProfile ()
 
 ~VideoDisplayProfile ()=default
 
void SetInput (const QSize &Size, float Framerate=0, const QString &CodecName=QString(), const QStringList &DisallowedDecoders=QStringList())
 
void SetOutput (float Framerate)
 
float GetOutput (void) const
 
void SetVideoRenderer (const QString &VideoRenderer)
 
bool CheckVideoRendererGroup (const QString &Renderer)
 
QString GetDecoder (void) const
 
bool IsDecoderCompatible (const QString &Decoder) const
 
uint GetMaxCPUs (void) const
 
bool IsSkipLoopEnabled (void) const
 
QString GetVideoRenderer (void) const
 
QString GetActualVideoRenderer (void) const
 
QString toString (void) const
 
QString GetSingleRatePreferences (void) const
 
QString GetDoubleRatePreferences (void) const
 

Static Public Member Functions

static void InitStatics (bool Reinit=false)
 
static QList< QPair< QString, QString > > GetDeinterlacers (void)
 
static QStringList GetDecoders (void)
 
static QStringList GetDecoderNames (void)
 
static QString GetDecoderName (const QString &Decoder)
 
static QString GetDecoderHelp (const QString &Decoder=QString())
 
static QString GetVideoRendererName (const QString &Renderer)
 
static QString GetDefaultProfileName (const QString &HostName)
 
static void SetDefaultProfileName (const QString &ProfileName, const QString &HostName)
 
static uint GetProfileGroupID (const QString &ProfileName, const QString &HostName)
 
static QStringList GetProfiles (const QString &HostName)
 
static bool DeleteProfileGroup (const QString &GroupName, const QString &HostName)
 
static uint CreateProfileGroup (const QString &ProfileName, const QString &HostName)
 
static void CreateProfile (uint GroupId, uint Priority, const QString &Width, const QString &Height, const QString &Codecs, const QString &Decoder, uint MaxCpus, bool SkipLoop, const QString &VideoRenderer, const QString &Deint1, const QString &Deint2)
 
static void CreateProfiles (const QString &HostName)
 
static QStringList GetVideoRenderers (const QString &Decoder)
 
static QString GetVideoRendererHelp (const QString &Renderer)
 
static QString GetPreferredVideoRenderer (const QString &Decoder)
 
static bool IsFilterAllowed (const QString &VideoRenderer)
 
static QStringList GetFilteredRenderers (const QString &Decoder, const QStringList &Renderers)
 
static QString GetBestVideoRenderer (const QStringList &Renderers)
 
static vector< ProfileItemLoadDB (uint GroupId)
 
static bool DeleteDB (uint GroupId, const vector< ProfileItem > &Items)
 
static bool SaveDB (uint GroupId, vector< ProfileItem > &Items)
 

Private Member Functions

vector< ProfileItem >::const_iterator FindMatch (const QSize &Size, float Framerate, const QString &CodecName, const QStringList &DisallowedDecoders=QStringList())
 
void LoadBestPreferences (const QSize &Size, float Framerate, const QString &CodecName, const QStringList &DisallowedDecoders=QStringList())
 
QString GetPreference (const QString &Key) const
 
void SetPreference (const QString &Key, const QString &Value)
 

Private Attributes

QMutex m_lock { QMutex::Recursive }
 
QSize m_lastSize { 0, 0 }
 
float m_lastRate { 0.0F }
 
QString m_lastCodecName { }
 
QString m_lastVideoRenderer { }
 
QMap< QString, QString > m_currentPreferences { }
 
vector< ProfileItemm_allowedPreferences { }
 

Static Private Attributes

static QMutex s_safe_lock
 
static bool s_safe_initialized = false
 
static QMap< QString, QStringList > s_safe_renderer
 
static QMap< QString, QStringList > s_safe_renderer_group
 
static QMap< QString, QStringList > s_safe_equiv_dec
 
static QStringList s_safe_custom
 
static QMap< QString, uints_safe_renderer_priority
 
static QMap< QString, QString > s_dec_name
 
static QMap< QString, QString > s_rend_name
 
static QStringList s_safe_decoders
 
static QList< QPair< QString, QString > > s_deinterlacer_options
 

Detailed Description

Definition at line 69 of file videodisplayprofile.h.

Constructor & Destructor Documentation

◆ VideoDisplayProfile()

VideoDisplayProfile::VideoDisplayProfile ( )

Definition at line 334 of file videodisplayprofile.cpp.

◆ ~VideoDisplayProfile()

VideoDisplayProfile::~VideoDisplayProfile ( )
default

Member Function Documentation

◆ SetInput()

void VideoDisplayProfile::SetInput ( const QSize &  Size,
float  Framerate = 0,
const QString &  CodecName = QString(),
const QStringList &  DisallowedDecoders = QStringList() 
)

◆ SetOutput()

void VideoDisplayProfile::SetOutput ( float  Framerate)

◆ GetOutput()

float VideoDisplayProfile::GetOutput ( void  ) const

◆ SetVideoRenderer()

void VideoDisplayProfile::SetVideoRenderer ( const QString &  VideoRenderer)

Definition at line 434 of file videodisplayprofile.cpp.

Referenced by VideoOutputD3D::SetProfile().

◆ CheckVideoRendererGroup()

bool VideoDisplayProfile::CheckVideoRendererGroup ( const QString &  Renderer)

Definition at line 457 of file videodisplayprofile.cpp.

◆ GetDecoder()

QString VideoDisplayProfile::GetDecoder ( void  ) const

Definition at line 399 of file videodisplayprofile.cpp.

Referenced by IsDecoderCompatible(), and AvFormatDecoder::ScanStreams().

◆ IsDecoderCompatible()

bool VideoDisplayProfile::IsDecoderCompatible ( const QString &  Decoder) const

Definition at line 472 of file videodisplayprofile.cpp.

◆ GetMaxCPUs()

uint VideoDisplayProfile::GetMaxCPUs ( void  ) const

◆ IsSkipLoopEnabled()

bool VideoDisplayProfile::IsSkipLoopEnabled ( void  ) const

Definition at line 419 of file videodisplayprofile.cpp.

Referenced by AvFormatDecoder::ScanStreams().

◆ GetVideoRenderer()

QString VideoDisplayProfile::GetVideoRenderer ( void  ) const

Definition at line 424 of file videodisplayprofile.cpp.

Referenced by MythVideoOutputGPU::Init(), and SetVideoRenderer().

◆ GetActualVideoRenderer()

QString VideoDisplayProfile::GetActualVideoRenderer ( void  ) const

Definition at line 429 of file videodisplayprofile.cpp.

◆ toString()

QString VideoDisplayProfile::toString ( void  ) const

Definition at line 1369 of file videodisplayprofile.cpp.

Referenced by SetVideoRenderer().

◆ GetSingleRatePreferences()

QString VideoDisplayProfile::GetSingleRatePreferences ( void  ) const

◆ GetDoubleRatePreferences()

QString VideoDisplayProfile::GetDoubleRatePreferences ( void  ) const

◆ InitStatics()

void VideoDisplayProfile::InitStatics ( bool  Reinit = false)
static

◆ GetDeinterlacers()

QList< QPair< QString, QString > > VideoDisplayProfile::GetDeinterlacers ( void  )
static

◆ GetDecoders()

QStringList VideoDisplayProfile::GetDecoders ( void  )
static

◆ GetDecoderNames()

QStringList VideoDisplayProfile::GetDecoderNames ( void  )
static

Definition at line 770 of file videodisplayprofile.cpp.

Referenced by PlaybackProfileItemConfig::Load().

◆ GetDecoderName()

QString VideoDisplayProfile::GetDecoderName ( const QString &  Decoder)
static

◆ GetDecoderHelp()

QString VideoDisplayProfile::GetDecoderHelp ( const QString &  Decoder = QString())
static

◆ GetVideoRendererName()

QString VideoDisplayProfile::GetVideoRendererName ( const QString &  Renderer)
static

◆ GetDefaultProfileName()

QString VideoDisplayProfile::GetDefaultProfileName ( const QString &  HostName)
static

◆ SetDefaultProfileName()

void VideoDisplayProfile::SetDefaultProfileName ( const QString &  ProfileName,
const QString &  HostName 
)
static

◆ GetProfileGroupID()

uint VideoDisplayProfile::GetProfileGroupID ( const QString &  ProfileName,
const QString &  HostName 
)
static

◆ GetProfiles()

QStringList VideoDisplayProfile::GetProfiles ( const QString &  HostName)
static

◆ DeleteProfileGroup()

bool VideoDisplayProfile::DeleteProfileGroup ( const QString &  GroupName,
const QString &  HostName 
)
static

Definition at line 1078 of file videodisplayprofile.cpp.

Referenced by PlaybackProfileConfig::Save().

◆ CreateProfileGroup()

uint VideoDisplayProfile::CreateProfileGroup ( const QString &  ProfileName,
const QString &  HostName 
)
static

◆ CreateProfile()

void VideoDisplayProfile::CreateProfile ( uint  GroupId,
uint  Priority,
const QString &  Width,
const QString &  Height,
const QString &  Codecs,
const QString &  Decoder,
uint  MaxCpus,
bool  SkipLoop,
const QString &  VideoRenderer,
const QString &  Deint1,
const QString &  Deint2 
)
static

Definition at line 988 of file videodisplayprofile.cpp.

Referenced by CreateProfiles().

◆ CreateProfiles()

void VideoDisplayProfile::CreateProfiles ( const QString &  HostName)
static

Definition at line 1130 of file videodisplayprofile.cpp.

Referenced by CurrentPlaybackProfile().

◆ GetVideoRenderers()

QStringList VideoDisplayProfile::GetVideoRenderers ( const QString &  Decoder)
static

◆ GetVideoRendererHelp()

QString VideoDisplayProfile::GetVideoRendererHelp ( const QString &  Renderer)
static

Definition at line 1276 of file videodisplayprofile.cpp.

Referenced by PlaybackProfileItemConfig::vrenderChanged().

◆ GetPreferredVideoRenderer()

QString VideoDisplayProfile::GetPreferredVideoRenderer ( const QString &  Decoder)
static

Definition at line 1322 of file videodisplayprofile.cpp.

Referenced by PlaybackProfileItemConfig::decoderChanged().

◆ IsFilterAllowed()

bool VideoDisplayProfile::IsFilterAllowed ( const QString &  VideoRenderer)
static

Definition at line 1327 of file videodisplayprofile.cpp.

◆ GetFilteredRenderers()

QStringList VideoDisplayProfile::GetFilteredRenderers ( const QString &  Decoder,
const QStringList &  Renderers 
)
static

Definition at line 1334 of file videodisplayprofile.cpp.

Referenced by MythVideoOutput::Create().

◆ GetBestVideoRenderer()

QString VideoDisplayProfile::GetBestVideoRenderer ( const QStringList &  Renderers)
static

Definition at line 1348 of file videodisplayprofile.cpp.

Referenced by MythVideoOutput::Create(), and GetPreferredVideoRenderer().

◆ LoadDB()

vector< ProfileItem > VideoDisplayProfile::LoadDB ( uint  GroupId)
static

◆ DeleteDB()

bool VideoDisplayProfile::DeleteDB ( uint  GroupId,
const vector< ProfileItem > &  Items 
)
static

Definition at line 605 of file videodisplayprofile.cpp.

Referenced by PlaybackProfileConfig::Save().

◆ SaveDB()

bool VideoDisplayProfile::SaveDB ( uint  GroupId,
vector< ProfileItem > &  Items 
)
static

Definition at line 631 of file videodisplayprofile.cpp.

Referenced by PlaybackProfileConfig::Save().

◆ FindMatch()

vector< ProfileItem >::const_iterator VideoDisplayProfile::FindMatch ( const QSize &  Size,
float  Framerate,
const QString &  CodecName,
const QStringList &  DisallowedDecoders = QStringList() 
)
private

Definition at line 504 of file videodisplayprofile.cpp.

Referenced by LoadBestPreferences().

◆ LoadBestPreferences()

void VideoDisplayProfile::LoadBestPreferences ( const QSize &  Size,
float  Framerate,
const QString &  CodecName,
const QStringList &  DisallowedDecoders = QStringList() 
)
private

Definition at line 513 of file videodisplayprofile.cpp.

Referenced by SetInput(), and SetOutput().

◆ GetPreference()

QString VideoDisplayProfile::GetPreference ( const QString &  Key) const
private

◆ SetPreference()

void VideoDisplayProfile::SetPreference ( const QString &  Key,
const QString &  Value 
)
private

Definition at line 496 of file videodisplayprofile.cpp.

Referenced by LoadBestPreferences(), and SetVideoRenderer().

Member Data Documentation

◆ m_lock

QMutex VideoDisplayProfile::m_lock { QMutex::Recursive }
mutableprivate

◆ m_lastSize

QSize VideoDisplayProfile::m_lastSize { 0, 0 }
private

Definition at line 131 of file videodisplayprofile.h.

Referenced by SetInput(), and SetOutput().

◆ m_lastRate

float VideoDisplayProfile::m_lastRate { 0.0F }
private

Definition at line 132 of file videodisplayprofile.h.

Referenced by GetOutput(), SetInput(), and SetOutput().

◆ m_lastCodecName

QString VideoDisplayProfile::m_lastCodecName { }
private

Definition at line 133 of file videodisplayprofile.h.

Referenced by SetInput(), and SetOutput().

◆ m_lastVideoRenderer

QString VideoDisplayProfile::m_lastVideoRenderer { }
private

◆ m_currentPreferences

QMap<QString,QString> VideoDisplayProfile::m_currentPreferences { }
private

Definition at line 135 of file videodisplayprofile.h.

Referenced by GetPreference(), LoadBestPreferences(), and SetPreference().

◆ m_allowedPreferences

vector<ProfileItem> VideoDisplayProfile::m_allowedPreferences { }
private

Definition at line 136 of file videodisplayprofile.h.

Referenced by FindMatch(), LoadBestPreferences(), and VideoDisplayProfile().

◆ s_safe_lock

QMutex VideoDisplayProfile::s_safe_lock
staticprivate

◆ s_safe_initialized

bool VideoDisplayProfile::s_safe_initialized = false
staticprivate

Definition at line 139 of file videodisplayprofile.h.

Referenced by InitStatics().

◆ s_safe_renderer

QMap< QString, QStringList > VideoDisplayProfile::s_safe_renderer
staticprivate

Definition at line 140 of file videodisplayprofile.h.

Referenced by GetVideoRenderers(), and InitStatics().

◆ s_safe_renderer_group

QMap< QString, QStringList > VideoDisplayProfile::s_safe_renderer_group
staticprivate

Definition at line 141 of file videodisplayprofile.h.

Referenced by CheckVideoRendererGroup(), and InitStatics().

◆ s_safe_equiv_dec

QMap< QString, QStringList > VideoDisplayProfile::s_safe_equiv_dec
staticprivate

Definition at line 142 of file videodisplayprofile.h.

Referenced by InitStatics(), and IsDecoderCompatible().

◆ s_safe_custom

QStringList VideoDisplayProfile::s_safe_custom
staticprivate

Definition at line 143 of file videodisplayprofile.h.

Referenced by InitStatics(), and IsFilterAllowed().

◆ s_safe_renderer_priority

QMap< QString, uint > VideoDisplayProfile::s_safe_renderer_priority
staticprivate

Definition at line 144 of file videodisplayprofile.h.

Referenced by GetBestVideoRenderer(), and InitStatics().

◆ s_dec_name

QMap< QString, QString > VideoDisplayProfile::s_dec_name
staticprivate

Definition at line 145 of file videodisplayprofile.h.

Referenced by GetDecoderName().

◆ s_rend_name

QMap< QString, QString > VideoDisplayProfile::s_rend_name
staticprivate

Definition at line 146 of file videodisplayprofile.h.

Referenced by GetVideoRendererName().

◆ s_safe_decoders

QStringList VideoDisplayProfile::s_safe_decoders
staticprivate

Definition at line 147 of file videodisplayprofile.h.

Referenced by GetDecoders(), and InitStatics().

◆ s_deinterlacer_options

QList< QPair< QString, QString > > VideoDisplayProfile::s_deinterlacer_options
staticprivate

Definition at line 148 of file videodisplayprofile.h.

Referenced by GetDeinterlacers(), and InitStatics().


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