Subversion Repositories Kolibri OS

Rev

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

Rev 2465 Rev 2987
Line 15... Line 15...
15
;;                                                              ;;
15
;;                                                              ;;
16
;;  See file COPYING for details                                ;;
16
;;  See file COPYING for details                                ;;
17
;;                                                              ;;
17
;;                                                              ;;
18
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
18
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 19... Line 19...
19
 
19
 
Line 20... Line 20...
20
$Revision: 2465 $
20
$Revision: 2987 $
21
 
21
 
Line 70... Line 70...
70
;--------------------------------------
70
;--------------------------------------
71
align 4
71
align 4
72
.no_mouseunder:
72
.no_mouseunder:
73
;--------------------------------------
73
;--------------------------------------
74
;        imul    ebx, [BytesPerScanLine] ; ebx = y * y multiplier
74
;        imul    ebx, [BytesPerScanLine] ; ebx = y * y multiplier
75
        mov     ebx, [d_width_calc_area + ebx*4]
75
        mov     ebx, [BPSLine_calc_area+ebx*4]
76
        lea     ebx, [ebx + ebx*2]
-
 
77
        lea     edi, [eax+eax*2]; edi = x*3
76
        lea     edi, [eax+eax*2]; edi = x*3
78
        add     edi, ebx      ; edi = x*3+(y*y multiplier)
77
        add     edi, ebx      ; edi = x*3+(y*y multiplier)
79
        mov     ecx, [LFB_BASE+edi]
78
        mov     ecx, [LFB_BASE+edi]
80
;--------------------------------------
79
;--------------------------------------
81
align 4
80
align 4
Line 103... Line 102...
103
;--------------------------------------
102
;--------------------------------------
104
align 4
103
align 4
105
.no_mouseunder:
104
.no_mouseunder:
106
;--------------------------------------
105
;--------------------------------------
107
;        imul    ebx, [BytesPerScanLine] ; ebx = y * y multiplier
106
;        imul    ebx, [BytesPerScanLine] ; ebx = y * y multiplier
108
        mov     ebx, [d_width_calc_area + ebx*4]
107
        mov     ebx, [BPSLine_calc_area+ebx*4]
109
        shl     ebx, 2
-
 
110
        lea     edi, [ebx+eax*4]; edi = x*4+(y*y multiplier)
108
        lea     edi, [ebx+eax*4]; edi = x*4+(y*y multiplier)
111
        mov     ecx, [LFB_BASE+edi]
109
        mov     ecx, [LFB_BASE+edi]
112
;--------------------------------------
110
;--------------------------------------
113
align 4
111
align 4
114
@@:
112
@@:
Line 241... Line 239...
241
; pointer to image
239
; pointer to image
242
        mov     esi, [putimg.pti]
240
        mov     esi, [putimg.pti]
243
; pointer to screen
241
; pointer to screen
244
        mov     edx, [putimg.abs_cy]
242
        mov     edx, [putimg.abs_cy]
245
;        imul    edx, [BytesPerScanLine]
243
;        imul    edx, [BytesPerScanLine]
246
 
-
 
247
        mov     edx, [d_width_calc_area + edx*4]
244
        mov     edx, [BPSLine_calc_area+edx*4]
248
        cmp     bl, 4
-
 
249
        je      .32
-
 
250
        lea     edx, [edx+edx*2]
-
 
251
        jmp     @f
-
 
252
;-------------------------------------
-
 
253
align 4
-
 
254
.32:
-
 
255
        shl     edx, 2
-
 
256
;-------------------------------------
-
 
257
align 4
-
 
258
@@:
-
 
259
        mov     eax, [putimg.abs_cx]
245
        mov     eax, [putimg.abs_cx]
260
;        movzx   ebx, byte [ScreenBPP]
246
;        movzx   ebx, byte [ScreenBPP]
261
;        shr     ebx, 3
247
;        shr     ebx, 3
262
        imul    eax, ebx
248
        imul    eax, ebx
263
        add     edx, eax
249
        add     edx, eax
Line 418... Line 404...
418
        call    eax
404
        call    eax
419
        cmp     [ebp], bl
405
        cmp     [ebp], bl
420
        jne     .skip
406
        jne     .skip
421
;--------------------------------------
407
;--------------------------------------
422
        push    ecx
408
        push    ecx
423
        mov     ecx, [putimg.real_sy_and_abs_cy + 4]
