Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
fbsplash stretching properly-sized image... [SOLVED]
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
vpoinot
Apprentice
Apprentice


Joined: 10 Nov 2003
Posts: 155

PostPosted: Tue Dec 19, 2006 10:58 pm    Post subject: fbsplash stretching properly-sized image... [SOLVED] Reply with quote

I followed instructions given on the wiki to set up gensplash, and it almost works: no matter what I do, the background image is horizontally stretched.

Details: my screen is 1680x1050, but listing available modes for frame buffer only gives:
Code:
# cat /proc/fb0/modes
640x400-8
640x480-8
800x600-8
1024x768-8
[snip]
1280x1024-16
1280x1024-32
[snip]
1400x1050-8
1400x1050-16

So I would like to use 1400x1050-16 mode: I created an initrd with the "gentoo" theme (which contains a configuration for 1400x1050), and added the following lines to grub.conf:
Code:
kernel (hd0,5)/boot/kernel-2.6.18-gentoo-r3 root=/dev/sda8 video=vesafb:ywrap,mtrr:3,1400x1050-16@60 splash=verbose,theme:gentoo console=tty1
initrd (hd0,5)/boot/initrd-1400x1050

Now when I boot, the image is displayed, albeit horizontally stretched. I first thought that my kernel was booting in 1680x1050 and trying to fit a 1400x1050 picture on the screen, hence stretching it, but I created an initrd for 1680x1050 and the result is the same. I guess this is because the driver is really unable to handle this resolution, and falls back to 1400x1050 with the previously observed stretch...

I also imagined that maybe the image included in the "gentoo" theme used 32 bpp instead of the 16 bpp allowed by my available modes: in this case, fbsplash would actually try to load the 1400x1050 background image, realize it is 32 bpp, reject it and fall back to the closest available mode, i.e. 1280x1024-32 (as listed above). I don't know if this makes sense, but here is what I did to check this theory:
- I created a dummy theme in /etc/splash/dummy, containing a single 1400x1050 image
Code:
# ls -lR /etc/splash/dummy
/etc/splash/dummy:
total 8
-rw-r--r-- 1 root root 1268 déc 19 22:59 1400x1050.cfg
drwxr-xr-x 2 root root 4096 déc 19 22:56 images

/etc/splash/dummy/images:
total 56
-rw-r--r-- 1 root root 35223 déc 19 22:53 silent-1400x1050.jpg
-rw-r--r-- 1 root root 18175 déc 19 22:53 verbose-1400x1050.jpg

- I ran splash_manager:
Code:
splash_manager -c demo --mode=v --tty=2 --theme=dummy

I assume that if my theory were right, fbsplash could not fall back to anything (no other image provided) and simply fail, but it does display the image, stretched as usual...

I am bit confused now. Any explanation about this mystery?

Details:
- using gentoo-sources 2.6.18
- Dell laptop / NV41 [Quadro FX Go1400]
- using vesafb-tng (since it seems it is not possible to use nvidiafb and nvidia X drivers, I haven't tried nvidiafb)

Thanks.


Last edited by vpoinot on Wed Jan 17, 2007 8:48 pm; edited 1 time in total
Back to top
View user's profile Send private message
Dan
Veteran
Veteran


Joined: 25 Oct 2005
Posts: 1302

PostPosted: Wed Dec 20, 2006 10:06 pm    Post subject: Reply with quote

Do you have the vesafb-tng size in the kernel configuration set to match that in the grub.conf ?
CONFIG_FB_VESA_DEFAULT_MODE="1400x1050@60"
Back to top
View user's profile Send private message
vpoinot
Apprentice
Apprentice


Joined: 10 Nov 2003
Posts: 155

PostPosted: Thu Dec 21, 2006 12:52 pm    Post subject: Reply with quote

Yes, but anyway, as far as I know, the command line parameters passed to the kernel have precedence over those in the kernel config. They are correctly set, though, just in case...

I should mention that fbset does return 1400x1050, which is really weird because it means the resolution is the one I want, but if I display an image with the correct size, it is stretched anyway...
Back to top
View user's profile Send private message
vpoinot
Apprentice
Apprentice


Joined: 10 Nov 2003
Posts: 155

PostPosted: Sat Dec 23, 2006 11:07 pm    Post subject: Reply with quote

Just in case somebody makes the same error as I did, here is the solution to this mystery: the vesafb-tng driver can only use 1400x1050 resolution with my card, but my screen has a physical resolution of 1680x1050.

So what happens is that the driver has to "map" a 1400x1050 picture onto a 1680x1050 screen, hence the stretching. At least, this is conclusion I came to...

Therefore, to fix my problem, I simply created a splash theme based on a 1680x1050 picture that I squeezed to 1400x1050 so that when vesafb-tng stretches it, it appears normal :-)
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum