mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-27 09:38:17 +00:00
wasapi: Fix indentation issues missed by the commit hook
These were missed because the relevant commits were made on Windows where `indent` wasn't installed.
This commit is contained in:
parent
e5c4135e81
commit
3f1e039007
5 changed files with 37 additions and 30 deletions
|
@ -27,12 +27,10 @@ G_DEFINE_TYPE (GstWasapiDeviceProvider, gst_wasapi_device_provider,
|
|||
GST_TYPE_DEVICE_PROVIDER);
|
||||
|
||||
static void gst_wasapi_device_provider_finalize (GObject * object);
|
||||
static GList *gst_wasapi_device_provider_probe (GstDeviceProvider *
|
||||
provider);
|
||||
static GList *gst_wasapi_device_provider_probe (GstDeviceProvider * provider);
|
||||
|
||||
static void
|
||||
gst_wasapi_device_provider_class_init (GstWasapiDeviceProviderClass *
|
||||
klass)
|
||||
gst_wasapi_device_provider_class_init (GstWasapiDeviceProviderClass * klass)
|
||||
{
|
||||
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
|
||||
GstDeviceProviderClass *dm_class = GST_DEVICE_PROVIDER_CLASS (klass);
|
||||
|
|
|
@ -35,11 +35,13 @@ typedef struct _GstWasapiDeviceProviderClass GstWasapiDeviceProviderClass;
|
|||
#define GST_WASAPI_DEVICE_PROVIDER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_DEVICE_PROVIDER, GstWasapiDeviceProviderClass))
|
||||
#define GST_WASAPI_DEVICE_PROVIDER_CAST(obj) ((GstWasapiDeviceProvider *)(obj))
|
||||
|
||||
struct _GstWasapiDeviceProvider {
|
||||
struct _GstWasapiDeviceProvider
|
||||
{
|
||||
GstDeviceProvider parent;
|
||||
};
|
||||
|
||||
struct _GstWasapiDeviceProviderClass {
|
||||
struct _GstWasapiDeviceProviderClass
|
||||
{
|
||||
GstDeviceProviderClass parent_class;
|
||||
};
|
||||
|
||||
|
@ -57,14 +59,16 @@ typedef struct _GstWasapiDeviceClass GstWasapiDeviceClass;
|
|||
#define GST_WASAPI_DEVICE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_DEVICE, GstWasapiDeviceClass))
|
||||
#define GST_WASAPI_DEVICE_CAST(obj) ((GstWasapiDevice *)(obj))
|
||||
|
||||
struct _GstWasapiDevice {
|
||||
struct _GstWasapiDevice
|
||||
{
|
||||
GstDevice parent;
|
||||
|
||||
gchar *strid;
|
||||
const gchar *element;
|
||||
};
|
||||
|
||||
struct _GstWasapiDeviceClass {
|
||||
struct _GstWasapiDeviceClass
|
||||
{
|
||||
GstDeviceClass parent_class;
|
||||
};
|
||||
|
||||
|
|
|
@ -429,8 +429,8 @@ gst_wasapi_sink_prepare (GstAudioSink * asink, GstAudioRingBufferSpec * spec)
|
|||
self->render_client = render_client;
|
||||
render_client = NULL;
|
||||
|
||||
gst_audio_ring_buffer_set_channel_positions (
|
||||
GST_AUDIO_BASE_SINK (self)->ringbuffer, self->positions);
|
||||
gst_audio_ring_buffer_set_channel_positions (GST_AUDIO_BASE_SINK
|
||||
(self)->ringbuffer, self->positions);
|
||||
|
||||
res = TRUE;
|
||||
|
||||
|
|
|
@ -350,7 +350,8 @@ gst_wasapi_src_prepare (GstAudioSrc * asrc, GstAudioRingBufferSpec * spec)
|
|||
guint bpf, rate, buffer_frames;
|
||||
HRESULT hr;
|
||||
|
||||
hr = IAudioClient_GetDevicePeriod (self->client, &default_period, &min_period);
|
||||
hr = IAudioClient_GetDevicePeriod (self->client, &default_period,
|
||||
&min_period);
|
||||
if (hr != S_OK) {
|
||||
GST_ERROR_OBJECT (self, "IAudioClient::GetDevicePeriod failed");
|
||||
goto beach;
|
||||
|
@ -437,8 +438,8 @@ gst_wasapi_src_prepare (GstAudioSrc * asrc, GstAudioRingBufferSpec * spec)
|
|||
self->client_clock_freq = client_clock_freq;
|
||||
self->capture_client = capture_client;
|
||||
|
||||
gst_audio_ring_buffer_set_channel_positions (
|
||||
GST_AUDIO_BASE_SRC (self)->ringbuffer, self->positions);
|
||||
gst_audio_ring_buffer_set_channel_positions (GST_AUDIO_BASE_SRC
|
||||
(self)->ringbuffer, self->positions);
|
||||
|
||||
res = TRUE;
|
||||
|
||||
|
|
|
@ -33,8 +33,10 @@
|
|||
#elif !defined(PKEY_Device_FriendlyName)
|
||||
#include <initguid.h>
|
||||
#include <propkey.h>
|
||||
DEFINE_PROPERTYKEY(PKEY_Device_FriendlyName, 0xa45c254e, 0xdf1c, 0x4efd, 0x80, 0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 14);
|
||||
DEFINE_PROPERTYKEY(PKEY_AudioEngine_DeviceFormat, 0xf19f064d, 0x82c, 0x4e27, 0xbc, 0x73, 0x68, 0x82, 0xa1, 0xbb, 0x8e, 0x4c, 0);
|
||||
DEFINE_PROPERTYKEY (PKEY_Device_FriendlyName, 0xa45c254e, 0xdf1c, 0x4efd, 0x80,
|
||||
0x20, 0x67, 0xd1, 0x46, 0xa8, 0x50, 0xe0, 14);
|
||||
DEFINE_PROPERTYKEY (PKEY_AudioEngine_DeviceFormat, 0xf19f064d, 0x82c, 0x4e27,
|
||||
0xbc, 0x73, 0x68, 0x82, 0xa1, 0xbb, 0x8e, 0x4c, 0);
|
||||
#endif
|
||||
|
||||
|
||||
|
@ -78,7 +80,8 @@ const IID IID_IAudioRenderClient = { 0xf294acfc, 0x3146, 0x4483,
|
|||
};
|
||||
#endif
|
||||
|
||||
static struct {
|
||||
static struct
|
||||
{
|
||||
guint64 wasapi_pos;
|
||||
GstAudioChannelPosition gst_pos;
|
||||
} wasapi_to_gst_pos[] = {
|
||||
|
@ -88,8 +91,10 @@ static struct {
|
|||
{SPEAKER_LOW_FREQUENCY, GST_AUDIO_CHANNEL_POSITION_LFE1},
|
||||
{SPEAKER_BACK_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_LEFT},
|
||||
{SPEAKER_BACK_RIGHT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT},
|
||||
{SPEAKER_FRONT_LEFT_OF_CENTER, GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER},
|
||||
{SPEAKER_FRONT_RIGHT_OF_CENTER, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER},
|
||||
{SPEAKER_FRONT_LEFT_OF_CENTER,
|
||||
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT_OF_CENTER},
|
||||
{SPEAKER_FRONT_RIGHT_OF_CENTER,
|
||||
GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT_OF_CENTER},
|
||||
{SPEAKER_BACK_CENTER, GST_AUDIO_CHANNEL_POSITION_REAR_CENTER},
|
||||
/* Enum values diverge from this point onwards */
|
||||
{SPEAKER_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT},
|
||||
|
@ -100,7 +105,7 @@ static struct {
|
|||
{SPEAKER_TOP_FRONT_RIGHT, GST_AUDIO_CHANNEL_POSITION_TOP_FRONT_RIGHT},
|
||||
{SPEAKER_TOP_BACK_LEFT, GST_AUDIO_CHANNEL_POSITION_TOP_REAR_LEFT},
|
||||
{SPEAKER_TOP_BACK_CENTER, GST_AUDIO_CHANNEL_POSITION_TOP_REAR_CENTER},
|
||||
{SPEAKER_TOP_BACK_RIGHT, GST_AUDIO_CHANNEL_POSITION_TOP_REAR_RIGHT},
|
||||
{SPEAKER_TOP_BACK_RIGHT, GST_AUDIO_CHANNEL_POSITION_TOP_REAR_RIGHT}
|
||||
};
|
||||
|
||||
GType
|
||||
|
@ -682,8 +687,7 @@ gst_wasapi_util_parse_waveformatex (WAVEFORMATEXTENSIBLE * format,
|
|||
"format", G_TYPE_STRING, afmt,
|
||||
"channels", G_TYPE_INT, format->Format.nChannels,
|
||||
"rate", G_TYPE_INT, format->Format.nSamplesPerSec,
|
||||
"channel-mask", GST_TYPE_BITMASK, channel_mask,
|
||||
NULL);
|
||||
"channel-mask", GST_TYPE_BITMASK, channel_mask, NULL);
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
|
|
Loading…
Reference in a new issue