Create a 32-bit root window

2017-01-08 Thread SRC SRC
Hi,

This is my first email to this mailing list and I was wondering if anyone could 
tell me how to draw a root window on the display using xlib with a 32-bit color 
depth so that I can use RGBA colors on the child windows. As far as I know, I 
could be wrong though, the child window cannot use the alpha channel if it is 
not a 32-bit color depth window, and for it to be a 32-bit depth window it's 
parent has to also be a 32-bit depth window. Basically what I'm trying  to do 
is I'm trying to set a root window with a color depth of 32-bit that has a 
scaled 24-bit image loaded as the background, and I want another window that 
will be the child of this parent, or root, window, which will have a 
translucent effect similar to the window borders in Microsoft windows 7. if you 
need more details I have posted a similar question on stack overflow with more 
details on the code that I'm using to create the root window. Hopefully I was 
clear on my question.

Thanks!
Sajeeb Roy

Stack overflow link: 
http://stackoverflow.com/questions/41524843/create-a-32-bit-root-window-in-xlib___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: Create a 32-bit root window

2017-01-08 Thread The Rasterman
On Sat, 7 Jan 2017 15:29:41 -0700 SRC SRC  said:

> Hi,
> 
> This is my first email to this mailing list and I was wondering if anyone
> could tell me how to draw a root window on the display using xlib with a
> 32-bit color depth so that I can use RGBA colors on the child windows. As far
> as I know, I could be wrong though, the child window cannot use the alpha
> channel if it is not a 32-bit color depth window, and for it to be a 32-bit
> depth window it's parent has to also be a 32-bit depth window. Basically what
> I'm trying  to do is I'm trying to set a root window with a color depth of
> 32-bit that has a scaled 24-bit image loaded as the background, and I want
> another window that will be the child of this parent, or root, window, which
> will have a translucent effect similar to the window borders in Microsoft
> windows 7. if you need more details I have posted a similar question on stack
> overflow with more details on the code that I'm using to create the root
> window. Hopefully I was clear on my question.

no. you don't have to have root window be depth 32 to have children be depth 32
too. otherwise how on earth do you think windows can have alpha channels in a
compositor? how do you think this:

http://www.enlightenment.org/ss/e-5872c6ec3ddce1.54730231.png

is possible without 2 of those windows having 32bit depth? (the 2 on the left -
clock and translucent terminal). :)

the way translucency WORKS is a compositor intervenes (these days usually your
window manager) and is composites the 32bit windows on top (also possibly deals
with redrawing root window too at the bottom - it may depend though).

so what you want really is a compositor AND 32bit windows. :) either use a
compositing window manager and then create 32bit windows, OR run a separate
compositor and your existing wm, or write your own compositor... (not going to
be much fun to get this right AND fast)...

> Thanks!
> Sajeeb Roy
> 
> Stack overflow link:
> http://stackoverflow.com/questions/41524843/create-a-32-bit-root-window-in-xlib

-- 
- Codito, ergo sum - "I code, therefore I am" --
The Rasterman (Carsten Haitzler)ras...@rasterman.com

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel