本文整理汇总了C++中CDVDAudioCodec类的典型用法代码示例。如果您正苦于以下问题:C++ CDVDAudioCodec类的具体用法?C++ CDVDAudioCodec怎么用?C++ CDVDAudioCodec使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了CDVDAudioCodec类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: SwitchCodecIfNeeded
bool CDVDPlayerAudio::SwitchCodecIfNeeded()
{
CLog::Log(LOGDEBUG, "CDVDPlayerAudio: Sample rate changed, checking for passthrough");
CDVDAudioCodec *codec = CDVDFactoryCodec::CreateAudioCodec(m_streaminfo);
if (!codec || codec->NeedPassthrough() == m_pAudioCodec->NeedPassthrough()) {
// passthrough state has not changed
delete codec;
return false;
}
delete m_pAudioCodec;
m_pAudioCodec = codec;
return true;
}
示例2: SwitchCodecIfNeeded
bool CDVDPlayerAudio::SwitchCodecIfNeeded()
{
// check if passthrough is disabled
if (!AUDIO_IS_BITSTREAM(CSettings::Get().GetInt("audiooutput.mode")))
return false;
CLog::Log(LOGDEBUG, "CDVDPlayerAudio: Sample rate changed, checking for passthrough");
CDVDAudioCodec *codec = CDVDFactoryCodec::CreateAudioCodec(m_streaminfo, true);
if (!codec || codec->NeedPassthrough() == m_pAudioCodec->NeedPassthrough()) {
// passthrough state has not changed
delete codec;
return false;
}
delete m_pAudioCodec;
m_pAudioCodec = codec;
return true;
}
示例3: SwitchCodecIfNeeded
bool CVideoPlayerAudio::SwitchCodecIfNeeded()
{
CLog::Log(LOGDEBUG, "CVideoPlayerAudio: Sample rate changed, checking for passthrough");
bool allowpassthrough = !CSettings::GetInstance().GetBool(CSettings::SETTING_VIDEOPLAYER_USEDISPLAYASCLOCK);
if (m_streaminfo.realtime)
allowpassthrough = false;
CDVDAudioCodec *codec = CDVDFactoryCodec::CreateAudioCodec(m_streaminfo, allowpassthrough, m_processInfo.AllowDTSHDDecode());
if (!codec || codec->NeedPassthrough() == m_pAudioCodec->NeedPassthrough()) {
// passthrough state has not changed
delete codec;
return false;
}
delete m_pAudioCodec;
m_pAudioCodec = codec;
return true;
}