Reputation: 922
In a H.264 stream just containing I-frames and P-frames I wonder if, in packet loss presence, would be possible to interpolate any lost P-frame in a "relatively easy way".
Imagine: I P P P ... (original) --> I X P P ... (received)
I P P P ... --> I P X P... and so on...
Looking at the H.264 diagram block it does not seem so easy...(e.g. High-Profile block diagram).
Currently, I am working with H.264 dynamic payload types 96 and 97; Baseline and High Video Profiles just for receiving video, in case it helps.
Upvotes: 0
Views: 466
Reputation: 430
If the entire frame is lost, the short answer: no, there’s no “relatively easy way”. Even if you employ every H264 error concealment trick, you’ll end up with lost pixel data subsequent P frames refer to, and visually unpleasant results.
Now, it’s very rare to lose the entire frame. If the packet loss is so severe, the best way to recover would be to retransmit lost packets (if latency allows) or even ask the server for new I frame (I assume that you have robust network stack with feedback loop to the server).
To solve packet loss problems, is much better is to focus on resilience and data redundancy. I highly recommend presentation Error resiliency and concealment in h264 and another paper on the same subject - they describe many mitigation techniques like flexible macroblock/slice ordering and redundant slices. Unfortunately, I cannot provide links to the existing implementations - real time video streaming is a very narrow field, and all companies who run active research and development keep their implementations secret.
Upvotes: 1