Text Mode Cursor: Difference between revisions
[unchecked revision] | [unchecked revision] |
Content deleted Content added
m →Without the BIOS: Add code to get the cursor position. |
|||
Line 163:
===Get Cursor Data===
With this code, you get: <tt>pos = y * VGA_WIDTH + x</tt>. To obtain the coordinates, just calculate: <tt>y = pos / VGA_WIDTH; x = pos % VGA_WIDTH</tt>.
'''Source in C'''
|