GNOME Bugzilla – Bug 564501
[rtph264pay] bytestream scan mode operation is not reliable
Last modified: 2009-08-06 09:21:47 UTC
Please describe the problem: rtph264pay has following bugs: - If SPS & PPS are in one payload, it fails to collect them. only first seen NAL is used for generating sprop_parameter_sets. - constructor forgot to initialize variables properly :) Steps to reproduce: 1. 2. 3. Actual results: Expected results: Does this happen every time? Other information:
Created attachment 124658 [details] [review] fixes this bug on more thing: - do not update output caps until we receive both SPS and PPS.
Created attachment 124778 [details] [review] fixes not to push packets before caps updated previous patch did allow packets pushed before we have analyzed all the NALS in one buffer. This patch simply collects NALs, and push them at the end of the buffer processing.
Created attachment 124781 [details] [review] oops oops, some mistake;;
I have some objections: - please make a patch with diff -u - The constructor in GObject initializes instance variables to 0 automatically. - Creating and destroying the nal_queue for each packet is too slow. - casting the gint to a gpointer to add it to the queue is not portable and does not compile on my machine. Surely there must be an easier way to delay setting the caps until both SPS and PPS are found, like with a simple flag or so...
Created attachment 136836 [details] [review] Modified patch Scan incoming bytestream buffer for SPS and PPS, then set caps, and only then push outgoing packets.
Re-opening, since updated patch available now. Is this something we should try to get into the upcoming -good release? Is this something that could be reproduced with a quite small sample file by any chance? (if yes, I might whip up a unit test)
commit 2bfb42c5f8ffec7fa15666b1e6072ae11700a427 Author: Mark Nauwelaerts <mark.nauwelaerts@collabora.co.uk> Date: Mon Aug 3 18:55:19 2009 +0200 rtph264pay: push NALs only after SPS/PPS parse complete (bytestream) buffer for SPS/PPS before pushing NALs. Fixes #564501.