Setting alpha channel in PixMap

16 views
Skip to first unread message

prana...@gmail.com

unread,
Jan 8, 2019, 6:36:53 AM1/8/19
to
Hi,

My display supports 32-bit visuals. I have alpha channel information for every pixel in the pixmap. I want to know if it is possible to initialize this pixmap directly pixel-by-pixel? Or, do I need to create an XImage, set alpha channel there and call XPutImage?, If so, could anyone please share the code to create XImage with alpha channel information.

More specific details: I want to implement edge-blending in our multiprojector tiled display system using NVIDIA Warp and Blend API. I have pre-computed alpha values for each pixel which I want to set in the pixmap to be forwarded to GPU via this API.


Regards,
Pranav

Sam

unread,
Jan 8, 2019, 7:09:27 AM1/8/19
to
That's pretty much the only way to do it, by creating an image buffer, and
then writing it out to a pixmap. That's how I do it; except that I use the
xcb library instead of Xlib, so my code won't help you much.

Reply all
Reply to author
Forward
0 new messages