mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-27 09:38:17 +00:00
Fix for Andy's GstBuffer->GstData changes
Original commit message from CVS: Fix for Andy's GstBuffer->GstData changes
This commit is contained in:
parent
a365faa43a
commit
0775f2156e
1 changed files with 16 additions and 10 deletions
|
@ -136,8 +136,8 @@ static void dxr3audiosink_set_scr (Dxr3AudioSink *sink,
|
||||||
|
|
||||||
static gboolean dxr3audiosink_handle_event (GstPad *pad,
|
static gboolean dxr3audiosink_handle_event (GstPad *pad,
|
||||||
GstEvent *event);
|
GstEvent *event);
|
||||||
static void dxr3audiosink_chain_pcm (GstPad *pad,GstBuffer *buf);
|
static void dxr3audiosink_chain_pcm (GstPad *pad,GstData *buf);
|
||||||
static void dxr3audiosink_chain_ac3 (GstPad *pad, GstBuffer *buf);
|
static void dxr3audiosink_chain_ac3 (GstPad *pad, GstData *buf);
|
||||||
|
|
||||||
/* static void dxr3audiosink_wait (Dxr3AudioSink *sink, */
|
/* static void dxr3audiosink_wait (Dxr3AudioSink *sink, */
|
||||||
/* GstClockTime time); */
|
/* GstClockTime time); */
|
||||||
|
@ -571,22 +571,25 @@ dxr3audiosink_handle_event (GstPad *pad, GstEvent *event)
|
||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
dxr3audiosink_chain_pcm (GstPad *pad, GstBuffer *buf)
|
dxr3audiosink_chain_pcm (GstPad *pad, GstData *_data)
|
||||||
{
|
{
|
||||||
Dxr3AudioSink *sink;
|
Dxr3AudioSink *sink;
|
||||||
gint bytes_written = 0;
|
gint bytes_written = 0;
|
||||||
|
GstBuffer *buf;
|
||||||
|
|
||||||
g_return_if_fail (pad != NULL);
|
g_return_if_fail (pad != NULL);
|
||||||
g_return_if_fail (GST_IS_PAD (pad));
|
g_return_if_fail (GST_IS_PAD (pad));
|
||||||
g_return_if_fail (buf != NULL);
|
g_return_if_fail (_data != NULL);
|
||||||
|
|
||||||
sink = DXR3AUDIOSINK (gst_pad_get_parent (pad));
|
sink = DXR3AUDIOSINK (gst_pad_get_parent (pad));
|
||||||
|
|
||||||
if (GST_IS_EVENT (buf)) {
|
if (GST_IS_EVENT (_data)) {
|
||||||
dxr3audiosink_handle_event (pad, GST_EVENT (buf));
|
dxr3audiosink_handle_event (pad, GST_EVENT (_data));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
buf = GST_BUFFER (_data);
|
||||||
|
|
||||||
if (sink->mode != DXR3AUDIOSINK_MODE_PCM) {
|
if (sink->mode != DXR3AUDIOSINK_MODE_PCM) {
|
||||||
/* Switch to PCM mode. */
|
/* Switch to PCM mode. */
|
||||||
dxr3audiosink_set_mode_pcm (sink);
|
dxr3audiosink_set_mode_pcm (sink);
|
||||||
|
@ -633,22 +636,25 @@ dxr3audiosink_chain_pcm (GstPad *pad, GstBuffer *buf)
|
||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
dxr3audiosink_chain_ac3 (GstPad *pad, GstBuffer *buf)
|
dxr3audiosink_chain_ac3 (GstPad *pad, GstData *_data)
|
||||||
{
|
{
|
||||||
Dxr3AudioSink *sink;
|
Dxr3AudioSink *sink;
|
||||||
gint bytes_written = 0;
|
gint bytes_written = 0;
|
||||||
|
GstBuffer *buf;
|
||||||
|
|
||||||
g_return_if_fail (pad != NULL);
|
g_return_if_fail (pad != NULL);
|
||||||
g_return_if_fail (GST_IS_PAD (pad));
|
g_return_if_fail (GST_IS_PAD (pad));
|
||||||
g_return_if_fail (buf != NULL);
|
g_return_if_fail (_data != NULL);
|
||||||
|
|
||||||
sink = DXR3AUDIOSINK (gst_pad_get_parent (pad));
|
sink = DXR3AUDIOSINK (gst_pad_get_parent (pad));
|
||||||
|
|
||||||
if (GST_IS_EVENT (buf)) {
|
if (GST_IS_EVENT (_data)) {
|
||||||
dxr3audiosink_handle_event (pad, GST_EVENT (buf));
|
dxr3audiosink_handle_event (pad, GST_EVENT (_data));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
buf = GST_BUFFER (_data);
|
||||||
|
|
||||||
if (sink->mode != DXR3AUDIOSINK_MODE_AC3) {
|
if (sink->mode != DXR3AUDIOSINK_MODE_AC3) {
|
||||||
/* Switch to AC3 mode. */
|
/* Switch to AC3 mode. */
|
||||||
dxr3audiosink_set_mode_ac3 (sink);
|
dxr3audiosink_set_mode_ac3 (sink);
|
||||||
|
|
Loading…
Reference in a new issue