Subversion Repositories Kolibri OS

Rev

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

Rev 102 Rev 115
Line 116... Line 116...
116
        mov     [putimg.image_cx], eax
116
        mov     [putimg.image_cx], eax
117
        mov     [putimg.image_cy], edx
117
        mov     [putimg.image_cy], edx
Line 118... Line 118...
118
 
118
 
119
        ; calculate absolute (i.e. screen) coordinates
119
        ; calculate absolute (i.e. screen) coordinates
120
        mov     eax, [0x3010]
120
        mov     eax, [0x3010]
121
        mov     ebx, [eax-twdw + 0]
121
        mov     ebx, [eax-twdw + WDATA.box.left]
122
        add     ebx, [putimg.image_cx]
122
        add     ebx, [putimg.image_cx]
123
        mov     [putimg.abs_cx], ebx
123
        mov     [putimg.abs_cx], ebx
124
        mov     ebx, [eax-twdw + 4]
124
        mov     ebx, [eax-twdw + WDATA.box.top]
125
        add     ebx, [putimg.image_cy]
125
        add     ebx, [putimg.image_cy]
Line 126... Line 126...
126
        mov     [putimg.abs_cy], ebx
126
        mov     [putimg.abs_cy], ebx
127
 
127
 
128
        ; real_sx = MIN(wnd_sx-image_cx, image_sx);
128
        ; real_sx = MIN(wnd_sx-image_cx, image_sx);
129
        mov     ebx, [eax-twdw + 8] ; ebx = wnd_sx
129
        mov     ebx, [eax-twdw + WDATA.box.width] ; ebx = wnd_sx
130
        sub     ebx, [putimg.image_cx]
130
        sub     ebx, [putimg.image_cx]
131
        ja      @f
131
        ja      @f
132
        add     esp, putimg.stack_data
132
        add     esp, putimg.stack_data
Line 140... Line 140...
140
      .end_x:
140
      .end_x:
141
        inc     ebx
141
        inc     ebx
142
        mov     [putimg.real_sx], ebx
142
        mov     [putimg.real_sx], ebx
Line 143... Line 143...
143
 
143
 
144
        ; init real_sy
144
        ; init real_sy
145
        mov     ebx, [eax-twdw + 12] ; ebx = wnd_sy
145
        mov     ebx, [eax-twdw + WDATA.box.height] ; ebx = wnd_sy
146
        sub     ebx, [putimg.image_cy]
146
        sub     ebx, [putimg.image_cy]
147
        ja      @f
147
        ja      @f
148
        add     esp, putimg.stack_data
148
        add     esp, putimg.stack_data
149
        popad
149
        popad
Line 600... Line 600...
600
 
600
 
601
        mov     [drbar.bar_cx], eax
601
        mov     [drbar.bar_cx], eax
Line 602... Line 602...
602
        mov     [drbar.bar_cy], ebx
602
        mov     [drbar.bar_cy], ebx
603
 
603
 
604
        mov     edi, [0x3010]
604
        mov     edi, [0x3010]
605
        add     eax, [edi-twdw + 0] ; win_cx
605
        add     eax, [edi-twdw + WDATA.box.left] ; win_cx
606
        add     ebx, [edi-twdw + 4] ; win_cy
606
        add     ebx, [edi-twdw + WDATA.box.top] ; win_cy
Line 607... Line 607...
607
        mov     [drbar.abs_cx], eax
607
        mov     [drbar.abs_cx], eax
608
        mov     [drbar.abs_cy], ebx
608
        mov     [drbar.abs_cy], ebx
609
 
609
 
610
        ; real_sx = MIN(wnd_sx-bar_cx, bar_sx);
610
        ; real_sx = MIN(wnd_sx-bar_cx, bar_sx);
611
        mov     ebx, [edi-twdw + 8] ; ebx = wnd_sx
611
        mov     ebx, [edi-twdw + WDATA.box.width] ; ebx = wnd_sx
612
        sub     ebx, [drbar.bar_cx]
612
        sub     ebx, [drbar.bar_cx]
613
        ja      @f
613
        ja      @f
Line 624... Line 624...
624
        mov     ebx, [drbar.bar_sx]
624
        mov     ebx, [drbar.bar_sx]
625
      .end_x:
625
      .end_x:
626
        mov     [drbar.real_sx], ebx
626
        mov     [drbar.real_sx], ebx
Line 627... Line 627...
627
 
627
 
628
        ; real_sy = MIN(wnd_sy-bar_cy, bar_sy);
628
        ; real_sy = MIN(wnd_sy-bar_cy, bar_sy);
629
        mov     ebx, [edi-twdw + 12] ; ebx = wnd_sy
629
        mov     ebx, [edi-twdw + WDATA.box.height] ; ebx = wnd_sy
630
        sub     ebx, [drbar.bar_cy]
630
        sub     ebx, [drbar.bar_cy]
631
        ja      @f
631
        ja      @f
632
        add     esp, drbar.stack_data
632
        add     esp, drbar.stack_data
633
        popad
633
        popad
Line 850... Line 850...
850
     mov edx,dword [WinMapAddress-8] ; B
