From 0768664fe08a1e8d3784f06571c8606214d05f45 Mon Sep 17 00:00:00 2001 From: "Evgeny Grechnikov (Diamond)" Date: Sat, 31 Jan 2009 03:30:53 +0000 Subject: [PATCH] libimg: fix in to_rgb2, version bump git-svn-id: svn://kolibrios.org@1015 a494cfbc-eb01-0410-851d-a64ba20cac60 --- .../libraries/libs-dev/libimg/libimg.asm | 20 ++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/programs/develop/libraries/libs-dev/libimg/libimg.asm b/programs/develop/libraries/libs-dev/libimg/libimg.asm index fe88a7041d..6e740dd20f 100644 --- a/programs/develop/libraries/libs-dev/libimg/libimg.asm +++ b/programs/develop/libraries/libs-dev/libimg/libimg.asm @@ -218,11 +218,15 @@ proc img._.do_rgb ;///////////////////////////////////////////////////////////// ; 32 BPP -> 24 BPP mov esi, [esi + Image.Data] - @@: dec ecx - js @f - movsd - dec edi - jmp @b + @@: + mov eax, [esi] + mov [edi], ax + shr eax, 16 + mov [edi+2], al + add esi, 4 + add edi, 3 + sub ecx, 1 + jnz @b @@: ret @@ -244,7 +248,9 @@ proc img._.do_rgb ;///////////////////////////////////////////////////////////// movzx eax, byte [esi] add esi, 1 mov eax, [ebx + eax*4] - mov [edi], eax + mov [edi], ax + shr eax, 16 + mov [edi+2], al add edi, 3 sub ecx, 1 jnz @b @@ -1154,7 +1160,7 @@ align 4 export \ lib_init , 'lib_init' , \ - 0x00010002 , 'version' , \ + 0x00010003 , 'version' , \ img.is_img , 'img.is_img' , \ img.info , 'img.info' , \ img.from_file , 'img.from_file' , \