Ubuntu consistency changes

John Nilsson john at milsson.nu
Thu Oct 13 03:26:46 CDT 2005


On Thu, 2005-10-13 at 16:33 +1000, Daniel Stone wrote:
> On Thu, Oct 13, 2005 at 08:09:08AM +0200, John Nilsson wrote:
> > On Thu, 2005-10-13 at 00:11 +0100, Sitsofe Wheeler wrote:
> > > When Ubuntu prompts for a password, the password window has no
> > > border. This makes it feel very strange and does not draw attention
> > > to it (focus appears to be elsewhere looking at titlebar colours).
> > 
> > I've been playing with the code for this. My plan was to have a full
> > screen blur effect behind the password window. But I've got a little
> > problem: Using gdk_pixbuf_get_from_drawable() to get the whole screen
> > from the server is a _VERY_ slow operation.
> > 
> > Does anyone have a better idea? I think that the operation can be
> > accelerated with SHM but that requires the server and client on the same
> > computer, which is kind of ugly.
> > 
> > I noticed that there was code copied that would shade the screen
> > instead, is anyone working on that?
> 
> So, there are a couple of issues here.
> 
> Firstly, SHM helps, but you'll have to read the image out of the video
> card's framebuffer, which is incredibly slow.  That's before you
> transfer it.

Ahh, that's why it's so slow.

> Secondly, assuming you want to do the compositing client-side, you need
> to do colour transformations of 1024*768, 1600*1200, or however many,
> pixels.  This hurts.  Doing this quickly in software is a non-trivially
> difficult task.

This is done within gdk_pixbuf_get_from_drawable?

> Thirdly, you need to upload the image again.

That part isn't so bad actually.

john at newkid:~/test$ ./blur
Pixbuf downloaded in 0.119416s
Pixbuf blured in 0.170319s
Pixbuf uploaded in 0.053775s

> This pretty much eliminates any kind of gradual fade: you'll need to do
> that with a very good compositing manager if you want it.  The only
> reason xscreensaver's fade works is because it does a gamma fade, which
> is both quick and very well supported.

I kind of figured that why nothing more was done with it in this case.

I guess the right thing to do is to postpone this kind of EyeCandy(TM)
until it can be done using OpenGL...

By the way is there a quick way to repaint the whole screen? I was
trying to use

	GdkRectangle rect = {0,0,width,height};
        gdk_window_invalidate_rect(root, &rect, TRUE);
        gdk_window_process_all_updates();

no luck. As you see, I'm still learning all this stuff...

This is rather off topic, maybe we should take this off the list...

Regards,
John Nilsson




More information about the ubuntu-devel mailing list