<div dir="ltr">I have a program that works. It receives a video stream to a vpudec (from rtsp), and then we pull a frame off using "glfilterbin" and "glbox". The problem is that it keeps the aspect ratio (300x168 from 4K) but it seems the powers-at-be would like it simply scaled to 300x300, so no aspect ratio.<div><br></div><div>Snippet:</div><div>...</div><div> GstElement *filter_ele = add_element("glfilterbin");<br>     GstElement *box_ele = gst_element_factory_make("glbox", NULL);<br>      g_object_set(filter_ele, "filter", box_ele, NULL);<br>  gst_element_link(dec_ele, filter_ele);<br><br>      appsink_ele_ = add_element("appsink");<br>      g_object_set(appsink_ele_, "emit-signals", TRUE, NULL);<br>     g_signal_connect(appsink_ele_, "new-sample", G_CALLBACK(on_sample_handler), this);<br>  target_width_ = w;<br>    target_height_ = h;<br><br> std::ostringstream oss;<br>       oss << "video/x-raw, format=RGB, width=" << w << ", height=" << h;<br>        GstCaps *caps = gst_caps_from_string(oss.str().c_str());<br>      g_object_set(appsink_ele_, "caps", caps, NULL);<br>     gst_caps_unref(caps);<br> gst_element_link(filter_ele, appsink_ele_);<br></div><div>...</div><div><br></div><div>Is there a replacement for glfilterbin and/or glbox that can just scale the video to 300x300?</div><div><br></div><div>Thanks<br></div><div><div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div><br></div>Floyd Brown<br><br></div></div></div></div></div>