-
 
424
        sub     ecx, edi
-
 
425
;--------------------------------------
409
;--------------------------------------
426
; check for Y
410
align 4
427
        cmp     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
428
        jb      .no_mouse_area
-
 
429
 
411
.sh:
430
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
-
 
431
        jae     .no_mouse_area
-
 
432
 
-
 
433
        rol     ecx, 16
412
        neg     ecx
434
        add     ecx, [putimg.real_sx_and_abs_cx + 4]
413
        add     ecx, [putimg.real_sx_and_abs_cx + 4]
435
        sub     ecx, [esp]
-
 
436
;--------------------------------------
414
;--------------------------------------
437
; check for X
415
; check for X
-
 
416
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
-
 
417
        jae     .no_mouse_area
-
 
418
 
438
        cmp     cx, [X_UNDER_subtraction_CUR_hot_x]
419
        sub     cx, [X_UNDER_subtraction_CUR_hot_x]
439
        jb      .no_mouse_area
420
        jb      .no_mouse_area
Line -... Line 421...
-
 
421
 
-
 
422
        shl     ecx, 16
-
 
423
 
-
 
424
        add     ecx, [putimg.real_sy_and_abs_cy + 4]
-
 
425
        sub     ecx, edi
-
 
426
;--------------------------------------
440
 
427
; check for Y
441
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
428
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
-
 
429
        jae     .no_mouse_area
-
 
430
 
-
 
431
        sub     cx, [Y_UNDER_subtraction_CUR_hot_y]
442
        jae     .no_mouse_area
432
        jb      .no_mouse_area
443
;--------------------------------------
433
;--------------------------------------
444
; check mouse area for putpixel
434
; check mouse area for putpixel
-
 
435
        call    check_mouse_area_for_putpixel_new.1
-
 
436
        cmp     ecx, -1   ;SHIT HAPPENS?
-
 
437
        jne     .no_mouse_area
-
 
438
 
-
 
439
        mov     ecx, [esp]
445
        call    check_mouse_area_for_putpixel_new.1
440
        jmp     .sh
446
;--------------------------------------
441
;--------------------------------------
447
align 4
442
align 4
448
.no_mouse_area:
443
.no_mouse_area:
449
        pop     ecx
444
        pop     ecx
Line 620... Line 615...
620
        call    eax
615
        call    eax
621
        cmp     [ebp], bl
616
        cmp     [ebp], bl
622
        jne     .skip
617
        jne     .skip
623
;--------------------------------------
618
;--------------------------------------
624
        push    ecx
619
        push    ecx
625
        mov     ecx, [putimg.real_sy_and_abs_cy + 4]
-
 
626
        sub     ecx, edi
-
 
627
;--------------------------------------
620
;--------------------------------------
628
; check for Y
621
align 4
629
        cmp     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
630
        jb      .no_mouse_area
-
 
631
 
622
.sh:
632
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
-
 
633
        jae     .no_mouse_area
-
 
634
 
-
 
635
        rol     ecx, 16
623
        neg     ecx
636
        add     ecx, [putimg.real_sx_and_abs_cx + 4]
624
        add     ecx, [putimg.real_sx_and_abs_cx + 4]
637
        sub     ecx, [esp]
-
 
638
;--------------------------------------
625
;--------------------------------------
639
; check for X
626
; check for X
-
 
627
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
-
 
628
        jae     .no_mouse_area
-
 
629
 
640
        cmp     cx, [X_UNDER_subtraction_CUR_hot_x]
630
        sub     cx, [X_UNDER_subtraction_CUR_hot_x]
641
        jb      .no_mouse_area
631
        jb      .no_mouse_area
Line -... Line 632...
-
 
632
 
-
 
633
        shl     ecx, 16
-
 
634
 
-
 
635
        add     ecx, [putimg.real_sy_and_abs_cy + 4]
-
 
636
        sub     ecx, edi
-
 
637
;--------------------------------------
642
 
638
; check for Y
643
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
639
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
-
 
640
        jae     .no_mouse_area
-
 
641
 
-
 
642
        sub     cx, [Y_UNDER_subtraction_CUR_hot_y]
644
        jae     .no_mouse_area
643
        jb      .no_mouse_area
645
;--------------------------------------
644
;--------------------------------------
646
; check mouse area for putpixel
645
; check mouse area for putpixel
-
 
646
        call    check_mouse_area_for_putpixel_new.1
