From fbb3b775335637edf61f6f8e1d8a3b5ef361c5ba Mon Sep 17 00:00:00 2001 From: Hendrik Leppkes Date: Sun, 4 Jan 2015 02:33:08 +0100 Subject: Remove useless renderer format support info from the status page --- decoder/LAVAudio/AudioSettingsProp.cpp | 6 ----- decoder/LAVAudio/LAVAudio.cpp | 31 +--------------------- decoder/LAVAudio/LAVAudio.h | 2 -- decoder/LAVAudio/LAVAudio.rc | 47 +++++++++++++++------------------- decoder/LAVAudio/resource.h | 6 ----- 5 files changed, 22 insertions(+), 70 deletions(-) (limited to 'decoder') diff --git a/decoder/LAVAudio/AudioSettingsProp.cpp b/decoder/LAVAudio/AudioSettingsProp.cpp index e74a9072..edf0b188 100644 --- a/decoder/LAVAudio/AudioSettingsProp.cpp +++ b/decoder/LAVAudio/AudioSettingsProp.cpp @@ -806,12 +806,6 @@ HRESULT CLAVAudioStatusProp::OnActivate() SendDlgItemMessage(m_Dlg, IDC_INPUT_FORMAT, WM_SETTEXT, 0, (LPARAM)buffer); } - SendDlgItemMessage(m_Dlg, IDC_INT8, BM_SETCHECK, m_pAudioStatus->IsSampleFormatSupported(SampleFormat_U8), 0); - SendDlgItemMessage(m_Dlg, IDC_INT16, BM_SETCHECK, m_pAudioStatus->IsSampleFormatSupported(SampleFormat_16), 0); - SendDlgItemMessage(m_Dlg, IDC_INT24, BM_SETCHECK, m_pAudioStatus->IsSampleFormatSupported(SampleFormat_24), 0); - SendDlgItemMessage(m_Dlg, IDC_INT32, BM_SETCHECK, m_pAudioStatus->IsSampleFormatSupported(SampleFormat_32), 0); - SendDlgItemMessage(m_Dlg, IDC_FP32, BM_SETCHECK, m_pAudioStatus->IsSampleFormatSupported(SampleFormat_FP32), 0); - const char *outputFormat = nullptr; int nOutputChannels = 0; int nOutputSampleRate = 0; diff --git a/decoder/LAVAudio/LAVAudio.cpp b/decoder/LAVAudio/LAVAudio.cpp index d9345246..d8faf226 100644 --- a/decoder/LAVAudio/LAVAudio.cpp +++ b/decoder/LAVAudio/LAVAudio.cpp @@ -80,12 +80,6 @@ CLAVAudio::CLAVAudio(LPUNKNOWN pUnk, HRESULT* phr) return; } - m_bSampleSupport[SampleFormat_U8] = TRUE; - m_bSampleSupport[SampleFormat_16] = TRUE; - m_bSampleSupport[SampleFormat_24] = TRUE; - m_bSampleSupport[SampleFormat_32] = TRUE; - m_bSampleSupport[SampleFormat_FP32] = TRUE; - LoadSettings(); InitBitstreaming(); @@ -787,10 +781,7 @@ STDMETHODIMP_(BOOL) CLAVAudio::GetSuppressFormatChanges() // ILAVAudioStatus BOOL CLAVAudio::IsSampleFormatSupported(LAVAudioSampleFormat sfCheck) { - if(!m_pOutput || m_pOutput->IsConnected() == FALSE) { - return FALSE; - } - return m_bSampleSupport[sfCheck]; + return FALSE; } HRESULT CLAVAudio::GetDecodeDetails(const char **pCodec, const char **pDecodeFormat, int *pnChannels, int *pSampleRate, DWORD *pChannelMask) @@ -1444,26 +1435,6 @@ HRESULT CLAVAudio::CheckConnect(PIN_DIRECTION dir, IPin *pPin) // TODO: Check if the upstream source filter is LAVFSplitter, and store that somewhere // Validate that this is called before any media type negotiation - } else if (dir == PINDIR_OUTPUT) { - CMediaType check_mt; - const int nChannels = m_pAVCtx ? m_pAVCtx->channels : 2; - const int nSamplesPerSec = m_pAVCtx ? m_pAVCtx->sample_rate : 48000; - const DWORD dwChannelMask = get_channel_mask(nChannels); - - check_mt = CreateMediaType(SampleFormat_FP32, nSamplesPerSec, nChannels, dwChannelMask); - m_bSampleSupport[SampleFormat_FP32] = pPin->QueryAccept(&check_mt) == S_OK; - - check_mt = CreateMediaType(SampleFormat_32, nSamplesPerSec, nChannels, dwChannelMask); - m_bSampleSupport[SampleFormat_32] = pPin->QueryAccept(&check_mt) == S_OK; - - check_mt = CreateMediaType(SampleFormat_24, nSamplesPerSec, nChannels, dwChannelMask); - m_bSampleSupport[SampleFormat_24] = pPin->QueryAccept(&check_mt) == S_OK; - - check_mt = CreateMediaType(SampleFormat_16, nSamplesPerSec, nChannels, dwChannelMask); - m_bSampleSupport[SampleFormat_16] = pPin->QueryAccept(&check_mt) == S_OK; - - check_mt = CreateMediaType(SampleFormat_U8, nSamplesPerSec, nChannels, dwChannelMask); - m_bSampleSupport[SampleFormat_U8] = pPin->QueryAccept(&check_mt) == S_OK; } return __super::CheckConnect(dir, pPin); } diff --git a/decoder/LAVAudio/LAVAudio.h b/decoder/LAVAudio/LAVAudio.h index 13b41e09..d1fa9aef 100644 --- a/decoder/LAVAudio/LAVAudio.h +++ b/decoder/LAVAudio/LAVAudio.h @@ -260,8 +260,6 @@ private: LAVAudioSampleFormat m_FallbackFormat = SampleFormat_None; DWORD m_dwOverrideMixer = 0; - BOOL m_bSampleSupport[SampleFormat_NB]; - BOOL m_bHasVideo = TRUE; AVAudioResampleContext *m_avrContext = nullptr; diff --git a/decoder/LAVAudio/LAVAudio.rc b/decoder/LAVAudio/LAVAudio.rc index c012a427..1f77fca6 100644 --- a/decoder/LAVAudio/LAVAudio.rc +++ b/decoder/LAVAudio/LAVAudio.rc @@ -97,7 +97,8 @@ BEGIN CONTROL "32-bit Integer",IDC_OUT_S32,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,216,107,61,10 CONTROL "32-bit Floating-point",IDC_OUT_FP32,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,216,123,81,10 CONTROL "8-bit Integer",IDC_OUT_U8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,286,107,54,10 - CONTROL "Use Dithering for 16-bit Output",IDC_OUT_S16_DITHER,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,216,139,125,10 + CONTROL "Use Dithering for 16-bit Output",IDC_OUT_S16_DITHER, + "Button",BS_AUTOCHECKBOX | WS_TABSTOP,216,139,125,10 LTEXT "Enabling all formats will allow untouched / bitexact output. Only if a format is not compatible with your hard- or software it should be disabled.",IDC_LBL_OUTNOTE,213,152,140,37 GROUPBOX "Audio Delay",IDC_GROUP_DELAY,207,7,151,50 CONTROL "Enable Audio Delay",IDC_DELAY_ENABLED,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,214,20,113,10 @@ -143,7 +144,7 @@ BEGIN CONTROL "",IDC_CODECS,"SysListView32",LVS_REPORT | LVS_SINGLESEL | LVS_SHOWSELALWAYS | LVS_NOSORTHEADER | WS_BORDER | WS_TABSTOP,7,40,351,166 END -IDD_PROPPAGE_STATUS DIALOGEX 0, 0, 214, 188 +IDD_PROPPAGE_STATUS DIALOGEX 0, 0, 214, 156 STYLE DS_SETFONT | DS_FIXEDSYS | WS_CHILD FONT 8, "MS Shell Dlg", 400, 0, 0x0 BEGIN @@ -165,29 +166,23 @@ BEGIN LTEXT "",IDC_OUTPUT_CHANNEL,160,30,45,8 LTEXT "",IDC_OUTPUT_SAMPLERATE,160,42,45,8 LTEXT "",IDC_OUTPUT_FORMAT,160,54,45,8 - GROUPBOX "Sample Formats supported by Renderer",IDC_SUP_SAMPLE_FORMATS,7,71,200,28 - CHECKBOX "U8",IDC_INT8,11,82,25,10,WS_DISABLED - CHECKBOX "S16",IDC_INT16,49,82,28,10,WS_DISABLED - CHECKBOX "S24",IDC_INT24,87,82,28,10,WS_DISABLED - CHECKBOX "S32",IDC_INT32,125,82,28,10,WS_DISABLED - CHECKBOX "FP32",IDC_FP32,165,82,32,10,WS_DISABLED - GROUPBOX "Channel Output",IDC_VOLUME,7,103,200,77 - CONTROL "",IDC_VOLUME1,"msctls_progress32",PBS_VERTICAL | WS_BORDER,14,116,12,45 - CONTROL "",IDC_VOLUME2,"msctls_progress32",PBS_VERTICAL | WS_BORDER,39,116,12,45 - CONTROL "",IDC_VOLUME3,"msctls_progress32",PBS_VERTICAL | WS_BORDER,64,116,12,45 - CONTROL "",IDC_VOLUME4,"msctls_progress32",PBS_VERTICAL | WS_BORDER,89,116,12,45 - CONTROL "",IDC_VOLUME5,"msctls_progress32",PBS_VERTICAL | WS_BORDER,114,116,12,45 - CONTROL "",IDC_VOLUME6,"msctls_progress32",PBS_VERTICAL | WS_BORDER,139,116,12,45 - CONTROL "",IDC_VOLUME7,"msctls_progress32",PBS_VERTICAL | WS_BORDER,164,116,12,45 - CONTROL "",IDC_VOLUME8,"msctls_progress32",PBS_VERTICAL | WS_BORDER,189,116,12,45 - CTEXT "L",IDC_VOLUME1_DESC,9,164,21,8 - CTEXT "R",IDC_VOLUME2_DESC,34,164,21,8 - CTEXT "C",IDC_VOLUME3_DESC,59,164,21,8 - CTEXT "LFE",IDC_VOLUME4_DESC,84,164,21,8 - CTEXT "BL",IDC_VOLUME5_DESC,109,164,21,8 - CTEXT "BR",IDC_VOLUME6_DESC,134,164,21,8 - CTEXT "SL",IDC_VOLUME7_DESC,159,164,21,8 - CTEXT "SR",IDC_VOLUME8_DESC,184,164,21,8 + GROUPBOX "Channel Output",IDC_VOLUME,7,71,200,77 + CONTROL "",IDC_VOLUME1,"msctls_progress32",PBS_VERTICAL | WS_BORDER,14,84,12,45 + CONTROL "",IDC_VOLUME2,"msctls_progress32",PBS_VERTICAL | WS_BORDER,39,84,12,45 + CONTROL "",IDC_VOLUME3,"msctls_progress32",PBS_VERTICAL | WS_BORDER,64,84,12,45 + CONTROL "",IDC_VOLUME4,"msctls_progress32",PBS_VERTICAL | WS_BORDER,89,84,12,45 + CONTROL "",IDC_VOLUME5,"msctls_progress32",PBS_VERTICAL | WS_BORDER,114,84,12,45 + CONTROL "",IDC_VOLUME6,"msctls_progress32",PBS_VERTICAL | WS_BORDER,139,84,12,45 + CONTROL "",IDC_VOLUME7,"msctls_progress32",PBS_VERTICAL | WS_BORDER,164,84,12,45 + CONTROL "",IDC_VOLUME8,"msctls_progress32",PBS_VERTICAL | WS_BORDER,189,84,12,45 + CTEXT "L",IDC_VOLUME1_DESC,9,132,21,8 + CTEXT "R",IDC_VOLUME2_DESC,34,132,21,8 + CTEXT "C",IDC_VOLUME3_DESC,59,132,21,8 + CTEXT "LFE",IDC_VOLUME4_DESC,84,132,21,8 + CTEXT "BL",IDC_VOLUME5_DESC,109,132,21,8 + CTEXT "BR",IDC_VOLUME6_DESC,134,132,21,8 + CTEXT "SL",IDC_VOLUME7_DESC,159,132,21,8 + CTEXT "SR",IDC_VOLUME8_DESC,184,132,21,8 END @@ -228,7 +223,7 @@ BEGIN LEFTMARGIN, 7 RIGHTMARGIN, 207 TOPMARGIN, 7 - BOTTOMMARGIN, 180 + BOTTOMMARGIN, 148 END END #endif // APSTUDIO_INVOKED diff --git a/decoder/LAVAudio/resource.h b/decoder/LAVAudio/resource.h index de93db64..48859b02 100644 --- a/decoder/LAVAudio/resource.h +++ b/decoder/LAVAudio/resource.h @@ -12,12 +12,6 @@ #define IDI_ICON1 104 #define IDS_MIXER 105 #define IDC_INPUT_STATUS 1013 -#define IDC_SUP_SAMPLE_FORMATS 1020 -#define IDC_INT16 1021 -#define IDC_INT24 1022 -#define IDC_INT32 1023 -#define IDC_FP32 1024 -#define IDC_INT8 1025 #define IDC_OUTPUT_STATUS 1026 #define IDC_DRC 1034 #define IDC_DRC_LEVEL 1035 -- cgit v1.2.3