From 306c0ed771a484a69efea704834b498cab03d1e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20Hord=C3=A9?= Date: Tue, 30 Nov 2004 19:27:59 +0000 Subject: [PATCH] feat: utilisation de la librairie bmp.lib plutot que l'int 47h --- programs/logo.asm | 90 +++++++++++++++++++++++++++-------------------- 1 file changed, 52 insertions(+), 38 deletions(-) diff --git a/programs/logo.asm b/programs/logo.asm index 85411e0..cae2394 100644 --- a/programs/logo.asm +++ b/programs/logo.asm @@ -1,10 +1,16 @@ .model tiny -.386c +.486 +smart .code + org 0h - - + +include ..\include\mem.h + start: +header exe <,1,0,,,offset imports,,> + +realstart: mov ah,7 mov cx,65535 int 49h @@ -34,7 +40,6 @@ jc problem2 push es pop ds -xor si,si mov ah,28h int 47h @@ -42,59 +47,68 @@ mov ax,0008h int 47h mov ah,2 int 47h -mov cx,300 -mov bx,30 -mov ah,37 -int 47h -mov ah,15h -mov cl,11 -int 47h +push 0 +call cs:[loadbmppalet] +push 150 +push 20 +push 0 +call cs:[showbmp] +jc problem4 push cs pop ds -mov ah,13 -mov si,offset poper -int 47h -mov ax,0 +push offset poper +call [print] +endofit: +xor ax,ax int 16h mov ah,29h int 47h -db 0CBH +retf problem: push cs pop ds -mov ah,13 -mov si,offset error -int 47h -mov ax,0 -int 16h -db 0CBh +push offset error +call [print] +jmp endofit problem2: push cs pop ds -mov ah,13 -mov si,offset error2 -int 47h -mov ax,0 -int 16h -db 0CBh +push offset error2 +call [print] +jmp endofit problem3: push cs pop ds -mov ah,13 -mov si,offset error3 -int 47h -mov ax,0 -int 16h -db 0CBh +push offset error3 +call [print] +jmp endofit -poper db 'COS2000 en mode graphique',0 +problem4: +push cs +pop ds +push offset error4 +call [print] +jmp endofit + +poper db '\c0BC\c0CO\c0DS\c0E2\c0E0\c0E0\c0F0 en mode graphique',0 logo db 'cos.rip',0 ok1 db 'Chargement de l''image OK',0 ok2 db 'Decompression de l''image OK',0 -error3 db 'Une erreur est apparue lors de l''allocation de mémoire',0 -error db 'Une erreur est apparue lors du chargement de l''image',0 -error2 db 'Une erreur est apparue lors de la decompression de l''image',0 +error3 db '\c04Une erreur est apparue lors de l''allocation de mémoire',0 +error db '\c04Une erreur est apparue lors du chargement de l''image',0 +error2 db '\c04Une erreur est apparue lors de la decompression de l''image',0 +error4 db '\c0FUne erreur est apparue lors de l''affichage de l''image',0 + + +imports: + db "VIDEO.LIB::print",0 +print dd 0 + db "BMP.LIB::showbmp",0 +showbmp dd 0 + db "BMP.LIB::loadbmppalet",0 +loadbmppalet dd 0 + dw 0 end start