Rev 1245 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1245 | Rev 6619 | ||
---|---|---|---|
Line 45... | Line 45... | ||
45 | or edx,ebx ; if any *one* of them is negative a sign flag is raised |
45 | or edx,ebx ; if any *one* of them is negative a sign flag is raised |
46 | or edx,ecx |
46 | or edx,ecx |
47 | test edx,80008000h ; Check both X&Y at once |
47 | test edx,80008000h ; Check both X&Y at once |
48 | jne .end_triangle |
48 | jne .end_triangle |
Line -... | Line 49... | ||
- | 49 | ||
49 | 50 | mov dx,[size_x_var] |
|
50 | cmp word[.x1],SIZE_X ; { |
51 | cmp word[.x1],dx ;SIZE_X ; { |
51 | jg .end_triangle |
52 | jg .end_triangle |
52 | cmp word[.x2],SIZE_X ; This can be optimized with effort |
53 | cmp word[.x2],dx ;SIZE_X ; This can be optimized with effort |
53 | jg .end_triangle |
54 | jg .end_triangle |
54 | cmp word[.x3],SIZE_X |
55 | cmp word[.x3],dx ;SIZE_X |
Line 55... | Line 56... | ||
55 | jg .end_triangle ; } |
56 | jg .end_triangle ; } |
56 | 57 | ||
57 | shr eax,16 |
58 | shr eax,16 |
Line 174... | Line 175... | ||
174 | ;---------edx - y position of line |
175 | ;---------edx - y position of line |
175 | ;---------edi - pointer to buffer |
176 | ;---------edi - pointer to buffer |
176 | jcxz .end_hor_l |
177 | jcxz .end_hor_l |
177 | ; or edx,edx |
178 | ; or edx,edx |
178 | ; jl .end_hor_l |
179 | ; jl .end_hor_l |
- | 180 | movzx esi,word[size_y_var] |
|
179 | cmp edx,SIZE_Y |
181 | cmp edx,esi ;SIZE_Y |
180 | jg .end_hor_l |
182 | jg .end_hor_l |
181 | push eax |
183 | push eax |
- | 184 | movzx eax,word[size_x_var] |
|
182 | mov eax,SIZE_X*3 |
185 | lea eax,[eax*3] |
- | 186 | ; mov eax,SIZE_X*3 |
|
183 | mul edx |
187 | mul edx |
184 | add edi,eax ; calculate line begin adress |
188 | add edi,eax ; calculate line begin adress |
185 | ;add edi,ebx |
189 | ;add edi,ebx |
186 | ;shl ebx,1 |
190 | ;shl ebx,1 |
187 | lea edi,[edi+ebx*2] |
191 | lea edi,[edi+ebx*2] |