Rev 1495 | Rev 1523 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1495 | Rev 1497 | ||
---|---|---|---|
Line 55... | Line 55... | ||
55 | ;; |
55 | ;; |
56 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
56 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
Line 57... | Line 57... | ||
57 | 57 | ||
Line 58... | Line 58... | ||
58 | include 'macros.inc' |
58 | include 'macros.inc' |
Line 59... | Line 59... | ||
59 | 59 | ||
Line 60... | Line 60... | ||
60 | $Revision: 1495 $ |
60 | $Revision: 1497 $ |
Line 4567... | Line 4567... | ||
4567 | mov [eax+12], edx |
4567 | mov [eax+12], edx |
4568 | mov [eax], edx |
4568 | mov [eax], edx |
4569 | mov [esp+32], edx |
4569 | mov [esp+32], edx |
4570 | ret |
4570 | ret |
Line -... | Line 4571... | ||
- | 4571 | ||
- | 4572 | ||
- | 4573 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|
- | 4574 | ;; 61 sys function. ;; |
|
- | 4575 | ;; in eax=61,ebx in [1..3] ;; |
|
- | 4576 | ;; out eax ;; |
|
- | 4577 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
|
- | 4578 | iglobal |
|
- | 4579 | align 4 |
|
- | 4580 | f61call: |
|
- | 4581 | dd sys_gs.1 ; resolution |
|
- | 4582 | dd sys_gs.2 ; bits per pixel |
|
- | 4583 | dd sys_gs.3 ; bytes per scanline |
|
- | 4584 | endg |
|
- | 4585 | ||
4571 | 4586 | ||
Line 4572... | Line 4587... | ||
4572 | align 4 |
4587 | align 4 |
- | 4588 | ||
- | 4589 | sys_gs: ; direct screen access |
|
- | 4590 | dec ebx |
|
- | 4591 | cmp ebx,2 |
|
- | 4592 | ja .not_support |
|
- | 4593 | jmp dword [f61call+ebx*4] |
|
- | 4594 | .not_support: |
|
Line -... | Line 4595... | ||
- | 4595 | or [esp+32],dword -1 |
|
4573 | 4596 | ret |
|
4574 | sys_gs: ; direct screen access |
- | |
4575 | 4597 | ||
4576 | cmp eax,1 ; resolution |
4598 | |
4577 | jne no_gs1 |
4599 | .1: ; resolution |
4578 | mov eax,[Screen_Max_X] |
4600 | mov eax,[Screen_Max_X] |
4579 | shl eax,16 |
4601 | shl eax,16 |
4580 | mov ax,[Screen_Max_Y] |
4602 | mov ax,[Screen_Max_Y] |
4581 | add eax,0x00010001 |
- | |
4582 | mov [esp+36],eax |
- | |
4583 | ret |
4603 | add eax,0x00010001 |
4584 | no_gs1: |
- | |
4585 | 4604 | mov [esp+32],eax |
|
4586 | cmp eax,2 ; bits per pixel |
4605 | ret |
4587 | jne no_gs2 |
4606 | .2: ; bits per pixel |
4588 | movzx eax,byte [ScreenBPP] |
- | |
4589 | mov [esp+36],eax |
- | |
4590 | ret |
4607 | movzx eax,byte [ScreenBPP] |
4591 | no_gs2: |
- | |
4592 | 4608 | mov [esp+32],eax |
|
4593 | cmp eax,3 ; bytes per scanline |
4609 | ret |
4594 | jne no_gs3 |
- | |
4595 | mov eax,[BytesPerScanLine] |
- | |
4596 | mov [esp+36],eax |
- | |
4597 | ret |
- | |
4598 | no_gs3: |
4610 | .3: ; bytes per scanline |
Line 4599... | Line 4611... | ||
4599 | 4611 | mov eax,[BytesPerScanLine] |