AW: AW: gstreamer - how to convert .ts to .mkv or .mp4 with sound

fufu5000 kazuko.nakamura at interia.pl
Wed Oct 18 09:46:30 UTC 2017


Thanks Ian, 

Is some progress :)

This command is working:

gst-launch-1.0 filesrc location=1.ts \
! decodebin name=demux demux. \
! queue \
! audioresample \
! "audio/x-raw,rate=44100" \
! audioconvert \
! "audio/x-raw,format=F32LE" \
! vorbisenc \
! mux. matroskamux name=mux \
! filesink location=1.mkv demux. \
! queue \
! videoconvert \
! videoscale \
! omxh264enc target-bitrate=1572864 control-rate=variable \
!
video/x-h264,stream-format=byte-stream,profile=high,width=480,height=270,framerate=25/1
\
! h264parse \
! mux.

Video is with changed bitrate and is scalled to 480x270

But.... Now I have problem with performance on RPi2. If I take above
command, transcoding 40 seconds .ts file takes about 4 minutes.

If I take this command on the same .ts file:

gst-launch-1.0 -v filesrc location=1.ts \
! tsdemux parse-private-sections=false name=demux \
! queue \
! ac3parse \
! matroskamux name=stream streamable=true demux. \
! queue \
! h264parse \
! omxh264dec \
! omxh264enc target-bitrate=1572864 control-rate=variable \
!
video/x-h264,stream-format=byte-stream,profile=high,width=480,height=270,framerate=25/1
\
! h264parse \
! filesink location=1.mkv

conversion takes just 20 seconds.



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/


More information about the gstreamer-devel mailing list