HOWTO add splash image to grub

How to do things, solutions, recipes, tutorials
Post Reply
Message
Author
106498
Posts: 250
Joined: Mon 19 Nov 2007, 02:07
Location: NZ
Contact:

HOWTO add splash image to grub

#1 Post by 106498 »

Here's a HOWTO on how to add a splashimage to your Grub boot screen.

To make changes in Grub you have to edit the menu.lst file. You find this file by going to /mnt/home/boot/grub. Before you make any changes you should backup the menu.lst file and it is also a good idea to install grub to a floppy (use the grub bootloader config and choose /mnt/floppy when asked for where to install the files. This can be used if for some crazy reason grub doesn't work.

Of course the first thing needed is a nice image to show all your friends when your computer boots up. This is not as easy as it sounds! First of all open up mtPaint, you have to resize the canvas. Click on Image|Resize Canvas. For new width enter 640 by 480, untick Fix Aspect Ratio, and click on OK. Now start painting away, but before you get too enthusiastic and artistic, beware, you must not use more than 14 colours, or the endproduct will look a bit funny. And your friends will laugh at you. So probly no fancy gradients, there there, no need to cry.

When your masterpiece is done, click on Image|Convert To Indexed. Set indexed colours to use to 14 (this will ruin any fancy gradients if you used more than 14 colours), and click on OK. Now you can do some final editing if needed.

Now click on File|Save, save it as an xpm file, and for the purpose of this howto, name it splash.xpm. It will need to be saved in /mnt/home/boot/grub.

That was fun!!!

Now open up ROX file manager (home icon) and go to /mnt/home/boot/grub. Press the ` key (under escape) and a console will pop up. Black magic! Type "gzip splash.xpm" (no quotemarks) and press <enter> Your image will now be named splash.xpm.gz. Thats your image finished!

Now open up the menu.lst file in Geany. This is done by !gasp! clicking on it. You will need to find out which partition puppy is on. Do this by looking for something like this in the file:

title Puppy Linux
rootnoverify (hd0,5)
kernel /puppy301/vmlinuz pmedia=idehd psubdir=puppy301
initrd /puppy301/initrd.gz

see that line "rootnoverify (hd0,5)", in my case puppy is on (hd0,5), It will probably be different for you. Remember it.

Now look for the first line starting with title, "title puppy linux", "title windows 98" or something similar. On the line above it type

splashimage=(hd0,5)/boot/grub/splash.xpm.gz

Of course replace (hd0,5) (in green) with whatever partition your puppy is on.
now below that add the lines

foreground ffffff
background 004992

these are to set the colours of the text your using. You can use the handy colour chooser (Tools|Colour Chooser) in geany to choose nice colours. and get the hexadecimal value.

your menu.lst file will look something like this now (without comments):
-------------------------------------------
timeout 8

default 0

fallback 2

splashimage=(hd0,5)/boot/grub/splash1.xpm.gz

foreground ffffff
background 004992

title Myfirstos
lots of other mumbojumbo follows
...
---------------------------------------------

Now be brave, and boot. (you did backup right!)
of course you can read the Grub manual too if you want :)

Disclaimer: I am not very good at disclaimers, or writing howtos. Use at your own risk. Any bodily harm or mental scarring for life that may occur is not my fault, but your own, unless you have a really good lawyer that twists the truth really well. If you feel the urge to give me money please donate it to barry instead :)

You may use my splash image if you want. Probly modify it a bit first though.
[color=green]An expert is just a beginner with experience.[/color]
Shamelessly representing [url=http://www.tdem.co.nz]TdeM[/url]!

wjaguar
Posts: 359
Joined: Wed 21 Jun 2006, 14:16

Re: HOWTO add splash image to grub

#2 Post by wjaguar »

106498 wrote:When your masterpiece is done, click on Image|Convert To Indexed. Set indexed colours to use to 14 (this will ruin any fancy gradients if you used more than 14 colours), and click on OK.
I have to say that your view of indexed conversion is rather too simplistic. While I would agree with you with regard of any tool other than mtPaint - but with mtPaint, you aren't doomed to lose your gradients, you can try to save them. You just have to know your tools a bit better for that, than just for clicking 'OK'. ;-)

The attached example is a rather fancy gradient reduced to 14 colors - and while it is a bit worse for wear, it's by no means "ruined". And here is how to get such results with mtPaint 3.20:
1) In 'Convert To Indexed' dialog, set 'Colours to use' to 14, choose 'Max-Min' quantizer and 'Stucki' dithering method.
2) Click on 'Settings' button to see dithering options.
3) There, set 'Colour Space' to 'LXN', 'Selective error propagation' to 'Separate/Split', 'Error propagation, %' to 85, and 'Full error precision' to enabled.
4) Now, click 'OK'.

mtPaint's quantization and dithering engine is the best there is - just learn how to use it, and it won't disappoint you. Reading manuals can be worth the time on occasion - and this is one such occasion. ;-)

-= With best regards, Dmitry Groshev, maintainer of mtPaint =-
Attachments
grad_rgb.png
Original gradient image (RGB)
(53.48 KiB) Downloaded 3529 times
grad_14.png
Gradient image in 14 colors
(47.75 KiB) Downloaded 3585 times

106498
Posts: 250
Joined: Mon 19 Nov 2007, 02:07
Location: NZ
Contact:

#3 Post by 106498 »

You are of course completely right but I felt my HOWTO was long enough as it is without any more detail.
[color=green]An expert is just a beginner with experience.[/color]
Shamelessly representing [url=http://www.tdem.co.nz]TdeM[/url]!

User avatar
richard.a
Posts: 513
Joined: Tue 15 Aug 2006, 08:00
Location: Adelaide, South Australia

#4 Post by richard.a »

Thank-you to both of you.

As mentioned elsewhere, I've recently put an old Twinhead laptop (266MHz Pentium-MMX processor and 64Mb of EDO RAM) into use as a puppy mobile demonstrator, and this thread is very good for the effect I'm trying to create for those who've never seen either PuppyLinux or any other OS (except perhaps Mac).

I've created a copy of the default blue wallpaper in 2.15ce which has 250-odd colours, and I did it the way suggested, but was stuck with ver 3.10 of mtPaint as there doesn't appear to be a later dot-pup or dot-pet of mtPaint.

Here is the result, and the background/foreground colours are great on it.

Image

Is there a way that the image can be instructed to stay there during the rest of the boot phase? Or maybe substituting a solid colour, to avoid the boring white text on a black background?

I'll work my way through the rest of the provided 2.15ce wallpapers to see what else can be added to that directory, when I get a "round tuit". Currently I also have saved this forum article, and the menu.lst currently booted from here, and you can download the splash.xpm.gz here

I'm working on a page slowly with links to many different images I've created from high-res images which will be in this general area when it's finished. Currently you can find it in draft form here and am happy to share them with whoever is interested.


Richard in Adelaide (Oztralia)
Last edited by richard.a on Fri 25 Jan 2008, 05:04, edited 2 times in total.
[i]Have you noticed editing is always needed for the inevitable typos that weren't there when you hit the "post" button?[/i]

[img]http://micro-hard.dreamhosters.com/416434.png[/img]

106498
Posts: 250
Joined: Mon 19 Nov 2007, 02:07
Location: NZ
Contact:

#5 Post by 106498 »

At the bottom of my post it says you can use my image, unfortunately I can't seem to upload it as xpm, so heres a png. I like the clean look of this one, and with white text and dark blue background of text,

foreground ffffff
background 004992

it looks great :)
Attachments
splash1.png
(4.87 KiB) Downloaded 3454 times
[color=green]An expert is just a beginner with experience.[/color]
Shamelessly representing [url=http://www.tdem.co.nz]TdeM[/url]!

Arthur
Posts: 15
Joined: Mon 10 Nov 2008, 05:46
Location: Earth

splash image

#6 Post by Arthur »

Re keeping the image there for the whole of the boot up process - Tiger Pup does this very well (amongst other things - the 3d desktop is great too).

User avatar
ravensrest
Posts: 365
Joined: Fri 22 Feb 2008, 16:43
Location: Grants Pass, Oregon

#7 Post by ravensrest »

Not all versions of grub support the splash image feature, and not all images can be used. Consult this url for detailed info and history:

http://ruslug.rutgers.edu/~mcgrof/grub-images/

BS

User avatar
Feel
Posts: 14
Joined: Sat 07 Feb 2009, 22:40

#8 Post by Feel »

ravensrest wrote:Not all versions of grub support the splash image feature, and not all images can be used. Consult this url for detailed info and history:

http://ruslug.rutgers.edu/~mcgrof/grub-images/

BS
Ah ah, I learnt it myself before I could read your post! But luckily Grub managed to boot Puppy anyway. The monitor looked funny somehow, I guess I've been lucky. The splash image is so cool, I will try and try again!

Post Reply