'buf2d.obj' update function 'buf_bit_blt_alpha'

git-svn-id: svn://kolibrios.org@2367 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
IgorA 2012-02-21 18:38:38 +00:00
parent dc66507e60
commit 24dfe231b8

View File

@ -2246,6 +2246,16 @@ proc buf_bit_blt_alpha, buf_destination:dword, coord_x:dword, coord_y:dword, buf
jge .copy_end ;¥á«¨ ¨§®¡à ¦¥­¨¥ ¯®«­®áâìî ¢ë« §¨â §  ¯à ¢ãî áâ®à®­ã jge .copy_end ;¥á«¨ ¨§®¡à ¦¥­¨¥ ¯®«­®áâìî ¢ë« §¨â §  ¯à ¢ãî áâ®à®­ã
mov ebx,buf2d_h ;ebx - ¢ëá®â  ®á­®¢­®£® ¡ãä¥à  mov ebx,buf2d_h ;ebx - ¢ëá®â  ®á­®¢­®£® ¡ãä¥à 
mov ecx,[coord_y] mov ecx,[coord_y]
cmp ecx,0
jge @f
;¥á«¨ ª®®à¤¨­ â  coord_y<0 (1-ï ­ áâனª )
add edx,ecx ;㬥­ìè ¥¬ ¢ëá®âã ª®¯¨à㥬®© ª à⨭ª¨
neg ecx
;inc ecx
imul ecx,eax
add esi,ecx ;ᤢ¨£ ¥¬ 㪠§ â¥«ì á ª®¯¨à㥬묨 ¤ ­­ë¬¨, á ãç¥â®¬ ¯à®¯ã襭®© ç áâ¨
xor ecx,ecx ;®¡­ã«ï¥¬ ª®®à¤¨­ âã coord_y
@@:
cmp ecx,ebx cmp ecx,ebx
jge .copy_end ;¥á«¨ ª®®à¤¨­ â  'y' ¡®«ìè¥ ¢ëá®âë ¡ãä¥à  jge .copy_end ;¥á«¨ ª®®à¤¨­ â  'y' ¡®«ìè¥ ¢ëá®âë ¡ãä¥à 
add ecx,edx ;ecx - ­¨¦­ïï ª®®à¤¨­ â  ª®¯¨à㥬®© ª à⨭ª¨ add ecx,edx ;ecx - ­¨¦­ïï ª®®à¤¨­ â  ª®¯¨à㥬®© ª à⨭ª¨
@ -2255,9 +2265,16 @@ proc buf_bit_blt_alpha, buf_destination:dword, coord_x:dword, coord_y:dword, buf
sub edx,ecx ;㬥­ìè ¥¬ ¢ëá®âã ª®¯¨à㥬®© ª à⨭ª¨, ¢ á«ãç¥ ª®£¤  ®­  ¢ë« §¨â §  ­¨¦­îî £à ­¨æã sub edx,ecx ;㬥­ìè ¥¬ ¢ëá®âã ª®¯¨à㥬®© ª à⨭ª¨, ¢ á«ãç¥ ª®£¤  ®­  ¢ë« §¨â §  ­¨¦­îî £à ­¨æã
@@: @@:
mov ebx,buf2d_w mov ebx,buf2d_w
mov ecx,ebx ;ecx ¨á¯®«ì§ã¥¬ ¤«ï ¢à¥¬¥­­ëå 楫¥© mov ecx,[coord_y] ;ecx ¨á¯®«ì§ã¥¬ ¤«ï ¢à¥¬¥­­ëå 楫¥©
imul ecx,[coord_y] cmp ecx,0
jge .end_otr_c_y
;¥á«¨ ª®®à¤¨­ â  coord_y<0 (2-ï ­ áâனª )
mov ecx,[coord_x]
jmp @f
.end_otr_c_y:
imul ecx,ebx
add ecx,[coord_x] add ecx,[coord_x]
@@:
lea ecx,[ecx+ecx*2] lea ecx,[ecx+ecx*2]
add ecx,buf2d_data add ecx,buf2d_data
sub ebx,eax sub ebx,eax