Variable framerate (VFR) encoding

Variable framerate (VFR) encoding

Portrait de froueint

I'm encoding frames using the H.264 encoder. The frames don't come at fixed intervals and so I set the mfxFrameSurface1::Data::TimeStamp parameter to the actual time that each frame was submitted before passing it to the VPP and encoder. This seems to work, however, I'm trying to figure out what is the correct setting for FrameRateExtN/FrameRateExtD parameters when I initialize the encoder in this case. Changing these parameters seems to affect output size but I don't know how these parameters are interpreted in this situation where the framerate is variable and I'm explicitly setting the timestamp of each frame.

Thanks for your help.

3 posts / 0 nouveau(x)
Dernière contribution
Reportez-vous à notre Notice d'optimisation pour plus d'informations sur les choix et l'optimisation des performances dans les produits logiciels Intel.
Portrait de Tony Pabon (Intel)
Best Reply

Hi,

When using VPP, the MediaSDK attempts to produce output frames that are intended to be viewed atthe rate specified by FrameRateExtN/FrameRateExtD. For any frame these values are compared with the input to see if frame rate conversion (FRC) is needed. The MediaSDK VPP FRC filter will add (duplicate) or drop frames to create output stream that represents the same period of time as the input stream. Please see section 4.9 of the "Intel_Media_Developers_Guide.pdf" to understand how this filter gets invoked.

Hope this helps.
-Tony

-Tony
Portrait de froueint

Thanks for the quick response Tony. I think I need to basically do what the MFXVideoVPPEx sample is doing (i.e. doing FRC based on incoming timestamps).

Cheers,
Farhad

Connectez-vous pour laisser un commentaire.