Advertisement
vliaskov

vagg: negotiation failure due to pixel-aspect-ratio

Mar 3rd, 2015
403
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.32 KB | None | 0 0
  1. Context: An app that uses gstvideoaggregator (glvideomixer) and decklinkvideosink to play multiple files seamlessly. NTSC decklink modes are tested (mode=2 of gstdecklinkvideosink here as an example)
  2.  
  3. There is an error in gst_videoaggregator_pad_sink_setcaps (gstvideoaggregator.c:799) because pixel-aspect-ratio of incoming upstream caps (1/1) is different from pixel-aspect-ratio (10/11) of vagg->priv_current_caps (set previously in gst_videoaggregator_update_src_caps).
  4.  
  5. Interestingly, the error happens only when second file plays (around the 2 second timestamp in the logs below). For the first file, gst_videoaggregator_pad_sink_setcaps is called before vagg->priv->current_caps has been set from gst_videoaggregator_update_src_caps(), and the error does not trigger (the caps set for srcpad is always the same for all files).
  6.  
  7. $ cat log-playout-mode2 | grep gst_videoaggregator_pad_sink_setcaps
  8. 0:00:00.452294552 7624 0x7f03a0002630 INFO videoaggregator gstvideoaggregator.c:787:gst_videoaggregator_pad_sink_setcaps:<video_mixer:sink_0> Setting caps video/x-raw, format=(string)I420, width=(int)512, height=(int)384, pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive, chroma-site=(string)mpeg2, colorimetry=(string)bt601, framerate=(fraction)25/1
  9. 0:00:02.375480363 7624 0x7f0344002230 INFO videoaggregator gstvideoaggregator.c:787:gst_videoaggregator_pad_sink_setcaps:<video_mixer:sink_1> Setting caps video/x-raw, format=(string)I420, width=(int)512, height=(int)384, pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive, chroma-site=(string)mpeg2, colorimetry=(string)bt601, framerate=(fraction)25/1
  10. 0:00:02.375610412 7624 0x7f0344002230 ERROR videoaggregator gstvideoaggregator.c:806:gst_videoaggregator_pad_sink_setcaps:<video_mixer:sink_1> got input caps video/x-raw, format=(string)I420, width=(int)512, height=(int)384, pixel-aspect-ratio=(fraction)1/1, interlace-mode=(string)progressive, chroma-site=(string)mpeg2, colorimetry=(string)bt601, framerate=(fraction)25/1, but current caps are video/x-raw, format=(string)UYVY, framerate=(fraction)24000/1001, width=(int)720, height=(int)486, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11, colorimetry=(string)bt601, chroma-site=(string)mpeg2
  11. 0:00:02.375673505 7624 0x7f0344002230 ERROR videoaggregator gstvideoaggregator.c:813:gst_videoaggregator_pad_sink_setcaps:<video_mixer:sink_1> input par: 1 / 1 interlace: 0, output par: 10 / 11 interlace: 0
  12.  
  13.  
  14.  
  15. $ cat log-playout-mode2 | grep gst_videoaggregator_update_src_caps
  16. 0:00:00.470479407 7624 0x1a70a80 DEBUG videoaggregator gstvideoaggregator.c:733:gst_videoaggregator_update_src_caps:<video_mixer> intersecting video/x-raw(memory:GLMemory), format=(string){ RGB, RGBx, RGBA, BGR, BGRx, BGRA, xRGB, xBGR, ARGB, ABGR, Y444, I420, YV12, Y42B, Y41B, NV12, NV21, YUY2, UYVY, AYUV, GRAY8, GRAY16_LE, GRAY16_BE, RGB16, BGR16 }, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ]; video/x-raw(memory:EGLImage), format=(string)RGBA, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ]; video/x-raw(meta:GstVideoGLTextureUploadMeta), format=(string)RGBA, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ]; video/x-raw, format=(string){ RGB, RGBx, RGBA, BGR, BGRx, BGRA, xRGB, xBGR, ARGB, ABGR, Y444, I420, YV12, Y42B, Y41B, NV12, NV21, YUY2, UYVY, AYUV, GRAY8, GRAY16_LE, GRAY16_BE, RGB16, BGR16 }, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ] with peer caps video/x-raw, format=(string)UYVY, width=(int)720, height=(int)486, framerate=(fraction)24000/1001, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11, colorimetry=(string)bt601, chroma-site=(string)mpeg2; video/x-raw, width=(int)720, height=(int)486, framerate=(fraction)24000/1001, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, NV16, NV24, GRAY8, GRAY16_BE, GRAY16_LE, v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE, I422_10LE, I422_10BE, Y444_10LE, Y444_10BE, GBR, GBR_10LE, GBR_10BE, NV12_64Z32 } result video/x-raw, format=(string)UYVY, framerate=(fraction)24000/1001, width=(int)720, height=(int)486, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11, colorimetry=(string)bt601, chroma-site=(string)mpeg2; video/x-raw, format=(string){ RGB, RGBx, RGBA, BGR, BGRx, BGRA, xRGB, xBGR, ARGB, ABGR, Y444, I420, YV12, Y42B, Y41B, NV12, NV21, YUY2, UYVY, AYUV, GRAY8, GRAY16_LE, GRAY16_BE, RGB16, BGR16 }, framerate=(fraction)24000/1001, width=(int)720, height=(int)486, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11
  17. 0:00:00.575245895 7624 0x1a70a80 DEBUG videoaggregator gstvideoaggregator.c:733:gst_videoaggregator_update_src_caps:<video_mixer> intersecting video/x-raw(memory:GLMemory), format=(string){ RGB, RGBx, RGBA, BGR, BGRx, BGRA, xRGB, xBGR, ARGB, ABGR, Y444, I420, YV12, Y42B, Y41B, NV12, NV21, YUY2, UYVY, AYUV, GRAY8, GRAY16_LE, GRAY16_BE, RGB16, BGR16 }, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ]; video/x-raw(memory:EGLImage), format=(string)RGBA, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ]; video/x-raw(meta:GstVideoGLTextureUploadMeta), format=(string)RGBA, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ]; video/x-raw, format=(string){ RGB, RGBx, RGBA, BGR, BGRx, BGRA, xRGB, xBGR, ARGB, ABGR, Y444, I420, YV12, Y42B, Y41B, NV12, NV21, YUY2, UYVY, AYUV, GRAY8, GRAY16_LE, GRAY16_BE, RGB16, BGR16 }, framerate=(fraction)[ 0/1, 2147483647/1 ], width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ] with peer caps video/x-raw, format=(string)UYVY, width=(int)720, height=(int)486, framerate=(fraction)24000/1001, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11, colorimetry=(string)bt601, chroma-site=(string)mpeg2; video/x-raw, width=(int)720, height=(int)486, framerate=(fraction)24000/1001, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11, format=(string){ I420, YV12, YUY2, UYVY, AYUV, RGBx, BGRx, xRGB, xBGR, RGBA, BGRA, ARGB, ABGR, RGB, BGR, Y41B, Y42B, YVYU, Y444, v210, v216, NV12, NV21, NV16, NV24, GRAY8, GRAY16_BE, GRAY16_LE, v308, RGB16, BGR16, RGB15, BGR15, UYVP, A420, RGB8P, YUV9, YVU9, IYU1, ARGB64, AYUV64, r210, I420_10LE, I420_10BE, I422_10LE, I422_10BE, Y444_10LE, Y444_10BE, GBR, GBR_10LE, GBR_10BE, NV12_64Z32 } result video/x-raw, format=(string)UYVY, framerate=(fraction)24000/1001, width=(int)720, height=(int)486, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11, colorimetry=(string)bt601, chroma-site=(string)mpeg2; video/x-raw, format=(string){ RGB, RGBx, RGBA, BGR, BGRx, BGRA, xRGB, xBGR, ARGB, ABGR, Y444, I420, YV12, Y42B, Y41B, NV12, NV21, YUY2, UYVY, AYUV, GRAY8, GRAY16_LE, GRAY16_BE, RGB16, BGR16 }, framerate=(fraction)24000/1001, width=(int)720, height=(int)486, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)10/11
  18.  
  19. As a result of the gst_videoaggregator_pad_sink_setcaps error, negotiation failed:
  20. 0:00:02.143449703 4789 0x7fcaa4002a30 DEBUG GST_PADS gstpad.c:5311:gst_pad_send_event_unchecked:<video_mixer:sink_1> sent event, ret not-negotiated
  21. 0:00:02.143474095 4789 0x7fcaa4002a30 DEBUG GST_PADS gstpad.c:3624:push_sticky:<bin1:ghostpad2> result not-negotiated, mark pending events
  22. 0:00:02.143537392 4789 0x1f25370 DEBUG libav gstavviddec.c:1368:gst_ffmpegviddec_video_frame:<avdec_mpeg4-1> return flow not-negotiated, len 1315
  23. 0:00:02.143552354 4789 0x1f25370 DEBUG videodecoder gstvideodecoder.c:3081:gst_video_decoder_decode_frame:<avdec_mpeg4-1> flow error not-negotiated
  24. 0:00:02.143642562 4789 0x1f36de0 INFO avidemux gstavidemux.c:5627:gst_avi_demux_loop: stream_movi flow: not-negotiated
  25.  
  26.  
  27. gst_aggregator_pad_dispose()/gst_videoaggregator_dispose() would reset vagg->priv->current_caps but I am not sure if this should be called on a running videoaggregator.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement