Page 1 of 1
How to enter and use VESA Video Modes ?
Posted: Fri Apr 08, 2016 5:44 am
by DeezRamChips
Hi, as said in the title, i was wondering how could i enter the vesa mode and plot pixels
I took time to read the page on the iki but i still dont understand :/
For the ones ho are interested, here is the source code :
https://github.com/AlexandreRouma/PenutOS
Thanks for your help
Re: How to enter and use VESA Video Modes ?
Posted: Fri Apr 08, 2016 6:17 am
by Combuster
Since you've read the wiki, which method do you plan to use and what about it don't you understand?
Re: How to enter and use VESA Video Modes ?
Posted: Fri Apr 08, 2016 6:19 am
by DeezRamChips
Well, since I want to use my own bootloader, I want to change it at startup (just before entering P-Mode)
Re: How to enter and use VESA Video Modes ?
Posted: Fri Apr 08, 2016 6:24 am
by DeezRamChips
And, what I dont understand, is how to plot a pixel after a changed the mode (i successfully change to 800 x 600 x16M) but i doesn't want to display anything so i assume i didn't change the mode correctly :/
Re: How to enter and use VESA Video Modes ?
Posted: Fri Apr 08, 2016 6:33 am
by Combuster
The
VESA tells you to use three functions, one to get a list of modes, one to get information about a specific mode (to see if it is what you want), and one to set a mode, including full pseudocode. To what extent is that insufficient?
In addition, you'll know setting the mode works if the screen gets cleared.
Re: How to enter and use VESA Video Modes ?
Posted: Fri Apr 08, 2016 6:35 am
by BrightLight
VESA says use function 0x4F01 to get the address of the framebuffer. You then write to the framebuffer to display pixels.
EDIT: Are you sure bit 14 (value 0x4000) of BX is set when you call function 0x4F02? You need to enable the linear frame buffer.