diff options
author | arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-08-22 23:03:51 +0000 |
---|---|---|
committer | arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-08-22 23:03:51 +0000 |
commit | 4ae1571dda7f29737939a91445bef2885bd0ebea (patch) | |
tree | 68fb4755bab37729823af59c011f06333cabd1e2 /linux | |
parent | 0e6edc2840af15cd9d175219521627bbc94454b2 (diff) | |
download | mpv-4ae1571dda7f29737939a91445bef2885bd0ebea.tar.bz2 mpv-4ae1571dda7f29737939a91445bef2885bd0ebea.tar.xz |
General Timing Formula algorithm from a scratch.
vo_vesa.c so now adjust the timing to highest possible refresh rate using
the monitor capabilities from a config file.
patch by Rudolf Marek <MAREKR2@cs.felk.cvut.cz>
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7070 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'linux')
-rw-r--r-- | linux/vbelib.c | 20 | ||||
-rw-r--r-- | linux/vbelib.h | 1 |
2 files changed, 21 insertions, 0 deletions
diff --git a/linux/vbelib.c b/linux/vbelib.c index 704371958b..d3fc9a445f 100644 --- a/linux/vbelib.c +++ b/linux/vbelib.c @@ -376,6 +376,26 @@ int vbeGetMode(unsigned *mode) return retval; } +int vbeGetPixelClock(unsigned *mode,unsigned *pixel_clock) // in Hz +{ + struct LRMI_regs r; + int retval; + memset(&r,0,sizeof(struct LRMI_regs)); + r.eax = 0x4f0b; + r.ebx = 0; + r.edx = *mode; + r.ecx = *pixel_clock; + if(!VBE_LRMI_int(0x10,&r)) return VBE_VM86_FAIL; + retval = r.eax & 0xffff; + if(retval == 0x4f) + { + *pixel_clock = r.ecx; + retval = VBE_OK; + } + return retval; +} + + int vbeSaveState(void **data) { struct LRMI_regs r; diff --git a/linux/vbelib.h b/linux/vbelib.h index 957c2fb550..c1ae08beb8 100644 --- a/linux/vbelib.h +++ b/linux/vbelib.h @@ -199,6 +199,7 @@ extern int vbeGetControllerInfo(struct VbeInfoBlock *); extern int vbeGetModeInfo(unsigned mode,struct VesaModeInfoBlock *); extern int vbeSetMode(unsigned mode,struct VesaCRTCInfoBlock *); extern int vbeGetMode(unsigned *mode); +extern int vbeGetPixelClock(unsigned *mode,unsigned *pixel_clock); extern int vbeSaveState(void **data); /* note never copy this data */ extern int vbeRestoreState(void *data); extern int vbeGetWindow(unsigned *win_num); /* win_A=0 or win_B=1 */ |