added support for int 10:01 set cursortype
Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@558
This commit is contained in:
parent
581774e9bc
commit
21a81276b4
3 changed files with 11 additions and 2 deletions
|
@ -20,13 +20,18 @@
|
|||
#define VGA_H_
|
||||
|
||||
#include <mem.h>
|
||||
#include "dosbox.h"
|
||||
|
||||
#undef TEXT
|
||||
#undef GRAPH
|
||||
/* conflicts with int10.h */
|
||||
enum { TEXT, GRAPH };
|
||||
enum { GFX_256C,GFX_256U,GFX_16,GFX_4,GFX_2, TEXT_16 };
|
||||
|
||||
typedef struct {
|
||||
|
||||
bool attrindex;
|
||||
Bit16u cursor;
|
||||
} VGA_Internal;
|
||||
|
||||
typedef struct {
|
||||
|
|
|
@ -176,7 +176,8 @@ void VGA_DrawTEXT(Bit8u * bitdata,Bitu pitch) {
|
|||
draw_start+=16*pitch;
|
||||
};
|
||||
VGA_StartRetrace();
|
||||
|
||||
|
||||
if(!(vga.internal.cursor & 0x2000)){
|
||||
/* Draw a cursor */
|
||||
if (((Bitu)vga.draw.cursor_col*8)>=vga.draw.width) return;
|
||||
if (((Bitu)vga.draw.cursor_row*16)>=vga.draw.height) return;
|
||||
|
@ -186,5 +187,6 @@ void VGA_DrawTEXT(Bit8u * bitdata,Bitu pitch) {
|
|||
}
|
||||
vga.draw.cursor_count++;
|
||||
if (vga.draw.cursor_count>16) vga.draw.cursor_count=0;
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -25,6 +25,7 @@
|
|||
#include "video.h"
|
||||
#include "inout.h"
|
||||
#include "int10.h"
|
||||
#include "../hardware/vga.h" /* Maybe move this thing */
|
||||
|
||||
#define TEXT_SEG 0xb800
|
||||
|
||||
|
@ -38,7 +39,8 @@ static Bitu INT10_Handler(void) {
|
|||
INT10_SetVideoMode(reg_al);
|
||||
break;
|
||||
case 0x01: /* Set TextMode Cursor Shape */
|
||||
LOG_WARN("INT10:01:Set textmode cursor shape not supported");
|
||||
vga.internal.cursor=reg_cx; // maybe write some memory somewhere
|
||||
LOG_DEBUG("INT10:01:Set textmode cursor shape partially supported: %X",reg_cx);
|
||||
break;
|
||||
case 0x02: /* Set Cursor Pos */
|
||||
//TODO Check some shit but not really usefull
|
||||
|
|
Loading…
Add table
Reference in a new issue