[vlc-commits] [Git][videolan/vlc][master] 6 commits: modules/win32: remove unused vlc_codecs.h
Steve Lhomme (@robUx4)
gitlab at videolan.org
Thu Nov 30 12:55:26 UTC 2023
Steve Lhomme pushed to branch master at VideoLAN / VLC
Commits:
54e045e4 by Steve Lhomme at 2023-11-30T11:49:57+00:00
modules/win32: remove unused vlc_codecs.h
- - - - -
1e38f757 by Steve Lhomme at 2023-11-30T11:49:57+00:00
waveout: use mmreg.h to get windows codec IDs
It's a Windows-only code. We don't need the VLC versions.
- - - - -
7e628f76 by Steve Lhomme at 2023-11-30T11:49:57+00:00
dmo: use mmreg.h to get windows codec IDs
It's a Windows-only code. We don't need the VLC versions.
- - - - -
14f82010 by Steve Lhomme at 2023-11-30T11:49:57+00:00
wasapi: use mmreg to get some official defines
It's a Windows-only code. We don't need the VLC versions.
- - - - -
823d7012 by Steve Lhomme at 2023-11-30T11:49:57+00:00
modules/win32: document why we need vlc_codecs.h
Formatting string or matching a VLC FourCC.
- - - - -
8327d888 by Steve Lhomme at 2023-11-30T11:49:57+00:00
wasapi: don't define CONST_VTABLE when we don't need it
We're not create a COM object in C.
- - - - -
9 changed files:
- modules/access/wasapi.c
- modules/audio_output/wasapi.c
- modules/audio_output/waveout.c
- modules/audio_output/windows_audio_common.h
- modules/codec/avcodec/directx_va.c
- modules/codec/avcodec/va_surface.c
- modules/codec/dmo/buffer.c
- modules/codec/dmo/dmo.c
- modules/codec/mft.cpp
Changes:
=====================================
modules/access/wasapi.c
=====================================
@@ -26,7 +26,6 @@
#include <initguid.h>
#define COBJMACROS
-#define CONST_VTABLE
#include <assert.h>
#include <stdlib.h>
=====================================
modules/audio_output/wasapi.c
=====================================
@@ -24,21 +24,22 @@
#define INITGUID
#define COBJMACROS
-#define CONST_VTABLE
-#define NONEWWAVE
#include <stdatomic.h>
#include <stdlib.h>
#include <assert.h>
#include <vlc_common.h>
-#include <vlc_codecs.h>
#include <vlc_aout.h>
#include <vlc_plugin.h>
+#include <windows.h>
+#include <mmreg.h>
#include <audioclient.h>
#include "mmdevice.h"
+#include <vlc_codecs.h> // GUID_FMT/GUID_PRINT
+
#define TIMING_REPORT_DELAY VLC_TICK_FROM_MS(1000)
/* 00000092-0000-0010-8000-00aa00389b71 */
@@ -504,8 +505,8 @@ static void LogWaveFormat(struct vlc_logger *l, const WAVEFORMATEX *restrict wf)
{
vlc_debug(l, "nChannels %d", wf->nChannels);
vlc_debug(l, "wBitsPerSample %d", wf->wBitsPerSample);
- vlc_debug(l, "nAvgBytesPerSec %d", wf->nAvgBytesPerSec);
- vlc_debug(l, "nSamplesPerSec %d", wf->nSamplesPerSec);
+ vlc_debug(l, "nAvgBytesPerSec %lu", wf->nAvgBytesPerSec);
+ vlc_debug(l, "nSamplesPerSec %lu", wf->nSamplesPerSec);
vlc_debug(l, "nBlockAlign %d", wf->nBlockAlign);
vlc_debug(l, "cbSize %d", wf->cbSize);
vlc_debug(l, "wFormatTag 0x%04X", wf->wFormatTag);
=====================================
modules/audio_output/waveout.c
=====================================
@@ -40,7 +40,7 @@
#include <vlc_aout.h>
#include <vlc_charset.h> /* FromWide() */
-#include "audio_output/windows_audio_common.h"
+#include "windows_audio_common.h"
#define FRAME_SIZE 4096 /* The size is in samples, not in bytes */
@@ -498,7 +498,7 @@ static int OpenWaveOut( audio_output_t *p_aout, uint32_t i_device_id, int i_form
waveformat.Samples.wValidBitsPerSample);
msg_Dbg( p_aout,"waveformat.Samples.wSamplesPerBlock = %d",
waveformat.Samples.wSamplesPerBlock);
- msg_Dbg( p_aout,"waveformat.dwChannelMask = %u",
+ msg_Dbg( p_aout,"waveformat.dwChannelMask = %lu",
waveformat.dwChannelMask);
}
=====================================
modules/audio_output/windows_audio_common.h
=====================================
@@ -23,6 +23,7 @@
#include <windows.h>
#include <mmsystem.h>
+#include <mmreg.h>
/*****************************************************************************
* DirectSound GUIDs.
@@ -33,8 +34,6 @@
#define INITGUID /* Doesn't define the DEFINE_GUID as extern */
#include <initguid.h>
-#include <vlc_codecs.h>
-
DEFINE_GUID( _KSDATAFORMAT_SUBTYPE_IEEE_FLOAT, WAVE_FORMAT_IEEE_FLOAT, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71 );
DEFINE_GUID( _KSDATAFORMAT_SUBTYPE_PCM, WAVE_FORMAT_PCM, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71 );
DEFINE_GUID( _KSDATAFORMAT_SUBTYPE_DOLBY_AC3_SPDIF, WAVE_FORMAT_DOLBY_AC3_SPDIF, 0x0000, 0x0010, 0x80, 0x00, 0x00, 0xaa, 0x00, 0x38, 0x9b, 0x71 );
=====================================
modules/codec/avcodec/directx_va.c
=====================================
@@ -44,7 +44,7 @@
#endif
#include "directx_va.h"
-#include <vlc_codecs.h>
+#include <vlc_codecs.h> // GUID_FMT/GUID_PRINT
#include "../../packetizer/h264_nal.h"
#include "../../packetizer/hevc_nal.h"
=====================================
modules/codec/avcodec/va_surface.c
=====================================
@@ -30,7 +30,6 @@
#include <assert.h>
#include <vlc_common.h>
-#include <vlc_codecs.h>
#include <vlc_codec.h>
#include <vlc_picture.h>
=====================================
modules/codec/dmo/buffer.c
=====================================
@@ -42,7 +42,6 @@
# include <wine/windef.h>
#endif
-#include <vlc_codecs.h>
#include "dmo.h"
static HRESULT STDCALL QueryInterface( IMediaBuffer *This,
=====================================
modules/codec/dmo/dmo.c
=====================================
@@ -34,13 +34,13 @@
#include <vlc_common.h>
#include <vlc_plugin.h>
#include <vlc_codec.h>
-#include <vlc_codecs.h>
#include <objbase.h>
#include <strmif.h>
#include <amvideo.h>
+#include <mmreg.h>
-#include <vlc_codecs.h>
+#include <vlc_codecs.h> // fourcc_to_wf_tag
#include "dmo.h"
#include "../../video_chroma/copy.h"
@@ -1265,7 +1265,7 @@ static int EncoderSetAudioType( encoder_t *p_enc, IMediaObject *p_dmo )
{
i_selected = i - 1;
i_last_byterate = p_wf->nAvgBytesPerSec;
- msg_Dbg( p_enc, "selected entry %i (bitrate: %i)",
+ msg_Dbg( p_enc, "selected entry %i (bitrate: %lu)",
i_selected, p_wf->nAvgBytesPerSec * 8 );
}
}
=====================================
modules/codec/mft.cpp
=====================================
@@ -48,7 +48,7 @@ extern "C" {
#include <codecapi.h>
-#include <vlc_codecs.h>
+#include <vlc_codecs.h> // wf_tag_to_fourcc
#include <algorithm>
#include <atomic>
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/a90d1656b919a09ace5519fd5e30dc67c14bf694...8327d88805898eb322d78b9dd46b23d37bf28bbb
--
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/a90d1656b919a09ace5519fd5e30dc67c14bf694...8327d88805898eb322d78b9dd46b23d37bf28bbb
You're receiving this email because of your account on code.videolan.org.
VideoLAN code repository instance
More information about the vlc-commits
mailing list