This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Gstreamer running with DVSDK 4.01 DM365 EVM - "videotestsrc"

I am new to Gstreamer and looking for some basic testing of our DM365 EVM board.

I am running DVSDK4.01

- ti-dvsdk_dm365-evm_4_01_00_09
- linux kernel 2.6.32.17 (psp/linux-2.6.32.17-psp03.01.01.38)
- Component outputs hooked to monitor
- using NFS filesytem.

 

Following the 4.01 Software Development guide, I have successfully ran the H264 video on the display with the following command.

 

# gst-launch filesrc location=/usr/share/ti/data/videos/davincieffect.264 ! TIViddec2 codecName=h264dec engineName=codecServer ! TIDmaiVideoSink videoStd=720P_60 videoOutput=component sync=false hideOSD=true numBufs=3 useUserptrBufs=TRUE -v

 

I have tried to follow the examples listed here

 

http://processors.wiki.ti.com/index.php/Example_GStreamer_Pipelines#DM365

 

but it appears these are no longer valid with this version of Gstreamer..

 

 

So I wanted to build up the Gstreamer commands from the start and use "videotestsrc".

 

When I run

 

# gst-launch -v videotestsrc ! TIDmaiVideoSink 

           
Setting pipeline to PAUSED ...
/GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0.GstPad:src: caps = video/x-raw-yuv, format=(fourcc)UYVY, color-matrix=(string)sdtv, chroma-site=(string)mpeg2, width=(int)320, hei
ght=(int)240, framerate=(fraction)30/1
Pipeline is PREROLLING ...
/GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0.GstPad:src: caps = video/x-raw-yuv, format=(fourcc)UYVY, color-matrix=(string)sdtv, chroma-site=(string)mpeg2, width=(int)720, hei
ght=(int)480, framerate=(fraction)30/1
/GstPipeline:pipeline0/GstTIDmaiVideoSink:tidmaivideosink0.GstPad:sink: caps = video/x-raw-yuv, format=(fourcc)UYVY, color-matrix=(string)sdtv, chroma-site=(string)mpeg2, width=(int)7
20, height=(int)480, framerate=(fraction)30/1
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
delay stream on ....
davinci_v4l2 davinci_v4l2.1: sizeimage is less, 691200
ERROR: from element /GstPipeline:pipeline0/GstTIDmaiVideoSink:tidmaivideosink0: Unable to initialize display

Additional debug info:
gsttidmaivideosink.c(1657): gst_tidmaivideosink_render (): /GstPipeline:pipeline0/GstTIDmaiVideoSink:tidmaivideosink0
Execution ended after 46626249 ns.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
/GstPipeline:pipeline0/GstTIDmaiVideoSink:tidmaivideosink0.GstPad:sink: caps = NULL
/GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0.GstPad:src: caps = NULL
Setting pipeline to NULL ...
Freeing pipeline ...

It looks like its complaining the video size is too small

                  "davinci_v4l2 davinci_v4l2.1: sizeimage is less, 691200"

 

I also try

 

