[Bug 730783] bytereader: Improve the performance to find start code for H.264 and H.265
GStreamer (bugzilla.gnome.org)
bugzilla at gnome.org
Fri May 30 01:39:39 PDT 2014
https://bugzilla.gnome.org/show_bug.cgi?id=730783
GStreamer | gstreamer (core) | git
--- Comment #11 from Sungho Bae <baver.bae at lge.com> 2014-05-30 08:39:35 UTC ---
(In reply to comment #9)
> The problem that Nicolas is pointing out is the following:
>
> Say your full stream is what you mentioned and it comes into h264parse as two
> buffers
>
> +----------+--------------------+----------+---------------+--------+
> | 0x000001 | current nal unit | 0x000001 | next nal unit | .... |
> +----------+--------------------+----------+---------------+--------+
> \______________________________/ \________________________/ ...
> First Buffer Second Buffer
>
> What Nicolas meant that it doesn't keep context is that, for each buffer,
> h264parse will look for the first start_code (trivial), and then the next one
> (as you mentioned, to know how big the NALU is).
>
> +----------+--------------------+
> | 0x000001 | current nal unit |
> +----------+--------------------+
> ^
> ^
> h264parse scans all the way to the end of the buffer...
> but then doesn't remember it already scanned when the next buffer comes round
>
> 2nd buffer comes in, 1st one is still in the parser, we now have:
>
> +----------+--------------------+----------+---------------+
> | 0x000001 | pending nal unit | 0x000001 | next nal unit |
> +----------+--------------------+----------+---------------+
> ^ ^
> A B
>
> h264parse will resume parsing from offset A instead of resuming it from offset
> B... resulting in scanning *twice* the nal unit
That's correct! That is what I guess the cause of the problem.
I'm currently reviewing h264parse plugin related to the problem.
Once I solve the problem, I will report it by another thread with patch files.
--
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.
More information about the gstreamer-bugs
mailing list