Hi Ti Team,
We use the H264 video decoding plugin using the Ducati plugin for decoding video and want to play this accelerated in our QT application. Running, decoding and displaying the video using Gstreamer pipeline seems to work just fine:
gst-launch-1.0 filesrc location=/big_buck_bunny_720x480_H264_AAC_25fps.mkv ! matroskademux ! h264parse ! ducatih264dec ! kmssink
When using Qt, we notice that QT tries to set the sink to qmlsink or any other. When using the Qt examples that you use in the SDK we see that we get a screen with green edges (same as refered to in https://e2e.ti.com/support/processors/f/791/t/550005?Artifacts-on-H-264-videos-playing-on-Qt5 )
It seems that Matroska Demux in the pipeline detects that the input image is the correct width and height:
0:00:02.431555642 274 0x107a60 INFO matroskademux matroska-demux.c:1500:gst_matroska_demux_add_stream:<matroskademux0> Adding pad 'video_0' with caps video/x-h264, level=(string)3, profile=(string)main, codec_data=(buffer)014d401effe10018674d401eda02d0f6c044000003000400000300c83c58ba8001000468ef3c80, stream-format=(string)avc, alignment=(string)au, width=(int)720, height=(int)480, pixel-aspect-ratio=(fraction)1/1, framerate=(fraction)25/1
Ducati plugin also seems to detect this pretty good:
video/x-raw, framerate=(fraction)25/1, width=(int)896, height=(int)576, pixel-aspect-ratio=(fraction)1/1, drm_mem=(boolean)true, max-ref-frames=(int)18, format=(string)NV12, interlace-mode=(string)progressive
0:00:26.401782107 292 0xb1434fb0 INFO ducati gstducatividdec.c:692:codec_process:<ducatih264dec0> active frame region 32, 24, 752, 504, crop 720x480
But when using QT; it seems that this cropping is not done:
video/x-raw, framerate=(fraction)25/1, width=(int)896, height=(int)576, pixel-aspect-ratio=(fraction)1/1, drm_mem=(boolean)true, max-ref-frames=(int)18, format=(string)NV12, interlace-mode=(string)progressive
Which is identical in both cases. so the difference seems to be in the videosink (kmssink vs qt (some) sink)??
Performance between QT and Native GStreamer
Also performance seems to be an issue, when using the gst-launch or playbin i see an CPU load of roughly 3 / 5% as i would expect on the AM5708 with Hardware video decoding, but when displaying via Qt i see about 70% CPU load and also memory load very high.
Could you help us out here?