root@dm365-evm:~# DMAI_DEBUG=2 gst-launch -v videotestsrc ! TIDmaiVideoSink vide
oStd=720P_60 videoOutput=component sync=false
@0x0000f933:[T:0x40020630] ti.sdo.dmai - [Dmai] Dmai log level set to '2'. Note that calling CERuntime_init after this point may cause unexpected change to DMAI tracing behavior.
Setting pipeline to PAUSED ...
/GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0.GstPad:src: caps = video/x-raw-yuv, format=(fourcc)UYVY, color-matrix=(string)sdtv, chroma-site=(string)mpeg2, width=(int)320, hei
ght=(int)240, framerate=(fraction)30/1
Pipeline is PREROLLING ...
@0x00084c4f:[T:0x410ab490] ti.sdo.dmai - [BufTab] Allocating BufTab for 3 buffers
@0x00084ee0:[T:0x410ab490] ti.sdo.dmai - [Buffer] Alloc Buffer of size 153600 at 0x410ac000 (0x83c00000 phys)
@0x00085170:[T:0x410ab490] ti.sdo.dmai - [Buffer] Alloc Buffer of size 153600 at 0x410d2000 (0x83c26000 phys)
@0x00085399:[T:0x410ab490] ti.sdo.dmai - [Buffer] Alloc Buffer of size 153600 at 0x410f8000 (0x83c4c000 phys)
/GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0.GstPad:src: caps = video/x-raw-yuv, format=(fourcc)UYVY, color-matrix=(string)sdtv, chroma-site=(string)mpeg2, width=(int)1280, he
ight=(int)720, framerate=(fraction)30/1
/GstPipeline:pipeline0/GstTIDmaiVideoSink:tidmaivideosink0.GstPad:sink: caps = video/x-raw-yuv, format=(fourcc)UYVY, color-matrix=(string)sdtv, chroma-site=(string)mpeg2, width=(int)1
280, height=(int)720, framerate=(fraction)30/1
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
@0x000ef0ec:[T:0x410ab490] ti.sdo.dmai - [Buffer] Alloc Buffer of size 1843200 at 0x412e1000 (0x83c72000 phys)
New clock: GstSystemClock
delay stream on ....
@0x001148b1:[T:0davinci_v4l2 davinci_v4l2.1: sizeimage is less, 1843200
x410ab490] ti.sdo.dmai - [Display] Video output set to size 1280x720 pitch 2560 imageSize 153600
@0x001162c7:[T:0x410ab490] ti.sdo.dmai - [Display] Failed VIDIOC_S_FMT on /dev/video2 (Invalid argument)
ERROR: from element /GstPipeline:pipeline0/GstTIDmaiVideoSink:tidmaivideosink0: Unable to initialize display

Additional debug info:
gsttidmaivideosink.c(1657): gst_tidmaivideosink_render (): /GstPipeline:pipeline0/GstTIDmaiVideoSink:tidmaivideosink0
Execution ended after 161664167 ns.
Setting pipeline to PAUSED ...
@0x0011692e:[T:0x410ab490] ti.sdo.dmai - [Buffer] Free Buffer of size 153600 at 0x410ac000 (0x83c00000 phys)
@0x001194c1:[T:0x410ab490] ti.sdo.dmai - [Buffer] Free Buffer of size 153600 at 0x410d2000 (0x83c26000 phys)
@0x00119803:[T:0x410ab490] ti.sdo.dmai - [Buffer] Free Buffer of size 153600 at 0x410f8000 (0x83c4c000 phys)
@0x00119bb0:[T:0x410ab490] ti.sdo.dmai - [Buffer] Free Buffer of size 1843200 at 0x412e1000 (0x83c72000 phys)
Setting pipeline to READY ...
/GstPipeline:pipeline0/GstTIDmaiVideoSink:tidmaivideosink0.GstPad:sink: caps = NULL
/GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0.GstPad:src: caps = NULL
Setting pipeline to NULL ...
Freeing pipeline ...

 

 

Can you please comment on what I need to do to get this to work? Is this a bug or lack of documentation and understanding.

 

Thanks

 

 

 

 

  • Bill,

    Most of the pipelines listed on the below wiki page applies to Gstreamer-ti release versions  and inside DVSDK we are using a snapshot version from trunk and hence all the pipelines listed on wiki may not work off the box. Please note that release version of gst-ti is somewhat a bit old and because of this we took snapshot during DVSDK release.

    http://processors.wiki.ti.com/index.php/Example_GStreamer_Pipelines#DM365

     

    And as per your videotestsrc pipeline is concerned,  by default TIDmaiVideoSink uses driver allocated buffer but default dvsdk memory map does not reverse the required kernel memory in its bootargs (this is mainly because most of time you will use user allocated buffer) and the latest changes in gst-ti trunk supports userAllocated buffer in TIDmaiVideoSink and this can be enabled by passing "userUserptrBufs=true numBufs=3" property.

     

    As per the explanation, the below pipeline should work

     

    # gst-launch videotestsrc  peer-alloc=false ! TIDmaiVideoSink userUserptrBufs=true numBufs=3 videoStd=720P_60 videoOutput=component

     

    HTH.

    Thanks

    Brijesh

  • BTW, there was small typo, the property is called "useUserptrBufs"

    Thanks

    Brijesh