mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-23 16:50:47 +00:00
Make flacenc work with mono streams by only setting the mid_side and loose_mid_side when its a stereo stream
Original commit message from CVS: Make flacenc work with mono streams by only setting the mid_side and loose_mid_side when its a stereo stream
This commit is contained in:
parent
8b999a970b
commit
be4c8f8df2
2 changed files with 11 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2004-08-17 Iain <iaingnome@gmail.com>
|
||||||
|
|
||||||
|
* ext/flac/gstflacenc.c (gst_flacenc_update_quality): Only set the
|
||||||
|
mid_side and loose_mid_side properties if its a stereo stream.
|
||||||
|
|
||||||
2004-08-17 Wim Taymans <wim@fluendo.com>
|
2004-08-17 Wim Taymans <wim@fluendo.com>
|
||||||
|
|
||||||
* ext/theora/theoradec.c: (gst_theora_dec_class_init),
|
* ext/theora/theoradec.c: (gst_theora_dec_class_init),
|
||||||
|
|
|
@ -364,6 +364,7 @@ gst_flacenc_sinkconnect (GstPad * pad, const GstCaps * caps)
|
||||||
caps = gst_caps_new_simple ("audio/x-flac",
|
caps = gst_caps_new_simple ("audio/x-flac",
|
||||||
"channels", G_TYPE_INT, flacenc->channels,
|
"channels", G_TYPE_INT, flacenc->channels,
|
||||||
"rate", G_TYPE_INT, flacenc->sample_rate, NULL);
|
"rate", G_TYPE_INT, flacenc->sample_rate, NULL);
|
||||||
|
|
||||||
ret = gst_pad_try_set_caps (flacenc->srcpad, caps);
|
ret = gst_pad_try_set_caps (flacenc->srcpad, caps);
|
||||||
if (ret <= 0) {
|
if (ret <= 0) {
|
||||||
return ret;
|
return ret;
|
||||||
|
@ -398,8 +399,11 @@ gst_flacenc_update_quality (FlacEnc * flacenc, gint quality)
|
||||||
|
|
||||||
g_object_freeze_notify (G_OBJECT (flacenc));
|
g_object_freeze_notify (G_OBJECT (flacenc));
|
||||||
|
|
||||||
DO_UPDATE (do_mid_side_stereo, mid_side, "mid_side_stereo");
|
if (flacenc->channels == 2) {
|
||||||
DO_UPDATE (loose_mid_side_stereo, loose_mid_side, "loose_mid_side");
|
DO_UPDATE (do_mid_side_stereo, mid_side, "mid_side_stereo");
|
||||||
|
DO_UPDATE (loose_mid_side_stereo, loose_mid_side, "loose_mid_side");
|
||||||
|
}
|
||||||
|
|
||||||
DO_UPDATE (blocksize, blocksize, "blocksize");
|
DO_UPDATE (blocksize, blocksize, "blocksize");
|
||||||
DO_UPDATE (max_lpc_order, max_lpc_order, "max_lpc_order");
|
DO_UPDATE (max_lpc_order, max_lpc_order, "max_lpc_order");
|
||||||
DO_UPDATE (qlp_coeff_precision, qlp_coeff_precision, "qlp_coeff_precision");
|
DO_UPDATE (qlp_coeff_precision, qlp_coeff_precision, "qlp_coeff_precision");
|
||||||
|
|
Loading…
Reference in a new issue