aboutsummaryrefslogtreecommitdiff
path: root/src/drivers/vga_t.hpp
blob: dd947bd53909b3caba1ce7c57398286fd8f529a0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#pragma once

#include "core/types.hpp"

typedef enum VIDEO_COLORS {
  BLACK=0, BLUE=1, GREEN=2,CYAN=3, RED=4,PURPLE=5,BROWN=6,GRAY=7,
  DARK_GRAY=8,LIGHT_BLUE=9,LIGHT_GREEN=10,LIGHT_CYAN=11,LIGHT_RED=12,LIGHT_PURPLE=13,YELLOW=14,WHITE=15
  
} VIDEO_COLORS;

typedef struct VIDEO_STATE {
  u8 *mem;
  u8 col;
  u8 line;
  u8 bg;
  u8 fg;
} VIDEO_STATE;

/**
 * Print char
 */
void vga_t_putchar(char);

/**
 * Scroll the framebuffer from one line
 */
void vga_t_scrollup();

/**
 * Clear all char from the framebuffer
 */
void vga_t_clear();