-
 
647
        cmp     ecx, -1   ;SHIT HAPPENS?
-
 
648
        jne     .no_mouse_area
-
 
649
 
-
 
650
        mov     ecx, [esp]
647
        call    check_mouse_area_for_putpixel_new.1
651
        jmp     .sh
648
;--------------------------------------
652
;--------------------------------------
649
align 4
653
align 4
650
.no_mouse_area:
654
.no_mouse_area:
651
        pop     ecx
655
        pop     ecx
Line 738... Line 742...
738
        mov     ecx, eax
742
        mov     ecx, eax
739
        shl     ecx, 16
743
        shl     ecx, 16
740
        mov     cx, bx
744
        mov     cx, bx
Line 741... Line 745...
741
 
745
 
742
;        imul    ebx, [BytesPerScanLine]  ; ebx = y * y multiplier
746
;        imul    ebx, [BytesPerScanLine]  ; ebx = y * y multiplier
743
        mov     ebx, [d_width_calc_area + ebx*4]
-
 
744
        lea     ebx, [ebx + ebx*2]
-
 
745
 
747
        mov     ebx, [BPSLine_calc_area+ebx*4]
746
        lea     edi, [eax+eax*2]; edi = x*3
748
        lea     edi, [eax+eax*2]; edi = x*3
747
        mov     eax, [esp+32-8+4]
749
        mov     eax, [esp+32-8+4]
748
;--------------------------------------
750
;--------------------------------------
749
; check for hardware cursor
751
; check for hardware cursor
Line 769... Line 771...
769
        mov     ecx, eax
771
        mov     ecx, eax
770
        shl     ecx, 16
772
        shl     ecx, 16
771
        mov     cx, bx
773
        mov     cx, bx
Line 772... Line 774...
772
 
774
 
773
;        imul    ebx, [BytesPerScanLine]  ; ebx = y * y multiplier
775
;        imul    ebx, [BytesPerScanLine]  ; ebx = y * y multiplier
774
        mov     ebx, [d_width_calc_area + ebx*4]
-
 
775
        lea     ebx, [ebx + ebx*2]
-
 
776
 
776
        mov     ebx, [BPSLine_calc_area+ebx*4]
777
        lea     edi, [eax+eax*2]; edi = x*3
777
        lea     edi, [eax+eax*2]; edi = x*3
778
        mov     eax, [esp+32-8+4]
778
        mov     eax, [esp+32-8+4]
779
;--------------------------------------
779
;--------------------------------------
780
; check for hardware cursor
780
; check for hardware cursor
Line 783... Line 783...
783
; check mouse area for putpixel
783
; check mouse area for putpixel
784
        test    eax, 0x04000000
784
        test    eax, 0x04000000
785
        jnz     @f
785
        jnz     @f
786
;--------------------------------------
786
;--------------------------------------
787
; check for Y
787
; check for Y
788
        cmp     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
789
        jb      @f
-
 
790
 
-
 
791
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
788
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
792
        jae     @f
789
        jae     @f
Line -... Line 790...
-
 
790
 
-
 
791
        sub     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
792
        jb      @f
793
 
793
 
794
        rol     ecx, 16
794
        rol     ecx, 16
795
;--------------------------------------
795
;--------------------------------------
796
; check for X
-
 
797
        cmp     cx, [X_UNDER_subtraction_CUR_hot_x]
-
 
798
        jb      @f
-
 
799
 
796
; check for X
800
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
797
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
Line -... Line 798...
-
 
798
        jae     @f
-
 
799
 
-
 
800
        sub     cx, [X_UNDER_subtraction_CUR_hot_x]
-
 
801
        jb      @f
-
 
802
 
801
        jae     @f
803
        ror     ecx, 16
802
 
804
 
803
        call    check_mouse_area_for_putpixel_new.1
805
        call    check_mouse_area_for_putpixel_new.1
804
;--------------------------------------
806
;--------------------------------------
805
align 4
807
align 4
Line 817... Line 819...
817
        mov     ecx, eax
819
        mov     ecx, eax
818
        shl     ecx, 16
820
        shl     ecx, 16
819
        mov     cx, bx
821
        mov     cx, bx
Line 820... Line 822...
820
 
822
 
821
;        imul    ebx, [BytesPerScanLine]  ; ebx = y * y multiplier
823
;        imul    ebx, [BytesPerScanLine]  ; ebx = y * y multiplier
822
        mov     ebx, [d_width_calc_area + ebx*4]
