Media (Intel® Video Processing Library, Intel Media SDK)
Access community support with transcoding, decoding, and encoding in applications using media tools like Intel® oneAPI Video Processing Library and Intel® Media SDK
Announcements
The Intel Media SDK project is no longer active. For continued support and access to new features, Intel Media SDK users are encouraged to read the transition guide on upgrading from Intel® Media SDK to Intel® Video Processing Library (VPL), and to move to VPL as soon as possible.
For more information, see the VPL website.

PixelAlphaEnable

BMart1
New Contributor II
576 Views
Hi, Is there any sample using per pixel alpha compositing via PixelAlphaEnable? I understand only the linux sdk supports it at the moment. I read the samples but couldn't understand where alpha is stored in a nv12/rgb sample. Shouldn't it be rgba? Bruno
0 Kudos
2 Replies
Sravanthi_K_Intel
576 Views

The sample_vpp application is a good example of Composition. In that sample, ParseCompositionParfile() (in sample_vpp_parser.cpp and sample_vpp_utils.cpp) accepts PixelAlphaEnable as one of the inputs from the par file. So, if your input is in RGB colorspace and you provide the PixelAlphaEnable, that should enable the alpha blending in composition.

Here is how a sample par file looks like:

stream=/home/lmsdk/Videos/in_352_288.yuv
width=352
height=288
cropx=0
cropy=0
cropw=352
croph=288
dstx=0
dsty=0
dstw=352
dsth=288
fourcc=nv12

stream=/home/lmsdk/Videos/in_176_144.rgb
width=176
height=144
cropx=0
cropy=0
cropw=100
croph=100
dstx=0
dsty=0
dstw=100
dsth=100
fourcc=rgb4
PixelAlphaEnable=128

0 Kudos
zhou_i_
Beginner
576 Views

As I have tried,if you want to use alpha channel in RGBA,two input source must all be RGBA,and set PixelAlphaEnable = 1

0 Kudos
Reply