update for audio api change

This commit is contained in:
Wim Taymans 2012-06-08 10:11:12 +02:00
parent e44df74eda
commit f65495d405
5 changed files with 8 additions and 7 deletions

View file

@ -649,7 +649,7 @@ gst_flac_enc_getcaps (GstAudioEncoder * enc, GstCaps * filter)
guint64 channel_mask;
gst_audio_channel_positions_to_mask (channel_positions[i - 1], i,
&channel_mask);
FALSE, &channel_mask);
gst_structure_set (s2, "channels", G_TYPE_INT, i, "channel-mask",
GST_TYPE_BITMASK, channel_mask, NULL);
}

View file

@ -400,7 +400,7 @@ gst_wavpack_enc_set_format (GstAudioEncoder * benc, GstAudioInfo * info)
enc->channel_mapping);
/* wavpack caps hold gst mask, not wavpack mask */
gst_audio_channel_positions_to_mask (opos, enc->channels, &mask);
gst_audio_channel_positions_to_mask (opos, enc->channels, FALSE, &mask);
/* set fixed src pad caps now that we know what we will get */
caps = gst_caps_new_simple ("audio/x-wavpack",

View file

@ -565,7 +565,7 @@ gst_wavpack_parse_handle_frame (GstBaseParse * parse,
if (!gst_wavpack_get_channel_positions (chans, mask, pos)) {
GST_WARNING_OBJECT (wvparse, "Failed to determine channel layout");
} else {
gst_audio_channel_positions_to_mask (pos, chans, &gmask);
gst_audio_channel_positions_to_mask (pos, chans, FALSE, &gmask);
if (gmask)
gst_caps_set_simple (caps,
"channel-mask", GST_TYPE_BITMASK, gmask, NULL);

View file

@ -309,7 +309,8 @@ gst_oss4_audio_add_channel_layout (GstObject * obj, guint64 layout,
g_return_if_fail (num_channels <= G_N_ELEMENTS (ch_layout));
gst_oss4_audio_get_channel_layout (obj, layout, num_channels, ch_layout);
if (gst_audio_channel_positions_to_mask (ch_layout, num_channels, &mask))
if (gst_audio_channel_positions_to_mask (ch_layout, num_channels, FALSE,
&mask))
gst_structure_set (s, "channel-mask", GST_TYPE_BITMASK, mask, NULL);
return;

View file

@ -456,17 +456,17 @@ sink_handoff_float32 (GstElement * element, GstBuffer * buffer, GstPad * pad,
if (n == 0) {
GstAudioChannelPosition pos[2] =
{ GST_AUDIO_CHANNEL_POSITION_NONE, GST_AUDIO_CHANNEL_POSITION_NONE };
gst_audio_channel_positions_to_mask (pos, 2, &mask);
gst_audio_channel_positions_to_mask (pos, 2, FALSE, &mask);
} else if (n == 1) {
GstAudioChannelPosition pos[2] = { GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT,
GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT
};
gst_audio_channel_positions_to_mask (pos, 2, &mask);
gst_audio_channel_positions_to_mask (pos, 2, FALSE, &mask);
} else if (n == 2) {
GstAudioChannelPosition pos[2] = { GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER,
GST_AUDIO_CHANNEL_POSITION_REAR_CENTER
};
gst_audio_channel_positions_to_mask (pos, 2, &mask);
gst_audio_channel_positions_to_mask (pos, 2, FALSE, &mask);
}
caps = gst_caps_new_simple ("audio/x-raw",