-
 
823
        shl     ebx, 2
-
 
824
 
824
        mov     ebx, [BPSLine_calc_area+ebx*4]
825
        lea     edi, [ebx+eax*4]; edi = x*4+(y*y multiplier)
825
        lea     edi, [ebx+eax*4]; edi = x*4+(y*y multiplier)
826
        mov     eax, [esp+32-8+4]; eax = color
826
        mov     eax, [esp+32-8+4]; eax = color
827
;--------------------------------------
827
;--------------------------------------
828
; check for hardware cursor
828
; check for hardware cursor
Line 847... Line 847...
847
        mov     ecx, eax
847
        mov     ecx, eax
848
        shl     ecx, 16
848
        shl     ecx, 16
849
        mov     cx, bx
849
        mov     cx, bx
Line 850... Line 850...
850
 
850
 
851
;        imul    ebx, [BytesPerScanLine]  ; ebx = y * y multiplier
851
;        imul    ebx, [BytesPerScanLine]  ; ebx = y * y multiplier
852
        mov     ebx, [d_width_calc_area + ebx*4]
-
 
853
        shl     ebx, 2
-
 
854
 
852
        mov     ebx, [BPSLine_calc_area+ebx*4]
855
        lea     edi, [ebx+eax*4]; edi = x*4+(y*y multiplier)
853
        lea     edi, [ebx+eax*4]; edi = x*4+(y*y multiplier)
856
        mov     eax, [esp+32-8+4]; eax = color
854
        mov     eax, [esp+32-8+4]; eax = color
857
;--------------------------------------
855
;--------------------------------------
858
; check for hardware cursor
856
; check for hardware cursor
Line 861... Line 859...
861
; check mouse area for putpixel
859
; check mouse area for putpixel
862
        test    eax, 0x04000000
860
        test    eax, 0x04000000
863
        jnz     @f
861
        jnz     @f
864
;--------------------------------------
862
;--------------------------------------
865
; check for Y
863
; check for Y
866
        cmp     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
867
        jb      @f
-
 
868
 
-
 
869
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
864
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
870
        jae     @f
865
        jae     @f
Line -... Line 866...
-
 
866
 
-
 
867
        sub     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
868
        jb      @f
871
 
869
 
872
        rol     ecx, 16
870
        rol     ecx, 16
873
;--------------------------------------
871
;--------------------------------------
874
; check for X
-
 
875
        cmp     cx, [X_UNDER_subtraction_CUR_hot_x]
-
 
876
        jb      @f
-
 
877
 
872
; check for X
878
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
873
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
Line -... Line 874...
-
 
874
        jae     @f
-
 
875
 
-
 
876
        sub     cx, [X_UNDER_subtraction_CUR_hot_x]
-
 
877
        jb      @f
-
 
878
 
879
        jae     @f
879
        ror     ecx, 16
880
 
880
 
881
        call    check_mouse_area_for_putpixel_new.1
881
        call    check_mouse_area_for_putpixel_new.1
882
;--------------------------------------
882
;--------------------------------------
883
align 4
883
align 4
Line 1236... Line 1236...
1236
        add     eax, [BytesPerScanLine]
1236
        add     eax, [BytesPerScanLine]
1237
        mov     [drbar.line_inc_scr], eax
1237
        mov     [drbar.line_inc_scr], eax
1238
; pointer to screen
1238
; pointer to screen
1239
        mov     edx, [drbar.abs_cy]
1239
        mov     edx, [drbar.abs_cy]
1240
;        imul    edx, [BytesPerScanLine]
1240
;        imul    edx, [BytesPerScanLine]
1241
 
-
 
1242
        mov     edx, [d_width_calc_area + edx*4]
1241
        mov     edx, [BPSLine_calc_area+edx*4]
1243
        cmp     bl, 4
-
 
1244
        je      .32
-
 
1245
        lea     edx, [edx+edx*2]
-
 
1246
        jmp     @f
-
 
1247
;-------------------------------------
-
 
1248
align 4
-
 
1249
.32:
-
 
1250
        shl     edx, 2
-
 
1251
;-------------------------------------
-
 
1252
align 4
-
 
1253
@@:
-
 
1254
        mov     eax, [drbar.abs_cx]
1242
        mov     eax, [drbar.abs_cx]
1255
        imul    eax, ebx
