can not link audio volume element to audio bin

cfd new newcfd at
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" );
                    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: <>

More information about the gstreamer-devel mailing list