Stamps and Animation
NEW: The video above is now outdated - there is a much easier way to convert an animated GIF using KickMyGraphics.exe and the GIFtoIMA.cmd script - see below!
Stamps do not work if using a GFX Menu.
The graphics files can be compressed using GZip or Encode_LZMA.cmd and can have any name or file extension.
If type=0x80 is used, the bottom-left corner pixel will be used to determine the transparent colour rgb value - any pixel of this same colour value (anywhere in the stamp) will not be displayed.
Tip: If you want to make text with a transparent background, use Microsoft Paint to make a 2-colour (black&white) .bmp file. This will create a non-dithered image with just two colours. Then re-load and re-save it as a 24-colour bmp and change the colour of the letters to whatever colour you want. This will leave a plain background which is suitable for using with transparency. Make sure the corner pixel (bottom-left) contains the rgb value that you want to be transparent. Any pixels colours of this same rgb value will then not be written to the display.
Use a different 'stamp' for each menu
If you always use a stamp with the same size and position, you can use a different stamp for each submenu.
For instance, when we load the Antivirus submenu, we could display an antivirus logo stamp at the top-right of the menu but use a different stamp for the Main menu.
Make two new .mnu files as follows (0x00=opaque or 0x80=transparent):
splashimage --offset=0x00=680=10 /_ISO/MMStamp.bmp
splashimage --offset=0x00=680=10 /_ISO/AVStamp.bmp
We use a folder called $$$$CONFIG because it must be the first alphabetically-sorted folder or file to be enumerated by E2B. Note that if you had a file called \_ISO\MAINMENU\$$$$$special.ISO, then the $$$$CONFIG folder would not be the first file/folder and so the MMStamp.mnu file would not work! Instead of using a $$$$CONFIG folder, you could just use a \_ISO\MAINMENU\$$$$MMStamp.mnu file - as long as it is enumerated first by E2B.
You can define only one animation sequence using the ANIMATE variable in the MyE2B.cfg file.
The sequence will either play for 1 to 15 times during E2B start-up and before the E2B Main Menu is displayed, OR it can be continuously displayed on the background wallpaper when the menu is displayed.
An animated GIF file must be split into multiple 24-bit colour .bmp or .jpg files (frames). E2B will load them one after the other with a delay between each one.
The easiest way to create an animation is use Google to find an Animated GIF, convert it using KickMyGraphics and then make it into an .IMA file using GIFtoIMA.cmd (see 'How to make animated frames for E2B' below).
Rules for animation files
- Extracted .BMP files must be in 24/32-bit colour depth (not 256 colour)
- Extracted .JPG can be used but do not support transparent backgrounds
- The dimensions of each .bmp/.jpg (Width x Height) must be identical for all frames - otherwise you get jitter and remnants on screen
- Animated GIFs which only store differences must be converted using KickMyGraphics.
- When you play animations using a transparent setting, the bottom-left corner pixel RGB colour value is used as the transparent colour.
- Max 255 frames supported
- If the last frame is the same as the first, reduce 'last' number by one so there is no 'pause'
- You can either loop it 1-15 times or play it continuously
- The file frame name and file extension must end in nnn.eee where nn is 01-99 or 001-255 and eee is any three letters (typically .bmp or .jpg).
- Use the free app KickMyGraphics to convert a GIF into the correct format (loopback mode=off) then use GIFtoIMA to convert it to a .IMA file.
E2B cannot directly use Animated .GIF files, you must extract the frames first.
The F2 key will stop/start the animation (if the F2 key has not been already defined as a menu hotkey).
Avoid positioning an 'infinite-play' animation inside the E2B Menu area or where text may be located (e.g. avoid the menu help text area under the menu or the 'footer' help text area under the menu).
You can specify a transparent background (the bottom-left pixel is regarded as the transparent pixel RGB value).
If the 'type' includes %infinite% then it will play the sequence continuously on the wallpaper when the menu is displayed.
If you specify the number of cycles (1-15), then the background will be displayed and the animation will play the specified number of cycles during E2B start-up and before the E2B menu is displayed.
Grub4dos only supports one animated sequence on the display at any one time.
Example (multiple .bmp files)
The example below displays 9 frames - 530791_frame_0001.bmp to 530791_frame_0009.bmp - the last frame is 09 so last=9.
The file name and extension must end in nn.eee where nn is 01-99 and eee is any three letters (typically .bmp or .jpg). Bitmap files can be compressed using GZip or LZMA. If there are more than 99 frames, the file name should end in 001.bmp or 001.jpg (max=255). The filename should always be the first frame (e.g. abc01.bmp or abc001.bmp).
Note: All individual frames must be the same x,y dimensions or the image will jitter and may leave remnants on the screen during animation.
Also, they each frame must contain a complete image (you can only checking by viewing the extracted .bmp file). Some GIFS use a 'differences only' encoding format.
Tip: Extract the frames using IrfanView and then configure Explorer to display the 'Dimension' column so you can check they all have the same dimension.
KickMyGraphics will convert an animated GIF into the correct format.
A sample of some animation code for the MyE2B.cfg file is shown below:
Load animation files into memory for faster animation (.IMA file)
It is better for performance reasons, to use uncompressed .bmp files or .jpg files for the frames but you can compress the final .ima file using Encode_LZMA.cmd.
How to make animated frames for E2B using GIFtoIMA.cmd
GIFs which only store differences are not suitable unless converted converted. You can check them using the GIFtoIMA - View Slideshow option and convert them using KickMyGraphics if necessary.
- For convenience, you can copy the GIFtoIMA.cmd file to another location if you wish (e.g. Desktop or folder containing GIFs).
- GIFtoIMA.cmd will extract the .bmp files from a GIF and then make a IMA file (it uses IrfanView and ImDisk which must be pre-installed).
- GIFs which have frames of different sizes are not suitable (they cause jitter and leave remnants on screen). Use KickMyGraphics to convert them first.
- GIFtoIMA.cmd allows you to change the size of the frames (and maintain aspect ratio).
- GIFtoIMA.cmd can convert to JPGs for smaller size but the transparent background option will not work well with JPG files. Use .jpg if transparency is not required - use .bmp if transparency is required.
Tip: If one of the partitions on your USB drive has a drive letter of Z: already and Windows Disk management does not allow you to change it, you can change the drive letter using "\_ISO\docs\Make_E2B_USB_Drive\ChangeDriveLetter\ChangeLetter.cmd".
Note: if you don't specify a large enough size for the .IMA virtual floppy drive (Z:), you will get an error, press CTRL+C to abort and try again with a larger size. The size entered should be in KB and 2% is automatically added as the suggested size (E2B v1.96+).
Tip: Once the .IMA file is made, you can then compress the IMA file using LZMA_Encode, if you wish. Drag-and-drop the IMA file onto the \_ISO\docs\E2B Utilities\LZMA\LZMA_Encode.cmd file. This will compress the file for faster loading, but it will not change the .IMA file extension.
You can cut-and-paste the lines of code that are displayed after conversion by GIFtoIMA, directly into your \_ISO\MyE2B.cfg file.
GIFtoIMA also saves a .txt file with the required code lines (\_ISO\MyE2B.cfg must always start with !BAT on first line), e.g.
# 1st param - use 0x90 for looping+transparent background, use 0x10 for opaque background
# 2nd param is delay (1\18th second), 3rd is last frame number, 4th is x pos, 5th is y pos (in pixels), 6th is path to first frame
set ANIMATE=0x10=3=%last%=575=225 (fd3)/E2B/horsedrawingKMG_frame_0001.bmp
You will need to change the numbers in bold - type (0x10 or 0x90), delay (1-99) and position (x=575, y=225) parameters. For more details see blog post here.
Use the free app KickMyGraphics to load (Add Graphics), edit and then save (Make animated GIF) a GIF in the correct format (use loopback mode=off).
To trim the frames: Select all frames - Trim selected frames -
Tip: If you want to make animated text, use Microsoft Paint to make a 2-colour (black&white) .bmp file. This will create a non-dithered image with just two colours. Then re-load and re-save it as a 24-colour bmp and change the colour of the letters to whatever colour you want. This will leave a plain background which is suitable for using with transparency.
Tip: You can use Google to find animated GIFs. Use Images - Tools - Size - Icon to find suitable ones
IMPORTANT: Many animated GIFs do not extract to the same size .bmp frames. After you extract the .bmp files, check that all frames are exactly the same dimensions or else the animation will jitter, leave remnants on the screen and won't work properly.
If you are going to make a .ima floppy disk image file (recommended - see below), then do not compress the .bmp files.
Multiple animations sequences
Play animation from IMA file 3 times with different background, before going to menu
How to make a floppy disk image (.ima)
WinImage (max 2.88MB)
ImDisk (for images larger than 2.88MB)
- Use the free app KickMyGraphics to save a GIF in the correc format.
To support this site, please disable AdBlock for this domain.
Recommended for Easy2Boot (fastest!) - SanDisk Extreme SDCZ880-128G-G46
BitCoin also accepted.