rpicamsrc: Buffer has no PTS

Jan Schmidt jan at widgetgrove.com.au
Wed Jan 11 06:59:35 UTC 2023


Hi,

Remove the 'do-timestamp=true' and 'inline-headers=true' from rpicamsrc

  It will apply timestamps automatically, so doesn't need 
`do-timestamp=true`

Sending `inline-headers=true` adds the packets with no timestamps, and 
h264parse isn't removing them - but you don't need inline-headers when 
muxing to mp4.

This works fine:

gst-launch-1.0 -e rpicamsrc preview=false keyframe-interval=30 ! 
video/x-h264,width=640,height=480,framerate=30/1,profile=high ! 
h264parse ! mp4mux ! filesink location=/tmp/tmp.mp4

Cheers,

Jan.

On 11/1/23 05:11, Abu Abdullah via gstreamer-devel wrote:
> my apologies to miss the response below. I can see some timestamp
> seems off with all 9's
>
> $ gst-launch-1.0 rpicamsrc do-timestamp=true inline-headers=true
> preview=false keyframe-interval=30 !
> video/x-h264,width=640,height=480,framerate=30/1,profile=high !
> h264parse ! tee name=t t. ! queue ! checksumsink
> Setting pipeline to PAUSED ...
> Pipeline is live and does not need PREROLL ...
> Pipeline is PREROLLED ...
> Setting pipeline to PLAYING ...
> New clock: GstSystemClock
> Redistribute latency...
> Redistribute latency...
> 0:00:00.000000000 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.000000000 e2c85424c8c8842cc6519c293ec840980d9a214a
> 0:00:00.000000000 e8f014a728879f8af8b12d44485baea68fc96313
> 0:00:00.243818904 fe007421276f9154fa7ef80a71faffac4f7930f2
> 0:00:00.277148659 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.277148659 dea40cfaef6aea633b9e4fe651be8597dfaf7c4c
> 0:00:00.310474409 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.310474409 395015f0d28580ac001795e7f462e2f9167e5240
> 0:00:00.343803159 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.343803159 f4e4ff7d2543145e01b49c9bcbc13852f846c3ac
> 0:00:00.377129902 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.377129902 0e5f0d1fe392bb47d3a324942cbb1922caa27f44
> 0:00:00.410451650 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.410451650 0421319fccd2625e5afad132947cc5f124960145
> 0:00:00.443771408 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.443771408 53bd3b1247e2b45775fae63376024660e2c25e56
> 0:00:00.477109154 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.477109154 5fe550c458d66af365dcff5305149806132cfc7b
> 0:00:00.510441904 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.510441904 98ac98390d21217ed7d9783c15b4b52671b8fff7
> 0:00:00.543753655 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.543753655 33e970961343fe9d6bf74422381f5fa12c4c30d6
> 0:00:00.577087394 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.577087394 d2c87cff29ac62c4b91b43b0fae44746355c689c
> 0:00:00.610417153 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.610417153 dd7657367c9f58697e47da7d2d841a069c7273cb
> 0:00:00.643744902 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.643744902 b432bfe4121bfa4d937a3dc341f735d73d1e8b4f
> 0:00:00.677067649 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.677067649 7c540d214d254d20d59d33ba70a3550cd9e118bf
> 0:00:00.710397400 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.710397400 abc7f5dfd8fda0d6e7de3a4d4915675ed564d0b7
> 0:00:00.743720139 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.743720139 0ceb3df525b4a1c8296b3591c7eff33b1c864dcc
> 0:00:00.777051896 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.777051896 7b3bf25b8b50e20365414f336bae21a3992c83d4
> 0:00:00.810378647 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.810378647 984711a6f3f9b54145143ef72e68ca03d2af9ea5
> 0:00:00.843705396 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.843705396 803844cbe495aac646ce9d80dbd79e7dde05ecc6
> 0:00:00.877031143 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.877031143 5e497e9f9cfe3bd4d53fe983a051076120abe2ca
> 0:00:00.910353887 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.910353887 80c3bbfde2b18752fe8d919d246861d8989fd5fb
> 0:00:00.943686646 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.943686646 e498e6a96f353e039f89537dfae8c61ae1be6e00
> 0:00:00.977003385 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:00.977003385 32d470d3e5c495d670e96fd025148ea0d472a6c8
> 0:00:01.010332140 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:01.010332140 bb558ac322550b0cc37d3c9e90187831c0d6180f
> 0:00:01.043661889 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:01.043661889 9b78ada08a2c8ac0ca85dd8a3aadf596ca86117f
> 0:00:01.076982623 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:01.076982623 626b913a4765b966083d89aae714c20373e2aef5
> 0:00:01.110311387 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:01.110311387 6b41b96ed1ae979da61e5475ddbd1cbb96ebf587
> 0:00:01.143642136 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:01.143642136 ee6e31618d4245b7e7cb8df65f279e1f852b0786
> 0:00:01.176964881 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:01.176964881 7cdc4843079c6f9f8cd7e9fbe9a1583fec5ed201
> 0:00:01.210291630 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:01.210291630 b1ffb2a6d38cbe193209e28bff0f94d1108ba235
> 99:99:99.999999999 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 99:99:99.999999999 e2c85424c8c8842cc6519c293ec840980d9a214a
> 99:99:99.999999999 e8f014a728879f8af8b12d44485baea68fc96313
> 0:00:01.243617361 cd5ffecc4e20cfc460d4052226fa2d4545d6d52e
> 0:00:01.276944128 1e6c932f8eca3a6ac9ca9916ca1312ba30809cb4
> 0:00:01.276944128 b4305711d1edcdc2847e7317421f09fac2fd090f
>
>
>
> On Tue, Oct 18, 2022 at 10:29 PM vinod kesti <vinodkesti at yahoo.com> wrote:
>> This error could be due to a wrong or negative timestamp.
>>
>> Do you see any problem in timestamp issue with below command
>> gst-launch-1.0 rpicamsrc do-timestamp=true inline-headers=true
>> preview=false keyframe-interval=30 !
>> video/x-h264,width=640,height=480,framerate=30/1,profile=high !
>> h264parse ! tee name=t t. ! queue ! checksumsink
>>
>>
>> Sent from Yahoo Mail. Get the app
>>
>>
>> On Wednesday, 12 October, 2022 at 07:51:33 am GMT-5, Abu Abdullah via gstreamer-devel <gstreamer-devel at lists.freedesktop.org> wrote:
>>
>>
>> Hi,
>>
>> i have this pipeline:
>> gst-launch-1.0 rpicamsrc do-timestamp=true inline-headers=true
>> preview=false keyframe-interval=30 !
>> video/x-h264,width=640,height=480,framerate=30/1,profile=high !
>> h264parse ! tee name=t t. ! queue ! splitmuxsink
>> location=/home/pi/snapshots_tmp/snap_%03d.mp4
>> max-size-time=30000000000 max-size-bytes=2000000 t. ! queue ! hlssink
>> max-files=5 target-duration=5
>> location=/home/pi/snapshots_tmp/segment_%05d.ts
>> playlist-location=/home/pi/snapshots_tmp/playlist.m3u8
>>
>> it throughs this error:
>> ERROR: from element
>> /GstPipeline:pipeline0/GstSplitMuxSink:splitmuxsink0/GstMP4Mux:muxer:
>> Could not multiplex stream.
>> Additional debug info:
>> ../gst/isomp4/gstqtmux.c(5402): gst_qt_mux_add_buffer ():
>> /GstPipeline:pipeline0/GstSplitMuxSink:splitmuxsink0/GstMP4Mux:muxer:
>> Buffer has no PTS.
>>
>> if i remove 'inline-headers=true' it works fine but the hls segments
>> are not playable in the browser, im using hls.js and it throughs a
>> bunch of errors. hls only works with inline-headers=true
>>
>> any support is appreciated


More information about the gstreamer-devel mailing list