Open Bug 1111317 Opened 5 years ago Updated 4 years ago

Apple's h264 decoder may never release a frame under some circumstances

Categories

(Core :: Audio/Video: Playback, defect, P3)

All
macOS
defect

Tracking

()

People

(Reporter: jya, Unassigned)

References

Details

The Apple's h264 decoder is based on the VideoToolbox decoder which outputs frame in dts order.

The frames are then re-ordered according to their presentation timestamp (pts). This is done by storing the decoded frames into a heap with the pts as index.
Once we decode a frame with a dts that is inferior than the earliest pts we output that frame.

A problem introduced by this method is that should the decoder be fed with invalid pts (like much further in the future), that decoded frame will stay in our heap forever.
Perhaps we should flush if something is more than a few frames in the future, similar to the fuzz checks we're doing for MSE sample duration?
Component: Audio/Video → Audio/Video: Playback
Mass change P2 -> P3
Priority: P2 → P3
You need to log in before you can comment on or make changes to this bug.