i.MX6: Alpha blending example code

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

i.MX6: Alpha blending example code

6,349 次查看
ganesank
Contributor III

I was looking for good examples to understand alpha blending methods supported in i.MX6. I got one good example which is operating at IPU driver level but not at frame-buffer level. After lot of searches in google and trying bits and pieces of code based on i.MX6 reference manual and i.MX6 Linux reference manual I developed test code for three types of alpha blending,

  • Global alpha blending
  • Local alpha blending with alpha values passed in a separate buffer (24-bit bpp)
  • Local alpha with alpha value in pixels (32-bit bpp Ex. RGBA/BGRA)

 

I could test this code on the target and it helped me to understand those methods better. I am sharing my test code here so that it will be useful to anyone in the community. Enable one of the alpha methods at the compile time and run it on the target.

 

Regards,

Ganesan. K

Original Attachment has been moved to: imx6_alpha_blending_example.c.zip

9 回复数

2,403 次查看
jiangyaqiang
Contributor V

HI ganesank:

 

  Does your  test example "imx6_alpha_blending_example.c.zip"   still be ? I could not downlaod it , could you please send my one ? 

  thanks.

0 项奖励
回复

3,993 次查看
rans
Senior Contributor I

Hello Ganesan,

Thank you very much for the examples !

Do you think it should also function for RGBA6666 too ?

I need to use LVDS output, and I only find that several people tried to do it, but it seems that no one had much success:

RGBA/ARGB LVDS output from i.MX6 

I also find the following examples:

ipu-examples - i.MX IPU Examples 

But it seems that RGBA is allways 8888 in these examples, and there is no RGBA6666.

I also don't find RGBA666 in the header file of IPU

Linux source code: arch/arm/plat-mxc/include/mach/ipu.h (v3.6) - Bootlin 

Thank you for the time,

ranran

0 项奖励
回复

3,993 次查看
jamesmin
Contributor II

Thank you for the reply Ganesan.

Also your test code works find to me as well.

0 项奖励
回复

3,993 次查看
zhengl
Contributor II

What kernel version are you using for alpha in pixels, I found alpha in pixels is not used in MXCFB_SET_LOC_ALPHA  kernel code of 4.14.98.

3,993 次查看
rans
Senior Contributor I

Hello Zheng,

Not sure I understand... Is it possible to do alpha blending with imx6 ?
As far as I understand from previous answers this feature is not supported,

So, did you manage to do alpha blending with imx6 ? How ?

Thanks

0 项奖励
回复

3,993 次查看
jamesmin
Contributor II

Hi Ganesan, Can I ask which Kernel version are you using for this test code?

I am trying to run this for alpha in pixels but it doesn't work.

I am thinking I might need right kernel version. My kernel is 3.14.28.

0 项奖励
回复

3,993 次查看
ganesank
Contributor III

The kernel version is 3.10.17

0 项奖励
回复

3,993 次查看
ganesank
Contributor III

I used kernel headers for mxcfb.h in my test code. I don't know how to make this available in the user space in the Yocto build framework. Has anyone done it so far? Is there a patch to export this header to sysroots/

0 项奖励
回复

3,993 次查看
Yuri
NXP Employee
NXP Employee

Great !

0 项奖励
回复