[Gstreamer, again...] Unable to change framerate on flvdemux

Hi all,
I’m trying to decode flv packets from an RTMP and change framrate, unfortunately it returns an error:

this is my pipeline:

gst-launch-1.0 rtmpsrc location=rtmp://127.0.0.1/source/camera1 ! flvdemux ! h264parse ! nvv4l2decoder ! nvvidconv ! videorate ! video/x-raw,framerate=5/1 ! nvvidconv ! "video/x-raw(memory:NVMM), width=(int)512, height=(int)512, pixel-aspect-ratio=1/1" ! nvvidconv ! video/x-raw,format=BGRx ! videoconvert ! video/x-raw,format=BGR ! appsink sync=true

and returns:

Setting pipeline to PAUSED ...
Opening in BLOCKING MODE
Pipeline is PREROLLING ...
ERROR: from element /GstPipeline:pipeline0/GstRTMPSrc:rtmpsrc0: Internal data stream error.
Additional debug info:
gstbasesrc.c(3055): gst_base_src_loop (): /GstPipeline:pipeline0/GstRTMPSrc:rtmpsrc0:
streaming stopped, reason not-linked (-1)
ERROR: pipeline doesn't want to preroll.
Setting pipeline to NULL ...
Freeing pipeline ...

if I remove “nvvidconv ! videorate ! video/x-raw,framerate=5/1 !”, so:

gst-launch-1.0 rtmpsrc location=rtmp://127.0.0.1/source/camera1 ! flvdemux ! h264parse ! nvv4l2decoder ! nvvidconv ! "video/x-raw(memory:NVMM), width=(int)512, height=(int)512, pixel-aspect-ratio=1/1" ! nvvidconv ! video/x-raw,format=BGRx ! videoconvert ! video/x-raw,format=BGR ! appsink sync=true

works correctly.

I’m using node-media-server al relay from RTSP to RTMP, it greps RTSP packets and packs them in FLV using ffmpeg with this command:



ffmpeg -rtsp_transport tcp -fflags nobuffer -i rtsp://admin:Password@192.168.0.204:554/ -c copy -f flv rtmp://127.0.0.1:1935/source/camera1

Any idea to solve this issue? I need to change framerate to 5fps.

PS: if I use gst-discoverer-1.0 I get this result:

gst-discoverer-1.0 rtmp://127.0.0.1/source/camera1
Analyzing rtmp://127.0.0.1/source/camera1
Opening in BLOCKING MODE
NvMMLiteOpen : Block : BlockType = 261
NVMEDIA: Reading vendor.tegra.display-size : status: 6
NvMMLiteBlockCreate : Block : BlockType = 261
Done discovering rtmp://127.0.0.1/source/camera1

Topology:
  container: Flash
    video: H.264 (Main Profile)

Properties:
  Duration: 99:99:99.999999999
  Seekable: yes
  Live: no
  Tags:
      duration: 0
      title: Media Server
      video codec: H.264
      nominal bitrate: 0

I don’t know why but results not “Live”

Find the solution myself, it must be:

nvvidconv ! videorate ! video/x-raw<b>(memory:NVMM)</b>,framerate=5/1 !

Hi,
We don’t touch framerate in NVIDIA plugins. You may check if native gstreamer plugins can support this case.

Please go to http://gstreamer-devel.966125.n4.nabble.com/
And ask with software decoder/converter pipeline:

gst-launch-1.0 rtmpsrc location=rtmp://127.0.0.1/source/camera1 ! flvdemux ! h264parse ! avdec_h264 ! videorate ! video/x-raw,framerate=5/1 ! videoscale ! video/x-raw, width=(int)512, height=(int)512 ! videoconvert ! video/x-raw,format=BGR ! appsink sync=true

Once you get suggestion on the pipeline, please replace software decoder/converter with nvv4l2decoder/nvvidconv.

Well I can assure that works using nvvidconv :)