1243
        imul    eax, ebx
1256
        add     edx, eax
1244
        add     edx, eax
1257
; pointer to pixel map
1245
; pointer to pixel map
1258
        mov     eax, [drbar.abs_cy]
1246
        mov     eax, [drbar.abs_cy]
Line 1404... Line 1392...
1404
;--------------------------------------
1392
;--------------------------------------
1405
        mov     ecx, [drbar.real_sy_and_abs_cy]
1393
        mov     ecx, [drbar.real_sy_and_abs_cy]
1406
        sub     ecx, esi
1394
        sub     ecx, esi
1407
;--------------------------------------
1395
;--------------------------------------
1408
; check for Y
1396
; check for Y
1409
        cmp     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
1410
        jb      .no_mouse_area
-
 
1411
 
-
 
1412
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
1397
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
1413
        jae     .no_mouse_area
1398
        jae     .no_mouse_area
Line -... Line 1399...
-
 
1399
 
-
 
1400
        sub     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
1401
        jb      .no_mouse_area
1414
 
1402
 
1415
        rol     ecx, 16
1403
        rol     ecx, 16
1416
        add     ecx, [drbar.real_sx_and_abs_cx]
1404
        add     ecx, [drbar.real_sx_and_abs_cx]
1417
        sub     ecx, edi
1405
        sub     ecx, edi
1418
;--------------------------------------
1406
;--------------------------------------
1419
; check for X
-
 
1420
        cmp     cx, [X_UNDER_subtraction_CUR_hot_x]
-
 
1421
        jb      .no_mouse_area
-
 
1422
 
1407
; check for X
1423
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
1408
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
-
 
1409
        jae     .no_mouse_area
-
 
1410
 
-
 
1411
        sub     cx, [X_UNDER_subtraction_CUR_hot_x]
-
 
1412
        jb      .no_mouse_area
-
 
1413
 
1424
        jae     .no_mouse_area
1414
        ror     ecx, 16
1425
;--------------------------------------
1415
;--------------------------------------
-
 
1416
; check mouse area for putpixel
1426
; check mouse area for putpixel
1417
        push    eax
1427
        call    check_mouse_area_for_putpixel_new.1
1418
        call    check_mouse_area_for_putpixel_new.1
1428
        mov     [edx], ax
1419
        mov     [edx], ax
1429
        shr     eax, 16
1420
        shr     eax, 16
1430
        mov     [edx + 2], al
1421
        mov     [edx + 2], al
1431
        mov     eax, [drbar.color]
1422
        pop     eax
1432
        jmp     .skip
1423
        jmp     .skip
1433
; store to real LFB
1424
; store to real LFB
1434
;--------------------------------------
1425
;--------------------------------------
1435
align 4
1426
align 4
Line 1588... Line 1579...
1588
;--------------------------------------
1579
;--------------------------------------
1589
        mov     ecx, [drbar.real_sy_and_abs_cy]
1580
        mov     ecx, [drbar.real_sy_and_abs_cy]
1590
        sub     ecx, esi
1581
        sub     ecx, esi
1591
;--------------------------------------
1582
;--------------------------------------
1592
; check for Y
1583
; check for Y
1593
        cmp     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
1594
        jb      .no_mouse_area
-
 
1595
 
-
 
1596
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
1584
        cmp     cx, [Y_UNDER_sub_CUR_hot_y_add_curh]
1597
        jae     .no_mouse_area
1585
        jae     .no_mouse_area
Line -... Line 1586...
-
 
1586
 
-
 
1587
        sub     cx, [Y_UNDER_subtraction_CUR_hot_y]
-
 
1588
        jb      .no_mouse_area
1598
 
1589
 
1599
        rol     ecx, 16
1590
        rol     ecx, 16
1600
        add     ecx, [drbar.real_sx_and_abs_cx]
1591
        add     ecx, [drbar.real_sx_and_abs_cx]
1601
        sub     ecx, edi
1592
        sub     ecx, edi
1602
;--------------------------------------
1593
;--------------------------------------
1603
; check for X
-
 
1604
        cmp     cx, [X_UNDER_subtraction_CUR_hot_x]
-
 
1605
        jb      .no_mouse_area
-
 
1606
 
1594
; check for X
1607
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
1595
        cmp     cx, [X_UNDER_sub_CUR_hot_x_add_curh]
-
 
1596
        jae     .no_mouse_area
-
 
