Welcome to BIOS Graphics page / Advanced BIOS Logo Reader
More then two dozens of different logo formats ... by ABR-G2
/* * * * AwardBitmapReader - ABR * Copyright (C) 1999, 2000, 2003, 2004, 2005 Anton Borisov * * */ #include <stdio.h> #include <stdlib.h> typedef unsigned char byte; typedef unsigned char uchar; typedef unsigned short word; typedef unsigned long dword; #if defined(LINUX) || defined(__LINUX__) || defined(__linux__) #define ATTRPACK __attribute__((packed)) #else // This WIN32 environment #define ATTRPACK #pragma pack(1) #endif #define StdEPA 1 /* 126x84 */ #define NStdEPA 2 /* Any other */ #define AWBM16bm 3 /* 16 Color AWBM */ #define QDIbm 4 /* 256 Color BMP in QDI */ #define BIObm 5 /* 256 Color PCX in BioStar */ #define PGbm 6 /* PhoenixGraphics */ #define SSbm 7 /* SystemSoft Bitmap */ #define INTELbm 8 /* GRFX */ #define AWBM256bm 9 /* 256 Color AWBM */ #define AMIGLE 10 /* GLE, GLB, GLA */ #define UsrLogo 11 /* TEXT Logo */ /*------------------------------------------------------ 4 Aug, 2003 Phoenix FirstBIOS ICON format ------------------------------------------------------*/ #define ICONbm 12 /*------------------------------------------------------ 9 Aug, 2003 Phoenix FirstBIOS SCRN format ------------------------------------------------------*/ #define SCRNbm 13 /*------------------------------------------------------ 15 Apr, 2004 ASUS 4OSB format ------------------------------------------------------*/ #define ASUSbm 14 /*------------------------------------------------------ 29 Apr, 2004 ASUS LOGO format ------------------------------------------------------*/ #define ASUSLOGObm 15 /*------------------------------------------------------ 11 May, 2004 AMI GFX (PCX) format Revised from AMIGFX project ------------------------------------------------------*/ #define AMIGFXbm 16 /*------------------------------------------------------ 17 May, 2004 ASUS OSB640 format ------------------------------------------------------*/ #define ASUSOSB640bm 17 /*------------------------------------------------------ 17 May, 2004 ASUS LOGO v2 (AMI) format ------------------------------------------------------*/ #define ASUS2v2bm 18 /*------------------------------------------------------ 18 May, 2004 ASUS LOGO v3 (HeaderLess) format ------------------------------------------------------*/ #define ASUSv3bm 19 /*------------------------------------------------------ 03 Aug, 2004 SystemSoft GFX (8-bit PCX) ------------------------------------------------------*/ #define SYSOGFXbm 20 /*------------------------------------------------------ 03 Aug, 2004 TM (AMI) ------------------------------------------------------*/ #define TMbm 21 /*------------------------------------------------------ 10 Aug, 2004 AWBM16 variation ------------------------------------------------------*/ #define AWBM16V2bm 22 /*------------------------------------------------------ 22 Nov, 2004 $OSB ------------------------------------------------------*/ #define OSB2bm 23 /*------------------------------------------------------ 23 Nov, 2004 JPEG (plain JFIF) ------------------------------------------------------*/ #define JFIFbm 24 /*------------------------------------------------------ 23 Nov, 2004 PCX 4-Bit, RLE Encoded ------------------------------------------------------*/ #define PCX4RLEbm 25 /*------------------------------------------------------ 23 Nov, 2004 Phoenix Composite Envelope (SCN) ------------------------------------------------------*/ #define SCN1bm 26 /*------------------------------------------------------ 23 Nov, 2004 PCX 8-bit, RLE Encode ------------------------------------------------------*/ #define PCX8RLEbm 27 /*------------------------------------------------------ 25 Nov, 2004 AWBM256 variation ------------------------------------------------------*/ #define AWBM256V2bm 28 /*------------------------------------------------------ 27 Nov, 2004 Phoenix Composite Envelope (SCN) ------------------------------------------------------*/ #define SCN2bm 29 /*------------------------------------------------------ 03 Dec, 2004 Intel Graphics (GRFXLOGO) ------------------------------------------------------*/ #define GRFXLOGObm 30 /*------------------------------------------------------ 03 Dec, 2004 Intel Graphics (M5) ------------------------------------------------------*/ #define UsrLogo2 31 /*------------------------------------------------------ 19 Dec, 2004 BMP 8-Bit, Indexed ------------------------------------------------------*/ #define BMP8ibm 32 /*------------------------------------------------------ 11 Jan, 2005 ASUS 4OSB format (V2) ------------------------------------------------------*/ #define ASUSV2bm 33 /*------------------------------------------------------ 11 Jan, 2005 Intel Graphics (Compressed GRFX) ------------------------------------------------------*/ #define UsrLogo3 34 /*------------------------------------------------------ 20 Mar, 2005 Dell NVRAM Logo (Inspiron 8100) ------------------------------------------------------*/ #define DELLbm 35 /*------------------------------------------------------ 4 Apr, 2005 $OSB V2 ------------------------------------------------------*/ #define OSB2BMPbm 36 // this is microseconds #define SLIDESHOWTIMEOUT 1 #define epaW 8 #define epaH 14 #define TRUE 1 #define FALSE 0 typedef struct EPAInfo { byte Type; /* 'AWBM16', 'AWBM256' ... */ char* Name; /* 'AWBM16', 'AWBM256' ... */ word Width; /* Image width */ word Height; /* Image height */ dword Len; /* File full length */ byte isComposite; /* Composite image? Yes = 1 */ word ColorPal; /* Colors in Palette */ byte* OEM; /* Reserved for future usage. Name of original OEM, VAR */ byte* RawGfx; /* Pointer to RAW decompressed image buffer */ byte* RGBPal; /* Pointer to RGB data */ FILE* ptx; /* Pointer to FILE struct */ char* RGB; } EPAInfo; typedef struct RGB { byte r; byte g; byte b; }; typedef struct AWBM { byte Sig[4]; word Width; word Height; } AWBM_HDR; typedef struct PGBM { byte Sig[2]; byte rsrv0; byte isPalette; word Len; word rsrv2; word rsrv3; word Width; word Height; word XOffset; word YOffset; } PGBM_HDR; typedef struct GLE { byte Sig[3]; byte rsrv1; byte Width; byte Height; byte Color; byte rsrv2; } GLE_HDR; typedef struct ASUS2 { word ShortJumper; /* asm instruction, jmp short */ byte Sig[6]; /* A,S,U,S,2,\x0 */ dword LongJumper; /* asm instruction, jmp long */ dword LogoStart; /* offset to first image */ byte Version_Lo; /* Version_Lo ? */ byte Version_Hi; /* Version_Hi ? */ } ASUS2_HDR; typedef struct ASUSLOGO { byte Sig[4]; /* L,O,G,O */ dword rsrv1; /* */ } ASUSLOGO_HDR;