Rev 381 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
425 | victor | 1 | $Revision: 425 $ |
1 | ha | 2 | ; |
3 | ; Call of videomode driver's functions |
||
4 | ; |
||
5 | ; (Add in System function 21 (and/or 26) as a subfunction 13) |
||
6 | ; |
||
7 | ; Author: Trans |
||
8 | ; Date: 19.07.2003 |
||
9 | ; |
||
10 | ; Include in MeOS kernel and compile with FASM |
||
11 | ; |
||
49 | mikedld | 12 | |
13 | uglobal |
||
14 | old_screen_width dd ? |
||
15 | old_screen_height dd ? |
||
16 | endg |
||
17 | |||
1 | ha | 18 | cmp eax,13 ; CALL VIDEOMODE DRIVER FUNCTIONS |
19 | jne .no_vmode_drv_access |
||
381 | serge | 20 | pushd [ScreenWidth] [ScreenHeight] |
49 | mikedld | 21 | popd [old_screen_height] [old_screen_width] |
1 | ha | 22 | or eax,-1 ; If driver is absent then eax does not change |
23 | call 0x760100 ; Entry point of video driver |
||
24 | mov [esp+36],eax |
||
25 | mov [esp+24],ebx |
||
26 | mov [esp+32],ecx |
||
27 | ; mov [esp+28],edx |
||
49 | mikedld | 28 | mov eax,[old_screen_width] |
29 | mov ebx,[old_screen_height] |
||
381 | serge | 30 | sub eax,[ScreenWidth] |
49 | mikedld | 31 | jnz @f |
381 | serge | 32 | sub ebx,[ScreenHeight] |
49 | mikedld | 33 | jz .resolution_wasnt_changed |
34 | jmp .lp1 |
||
381 | serge | 35 | @@: sub ebx,[ScreenHeight] |
49 | mikedld | 36 | .lp1: sub [screen_workarea.right],eax |
37 | sub [screen_workarea.bottom],ebx |
||
38 | |||
39 | call repos_windows |
||
112 | poddubny | 40 | mov eax, 0 |
41 | mov ebx, 0 |
||
381 | serge | 42 | mov ecx, [ScreenWidth] |
43 | mov edx, [ScreenHeight] |
||
49 | mikedld | 44 | call calculatescreen |
45 | |||
46 | .resolution_wasnt_changed: |
||
1 | ha | 47 | ret |
48 | .no_vmode_drv_access: |