1597
 
-
 
1598
        sub     cx, [X_UNDER_subtraction_CUR_hot_x]
-
 
1599
        jb      .no_mouse_area
-
 
1600
 
1608
        jae     .no_mouse_area
1601
        ror     ecx, 16
1609
;--------------------------------------
1602
;--------------------------------------
-
 
1603
; check mouse area for putpixel
1610
; check mouse area for putpixel
1604
        push    eax
1611
        call    check_mouse_area_for_putpixel_new.1
1605
        call    check_mouse_area_for_putpixel_new.1
1612
        mov     [edx], eax
1606
        mov     [edx], eax
1613
        mov     eax, [drbar.color]
1607
        pop     eax
1614
        jmp     .skip
1608
        jmp     .skip
1615
; store to real LFB
1609
; store to real LFB
1616
;--------------------------------------
1610
;--------------------------------------
1617
align 4
1611
align 4
Line 1652... Line 1646...
1652
        mov     ebp, [draw_data+32+RECT.left]   ; x start
1646
        mov     ebp, [draw_data+32+RECT.left]   ; x start
1653
; 1) Calculate pointers in WinMapAddress (does pixel belong to OS thread?) [ebp]
1647
; 1) Calculate pointers in WinMapAddress (does pixel belong to OS thread?) [ebp]
1654
;                       and LFB data (output for our function) [edi]
1648
;                       and LFB data (output for our function) [edi]
1655
;        mov     eax, [BytesPerScanLine]
1649
;        mov     eax, [BytesPerScanLine]
1656
;        mul     ebx
1650
;        mul     ebx
1657
        mov     eax, [d_width_calc_area + ebx*4]
1651
        mov     eax, [BPSLine_calc_area+ebx*4]
1658
        cmp     [ScreenBPP], byte 32
-
 
1659
        je      .32
-
 
1660
        lea     eax, [eax+eax*2]
-
 
1661
        jmp     @f
-
 
1662
;-------------------------------------
-
 
1663
align 4
-
 
1664
.32:
-
 
1665
        shl     eax, 2
-
 
1666
;-------------------------------------
-
 
1667
align 4
-
 
1668
@@:
-
 
1669
        xchg    ebp, eax
1652
        xchg    ebp, eax
1670
        add     ebp, eax
1653
        add     ebp, eax
1671
        add     ebp, eax
1654
        add     ebp, eax
1672
        add     ebp, eax
1655
        add     ebp, eax
1673
        cmp     [ScreenBPP], byte 24    ; 24 or 32 bpp ? - x size
1656
        cmp     [ScreenBPP], byte 24    ; 24 or 32 bpp ? - x size
Line 1809... Line 1792...
1809
        mov     ebp, [draw_data+32+RECT.left]   ; x start
1792
        mov     ebp, [draw_data+32+RECT.left]   ; x start
1810
; 1) Calculate pointers in WinMapAddress (does pixel belong to OS thread?) [ebp]
1793
; 1) Calculate pointers in WinMapAddress (does pixel belong to OS thread?) [ebp]
1811
;                       and LFB data (output for our function) [edi]
1794
;                       and LFB data (output for our function) [edi]
1812
;        mov     eax, [BytesPerScanLine]
1795
;        mov     eax, [BytesPerScanLine]
1813
;        mul     ebx
1796
;        mul     ebx
1814
        mov     eax, [d_width_calc_area + ebx*4]
1797
        mov     eax, [BPSLine_calc_area+ebx*4]
1815
        cmp     [ScreenBPP], byte 32
-
 
1816
        je      .32
-
 
1817
        lea     eax, [eax+eax*2]
-
 
1818
        jmp     @f
-
 
1819
;-------------------------------------
-
 
1820
align 4
-
 
1821
.32:
-
 
1822
        shl     eax, 2
-
 
1823
;-------------------------------------
-
 
1824
align 4
-
 
1825
@@:
-
 
1826
 
-
 
1827
        xchg    ebp, eax
1798
        xchg    ebp, eax
1828
        add     ebp, eax
1799
        add     ebp, eax
1829
        add     ebp, eax
1800
        add     ebp, eax
1830
        add     ebp, eax
1801
        add     ebp, eax
1831
        cmp     [ScreenBPP], byte 24    ; 24 or 32 bpp ? - x size
1802
        cmp     [ScreenBPP], byte 24    ; 24 or 32 bpp ? - x size