[regression] baseparse cache fix breaks h264parse and h265parse
gst-launch-1.0 -vf filesrc location=h264/alphaconformanceG.264 ! h264parse ! fakesink
ERROR:../gst/videoparsers/gsth264parse.c:1315:gst_h264_parse_handle_frame: assertion failed: (current_off < size)
commit e906197c622725e48b6250a71a922d45b006fb14 Author: Jan Schmidt <firstname.lastname@example.org> Date: Wed Apr 1 02:36:40 2020 +1100 baseparse: Fix upstream read caching When running in pull mode (for e.g. mp3 reading), baseparse currently reads 64KB from upstream, then mp3parse consumes typically around 417/418 bytes of it. Then on the next loop, it will read a full fresh 64KB again, which is a big waste. Fix the read loop to use the available cache buffer first before going for more data, until the cache drops to < 1KB. Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/issues/518
Reverting this commit fixes the regression.
Also seeing similar error with some