Subversion Repositories Kolibri OS

Rev

Rev 918 | Rev 924 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 918 Rev 921
Line 53... Line 53...
53
;;
53
;;
54
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
54
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 55... Line 55...
55
 
55
 
Line 56... Line 56...
56
include 'macros.inc'
56
include 'macros.inc'
Line 57... Line 57...
57
 
57
 
Line 58... Line 58...
58
$Revision: 918 $
58
$Revision: 921 $
Line 5085... Line 5085...
5085
     xchg  eax, ebx
5085
     xchg  eax, ebx
5086
     call  dword [GETPIXEL] ; eax - x, ebx - y
5086
     call  dword [GETPIXEL] ; eax - x, ebx - y
5087
     mov   [esp + 32], ecx
5087
     mov   [esp + 32], ecx
5088
     ret
5088
     ret
Line -... Line 5089...
-
 
5089
 
-
 
5090
align 4
-
 
5091
 
-
 
5092
syscall_getarea:
-
 
5093
;eax = 36
-
 
5094
;ebx = pointer to bufer for img BBGGRRBBGGRR... 
-
 
5095
;ecx = [size x]*65536 + [size y] 
-
 
5096
;edx = [start x]*65536 + [start y] 
-
 
5097
     pushad
-
 
5098
     mov   edi,ebx
-
 
5099
     mov   eax,edx
-
 
5100
     shr   eax,16
-
 
5101
     mov   ebx,edx
-
 
5102
     and   ebx,0xffff
-
 
5103
     ; eax - x, ebx - y
-
 
5104
     mov   edx,ecx
-
 
5105
     
-
 
5106
     shr   ecx,16
-
 
5107
     and   edx,0xffff
-
 
5108
     mov   esi,ecx
-
 
5109
     ; ecx - size x, edx - size y
-
 
5110
.start_y:
-
 
5111
     push  ecx
-
 
5112
.start_x:
-
 
5113
     push  eax ebx ecx edx  esi edi
-
 
5114
     add   eax,ecx
-
 
5115
     add   ebx,edx
-
 
5116
     call  dword [GETPIXEL] ; eax - x, ebx - y
-
 
5117
     pop   edi esi
-
 
5118
     
-
 
5119
     mov   eax,ecx
-
 
5120
     pop   edx  ecx
-
 
5121
     
-
 
5122
     push  ecx  edx
-
 
5123
 
-
 
5124
     dec   edx
-
 
5125
     lea   edx,[edx*3]
-
 
5126
     imul  edx,esi
-
 
5127
     dec   ecx
-
 
5128
     lea   ecx,[ecx*3]
-
 
5129
     add   edx,ecx
-
 
5130
     add   edx,edi
-
 
5131
     mov   [edx],ax
-
 
5132
     shr   eax,16
-
 
5133
     mov   [edx+2],al
-
 
5134
 
-
 
5135
     pop   edx ecx ebx eax 
-
 
5136
     
-
 
5137
     dec   ecx
-
 
5138
     jnz   .start_x
-
 
5139
     pop   ecx
-
 
5140
     dec   edx
-
 
5141
     jnz   .start_y
-
 
5142
     popad
Line 5089... Line 5143...
5089
 
5143
     ret
Line 5090... Line 5144...
5090
 
5144