GNOME Bugzilla – Bug 652694
rtpvp8pay fails on error-resilient stream
Last modified: 2011-09-19 09:48:00 UTC
Current rtpvp8pay fail on this pipe: ... ! vp8enc error-resilient=true ! rtpvp8pay ! ... the reason is, this check in function gst_rtp_vp8_pay_parse_frame: if (header_size + (partitions - 1) * 3 >= GST_BUFFER_SIZE (buffer)) goto error; by stream with error-resilient=false, partitions=1, so result of this check is less then buffer_size. With error-resilient=true, usually partitions=4 (after partitions = 1 << tmp8), and the buffer size is too small. I assume: - vp8 should produce bigger buffer by samples with more then one partition. - libvpx is brocken? - rtpvp8pay should recalculate the buffer instead of fail. Any other suggestions? Regards, Alexey.
Offhand, it's probably a mistake in rtpvp8pay.
Created attachment 196169 [details] [review] rtpvp8: fix bitstream parsing using the wrong kind of bitreader VP8 uses a probabilistic bool coder, not a straight bit coder. This fixes parsing when error-resilient is set. This commit includes a copy of libvpx's bool coder, BSD licensed.
(In reply to comment #1) > Offhand, it's probably a mistake in rtpvp8pay. It was. And it took me hours of reading the spec to find out where it was going out of sync before realizing it was on the lower layer :S
Review of attachment 196169 [details] [review]: Looks good from a technical point of view but: ::: gst/rtpvp8/dboolhuff.c @@ +3,3 @@ + * + * Use of this source code is governed by a BSD-style license + * that can be found in the LICENSE file in the root of the source You have to include the LICENSE file here somewhere or copy the license into the file headers @@ +12,3 @@ +#include "dboolhuff.h" +//#include "vpx_ports/mem.h" +//#include "vpx_mem/vpx_mem.h" No // comments, even if it's code copied from somewhere else. Also, add a README file here that says where the code comes from and from where it can be synced again, also including a diff of all changes you did ::: gst/rtpvp8/dboolhuff.h @@ +17,3 @@ +//#include "vpx_ports/config.h" +//#include "vpx_ports/mem.h" +//#include "vpx/vpx_integer.h" // comments again
Created attachment 196908 [details] [review] rtpvp8: fix bitstream parsing using the wrong kind of bitreader VP8 uses a probabilistic bool coder, not a straight bit coder. This fixes parsing when error-resilient is set. This commit includes a copy of libvpx's bool coder, BSD licensed.
commit 837500af07124c19fbad891a9edf57a38d15c025 Author: Vincent Penquerc'h <vincent.penquerch@collabora.co.uk> Date: Sat Sep 10 11:31:20 2011 +0100 rtpvp8: fix bitstream parsing using the wrong kind of bitreader VP8 uses a probabilistic bool coder, not a straight bit coder. This fixes parsing when error-resilient is set. This commit includes a copy of libvpx's bool coder, BSD licensed. https://bugzilla.gnome.org/show_bug.cgi?id=652694
Thank you!