850
     mov edx,dword [WinMapAddress-8] ; B
851
     add edx,dword [WinMapAddress-8] ; +B
851
     add edx,dword [WinMapAddress-8] ; +B
852
     add edx,dword [WinMapAddress-8] ; +B
852
     add edx,dword [WinMapAddress-8] ; +B
853
     push edx
853
     push edx
Line 854... Line 854...
854
 
854
 
855
     mov ebp,[draw_data+32+0] ; x start:=(x+Xwin)
855
     mov ebp,[draw_data+32+RECT.left] ; x start:=(x+Xwin)
Line 856... Line 856...
856
     mov ebx,[draw_data+32+4] ; y start:=(y+Ywin)
856
     mov ebx,[draw_data+32+RECT.top] ; y start:=(y+Ywin)
857
 
857
 
858
     mov eax,[BytesPerScanLine]
858
     mov eax,[BytesPerScanLine]
859
     mul ebx
859
     mul ebx
Line 932... Line 932...
932
   hook1:
932
   hook1:
Line 933... Line 933...
933
 
933
 
934
     inc edi                       ; ptrBuffer++
934
     inc edi                       ; ptrBuffer++
935
     add esi,3                     ; ptrImage+=3
935
     add esi,3                     ; ptrImage+=3
936
     inc eax
936
     inc eax
937
     cmp eax,[draw_data+32+8]         ; X > xend?
937
     cmp eax,[draw_data+32+RECT.right]         ; X > xend?
938
;     jg nodp3
938
;     jg nodp3
939
;     jmp dp3
939
;     jmp dp3
940
;
940
;
941
;   nodp3:
941
;   nodp3:
Line 942... Line 942...
942
     jle dp3
942
     jle dp3
Line 943... Line 943...
943
 
943
 
Line 944... Line 944...
944
     mov ebp,[draw_data+32+0]
944
     mov ebp,[draw_data+32+RECT.left]
945
 
945
 
Line 959... Line 959...
959
 
959
 
Line 960... Line 960...
960
     ; ebp:=Y*BytesPerScanLine+X*BytesPerPixel+AddrLFB
960
     ; ebp:=Y*BytesPerScanLine+X*BytesPerPixel+AddrLFB
Line 961... Line 961...
961
 
961
 
962
     call calculate_edi
962
     call calculate_edi
963
 
963
 
964
     cmp ebx,[draw_data+32+12]
964
     cmp ebx,[draw_data+32+RECT.bottom]
965
;     jg  dp4
965
;     jg  dp4
966
;
966
;
Line 995... Line 995...
995
     mov edx,dword [WinMapAddress-8] ; B
995
     mov edx,dword [WinMapAddress-8] ; B
996
     add edx,dword [WinMapAddress-8] ; +B
996
     add edx,dword [WinMapAddress-8] ; +B
997
     add edx,dword [WinMapAddress-8] ; +B
997
     add edx,dword [WinMapAddress-8] ; +B
998
     push edx
998
     push edx
Line 999... Line 999...
999
 
999
 
1000
     mov ebp,[draw_data+32+0] ; x start:=(x+Xwin)
1000
     mov ebp,[draw_data+32+RECT.left] ; x start:=(x+Xwin)
Line 1001... Line 1001...
1001
     mov ebx,[draw_data+32+4] ; y start:=(y+Ywin)
1001
     mov ebx,[draw_data+32+RECT.top] ; y start:=(y+Ywin)
1002
 
1002
 
1003
     mov eax,[BytesPerScanLine]
1003
     mov eax,[BytesPerScanLine]
1004
     mul ebx
1004
     mul ebx
Line 1068... Line 1068...
1068
   shook1:
1068
   shook1:
Line 1069... Line 1069...
1069
 
1069
 
1070
     inc edi                       ; ptrBuffer++
1070
     inc edi                       ; ptrBuffer++
1071
     add esi,3                     ; ptrImage+=3
1071
     add esi,3                     ; ptrImage+=3
1072
     inc eax
1072
     inc eax
1073
     cmp eax,[draw_data+32+8]         ; X > xend?
1073
     cmp eax,[draw_data+32+RECT.right]         ; X > xend?
Line 1074... Line 1074...
1074
     jle sdp3
1074
     jle sdp3
Line 1075... Line 1075...
1075
 
1075
 
Line 1076... Line 1076...
1076
     mov ebp,[draw_data+32+0]
1076
     mov ebp,[draw_data+32+RECT.left]
1077
 
1077
 
Line 1091... Line 1091...
1091
 
1091
 
Line 1092... Line 1092...
1092
     ; ebp:=Y*BytesPerScanLine+X*BytesPerPixel+AddrLFB
1092
     ; ebp:=Y*BytesPerScanLine+X*BytesPerPixel+AddrLFB
Line 1093... Line 1093...
1093
 
1093
 
1094
     call calculate_edi
1094
     call calculate_edi
Line 1095... Line 1095...
1095
 
1095
 
Line 1096... Line 1096...
1096
     cmp ebx,[draw_data+32+12]
1096
     cmp ebx,[draw_data+32+RECT.bottom]