can not link audio volume element to audio bin

cfd new newcfd at yahoo.com
Thu Nov 17 00:07:07 UTC 2022


following the link here: Linking audio and video bins with gstreamer in c
to build audio bin. 
    /*audio bin*/
    audio = gst_bin_new ("audiobin");
    audioQueue = gst_element_factory_make ("queue", "audio-queue");
    audioDepay = gst_element_factory_make ("rtpmp4gdepay", "audio-depayer");
    audioParse = gst_element_factory_make ("aacparse", "audio-parser");
    audioDecode = gst_element_factory_make ("avdec_aac", "audio-decoder");
    audioConvert = gst_element_factory_make ("audioconvert", "aconv");
    audioResample = gst_element_factory_make ("audioresample", "audio-resample");
    audioSink = gst_element_factory_make ("autoaudiosink", "audiosink");
    audioVolume = gst_element_factory_make( "volume", "audiovolume" );
    gst_bin_add_many(GST_BIN(audio),
                    audioQueue, audioVolume, audioDepay, audioParse, audioDecode,audioConvert, audioResample, audioSink, NULL);
But I can not link volume element
 /*Linking audio elements internally*/ if (!gst_element_link_many(audioQueue, audioVolume, audioDepay, audioParse, audioDecode, audioConvert, audioResample, audioSink, NULL)) { g_printerr("Cannot link audioDepay and audioParse \n"); return 0; }
gst_element_link_many returns false. Without volume element, the pipeline works fine, But I can not change volume. Any idea about what is wrong?
without audiobin, volume element can be added to the pipeline and also no problem for link to audioQueue and changing volume works fine.


 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20221117/2bf73da0/attachment.htm>


More information about the gstreamer-devel mailing list