sys/osxaudio/: Fix the build on macosx.

Original commit message from CVS:
* sys/osxaudio/gstosxaudiosink.c:
(gst_osx_audio_sink_select_device):
* sys/osxaudio/gstosxaudiosrc.c:
(gst_osx_audio_src_create_ringbuffer),
(gst_osx_audio_src_select_device):
* sys/osxaudio/gstosxringbuffer.c: (gst_osx_ring_buffer_acquire):
Fix the build on macosx.
This commit is contained in:
Edward Hervey 2008-08-27 16:12:39 +00:00
parent 2664bb269e
commit d92f63d3ab
4 changed files with 26 additions and 14 deletions

View file

@ -1,3 +1,13 @@
2008-08-27 Edward Hervey <edward.hervey@collabora.co.uk>
* sys/osxaudio/gstosxaudiosink.c:
(gst_osx_audio_sink_select_device):
* sys/osxaudio/gstosxaudiosrc.c:
(gst_osx_audio_src_create_ringbuffer),
(gst_osx_audio_src_select_device):
* sys/osxaudio/gstosxringbuffer.c: (gst_osx_ring_buffer_acquire):
Fix the build on macosx.
2008-08-27 Tim-Philipp Müller <tim.muller at collabora co uk>
* gst/icydemux/gsticydemux.c:

View file

@ -425,7 +425,8 @@ gst_osx_audio_sink_select_device (GstOsxAudioSink * osxsink)
GST_DEBUG_OBJECT (osxsink,
"Getting available streamids from %d (%d bytes)",
(int) (propertySize / sizeof (AudioStreamID)), propertySize);
(int) (propertySize / sizeof (AudioStreamID)),
(unsigned int) propertySize);
streams = g_malloc (propertySize);
status = AudioDeviceGetProperty (osxsink->device_id, 0, /* Master channel */
FALSE, /* isInput */
@ -439,7 +440,8 @@ gst_osx_audio_sink_select_device (GstOsxAudioSink * osxsink)
}
GST_DEBUG_OBJECT (osxsink, "Getting streamid from %d (%d bytes)",
(int) (propertySize / sizeof (AudioStreamID)), propertySize);
(int) (propertySize / sizeof (AudioStreamID)),
(unsigned int) propertySize);
if (propertySize >= sizeof (AudioStreamID)) {
osxsink->stream_id = streams[0];

View file

@ -227,8 +227,6 @@ static GstRingBuffer *
gst_osx_audio_src_create_ringbuffer (GstBaseAudioSrc * src)
{
GstOsxAudioSrc *osxsrc;
OSStatus status;
UInt32 propertySize;
GstOsxRingBuffer *ringbuffer;
osxsrc = GST_OSX_AUDIO_SRC (src);
@ -327,7 +325,8 @@ gst_osx_audio_src_select_device (GstOsxAudioSrc * osxsrc)
GST_DEBUG_OBJECT (osxsrc,
"Getting available streamids from %d (%d bytes)",
(int) (propertySize / sizeof (AudioStreamID)), propertySize);
(int) (propertySize / sizeof (AudioStreamID)),
(unsigned int) propertySize);
streams = g_malloc (propertySize);
status = AudioDeviceGetProperty (osxsrc->device_id, 0, /* Master channel */
FALSE, /* isInput */
@ -341,7 +340,8 @@ gst_osx_audio_src_select_device (GstOsxAudioSrc * osxsrc)
}
GST_DEBUG_OBJECT (osxsrc, "Getting streamid from %d (%d bytes)",
(int) (propertySize / sizeof (AudioStreamID)), propertySize);
(int) (propertySize / sizeof (AudioStreamID)),
(unsigned int) propertySize);
if (propertySize >= sizeof (AudioStreamID)) {
osxsrc->stream_id = streams[0];

View file

@ -172,7 +172,6 @@ gst_osx_ring_buffer_acquire (GstRingBuffer * buf, GstRingBufferSpec * spec)
/* Configure the output stream and allocate ringbuffer memory */
GstOsxRingBuffer *osxbuf;
AudioStreamBasicDescription asbd;
AudioStreamBasicDescription asbd2;
OSStatus status;
UInt32 buffer_len;
UInt32 propertySize;
@ -190,14 +189,15 @@ gst_osx_ring_buffer_acquire (GstRingBuffer * buf, GstRingBufferSpec * spec)
asbd.mFramesPerPacket = 1;
asbd.mReserved = 0;
GST_LOG_OBJECT (osxbuf, "Format: %x, %f, %d, %x, %d, %d, %d, %d, %d",
asbd.mFormatID,
GST_LOG_OBJECT (osxbuf, "Format: %x, %f, %u, %x, %d, %d, %d, %d, %d",
(unsigned int) asbd.mFormatID,
asbd.mSampleRate,
asbd.mChannelsPerFrame,
asbd.mFormatFlags,
asbd.mBytesPerFrame,
asbd.mBitsPerChannel,
asbd.mBytesPerPacket, asbd.mFramesPerPacket, asbd.mReserved);
(unsigned int) asbd.mChannelsPerFrame,
(unsigned int) asbd.mFormatFlags,
(unsigned int) asbd.mBytesPerFrame,
(unsigned int) asbd.mBitsPerChannel,
(unsigned int) asbd.mBytesPerPacket,
(unsigned int) asbd.mFramesPerPacket, (unsigned int) asbd.mReserved);
GST_DEBUG_OBJECT (osxbuf, "Using stream_id %d, setting output format",
(int) osxbuf->stream_id);