Ilya Petrov wrote: > 2009/4/1 Daniel Ribeiro <drw...@gmail.com>: >> red.length + green.length + blue.length gives you the _color_depth_. (on >> a1200, always 18) > > ok, i fixed this in libQtGui : > > --- a/qtopiacore/qt/src/gui/embedded/qscreenlinuxfb_qws.cpp > +++ b/qtopiacore/qt/src/gui/embedded/qscreenlinuxfb_qws.cpp > @@ -315,7 +315,7 @@ bool QLinuxFbScreen::connect(const QString &displaySpec) > } > > grayscale = vinfo.grayscale; > - d = vinfo.bits_per_pixel; > + d = vinfo.red.length + vinfo.green.length + vinfo.blue.length; > if (d == 24) > d = vinfo.red.length + vinfo.green.length + vinfo.blue.length;
It seems that the change below makes this change unnecessary, since the test for "d == 24" already does the length calculation correctly, no? > lstep=finfo.line_length; > > > and bpp to 24 in kernel: > > --- a/arch/arm/mach-pxa/ezx.c > +++ b/arch/arm/mach-pxa/ezx.c > @@ -106,7 +106,7 @@ static struct pxafb_mode_info mode_72r89803y01 = { > .pixclock = 192308, > .xres = 240, > .yres = 320, > - .bpp = 32, > + .bpp = 24, > .depth = 18, > .hsync_len = 10, > .left_margin = 20, > > and all looks good, becouse qtopia has 18 bit color support. -- Paulo Marques Software Development Department - Grupo PIE, S.A. Phone: +351 252 290600, Fax: +351 252 290601 Web: www.grupopie.com "As far as we know, our computer has never had an undetected error." Weisert