Hi,<br><br>I've written an test application to play .mp4 video files. The pipeline is : filesrc -> qtdemux -> ffdec_mpeg4 -> sdlvideosink. The pipeline is working fine. Now I want to have runtime video scaling. So I included videoscale in between ffdec_mpeg4 and sdlvideoscale. When I set the caps of videoscale src pad while creating the pipeline, I can set different video sizes. However I want to know how I can reset the video size to a different heightXwidth when the pipeline in already playing (say, after 3 seconds of playback, the video size should become half of original size). I have a callback registered, which gets called after 3 seconds. Inside the callback, I'm trying to set the caps of the videoscale src pad, but its not working. The video is playing for first 3 seconds and then getting EOS. Can someone please let me know the correct method to achive my goal?
<br><br>Given below is my callback code...<br><br>Callback function (input : height, width of the original video)<br>----------<br>...<br>pad = gst_element_get_pad(videoscale, "src");<br><br>newpadcaps = gst_caps_new_simple("video/x-raw-yuv",
<br> "format", GST_TYPE_FOURCC, GST_MAKE_FOURCC('I', '4', '2', '0'),<br> "width", G_TYPE_INT, (width/2),<br> "height", G_TYPE_INT, (height/2),
<br> "framerate", GST_TYPE_FRACTION, 15,1,<br> NULL);<br><br>gst_pad_set_caps (pad, newpadcaps);<br>return FALSE;<br><br>......Do I need to do something additional (like pausing the pipeline before changing caps, or unlinking-relinking the videoscale element)? Couldn't find much documentation on the topic.
<br><br>
Thanks in advance for your time :)<br>
<br>...Romit<br>