intel / libvpl

Intel® Video Processing Library (Intel® VPL) API, dispatcher, and examples
https://intel.github.io/libvpl/
MIT License
275 stars 84 forks source link

hello-decvpp example question #120

Closed llin60 closed 7 months ago

llin60 commented 8 months ago

Hi, I'm looking at the samples and noticed that hello-decvpp uses a set of combined function (such as MFXVideoDECODE_VPP_Init) that seems to be designed specifically for decode+vpp. Is there any particular reason that you provide these MFXVideoDECODE_VPP* interfaces? If I want to do some post-processing after decode, what is the difference between: option 1.using MFXVideoDECODE_VPP_Init , and option 2. using a MFXVideoDECODE_Init and a MFXVideoVPP_Init, then run frame processing async respectively for decode and vpp?

shepark commented 7 months ago

Hi @llin60 There's no difference in runtime level (performance) with separate processing with DECODE and VPP. It manages decode and vpp session internally, https://github.com/oneapi-src/oneVPL-intel-gpu/blob/02b3a2bd5896361de6d34bc87d2258f9642d6b42/_studio/mfx_lib/shared/src/libmfxsw_decode_vp.cpp#L52 The goal for this DECODE_VPP is to provide easy configuration for N x (decode + vpp), For example, input resolution is 1920x1080/nv12 and if you want to have multiple output size/csc (320x240/bgra, 1280x720/i420). If you implement this with separate Decode / VPP functions/params, then it's going to be huge lines. But, you can implement this with much simpler/shorter lines. This DECODE_VPP supports limited functionality for now, like resize/csc.

llin60 commented 7 months ago

Thanks for the answer. Understood.