From d78900cd1497441d7712805b08072e46ee361ff8 Mon Sep 17 00:00:00 2001 From: Takamichi Horikawa Date: Sun, 19 Feb 2017 17:25:56 +0900 Subject: add opna status display --- fmdsp/fmdsp.h | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'fmdsp/fmdsp.h') diff --git a/fmdsp/fmdsp.h b/fmdsp/fmdsp.h index f123138..9a67bc7 100644 --- a/fmdsp/fmdsp.h +++ b/fmdsp/fmdsp.h @@ -2,12 +2,15 @@ #define MYON_FMDSP_H_INCLUDED #include +#include #include "font.h" #ifdef __cplusplus extern "C" { #endif +struct opna; + enum { PC98_W = 640, PC98_H = 400 @@ -17,11 +20,18 @@ enum { FMDSP_PALETTE_COLORS = 9 }; +enum FMDSP_DISPSTYLE { + FMDSP_DISPSTYLE_DEFAULT, + FMDSP_DISPSTYLE_OPN, + FMDSP_DISPSTYLE_CNT +}; + struct fmdsp { uint8_t palette[FMDSP_PALETTE_COLORS*3]; uint8_t target_palette[FMDSP_PALETTE_COLORS*3]; const struct fmdsp_font *font98; - + enum FMDSP_DISPSTYLE style; + bool style_updated; }; struct fmdriver_work; @@ -29,10 +39,12 @@ void fmdsp_init(struct fmdsp *fmdsp, const struct fmdsp_font *font); void fmdsp_vram_init(struct fmdsp *fmdsp, struct fmdriver_work *work, uint8_t *vram); -void fmdsp_update(struct fmdsp *fmdsp, const struct fmdriver_work *work, uint8_t *vram); +void fmdsp_update(struct fmdsp *fmdsp, const struct fmdriver_work *work, + const struct opna *opna, uint8_t *vram); void fmdsp_vrampalette(struct fmdsp *fmdsp, const uint8_t *vram, uint8_t *vram32, int stride); void fmdsp_font_from_fontrom(uint8_t *font, const uint8_t *fontrom); void fmdsp_palette_set(struct fmdsp *fmdsp, int p); +void fmdsp_dispstyle_set(struct fmdsp *fmdsp, enum FMDSP_DISPSTYLE style); #ifdef __cplusplus } #endif -- cgit v1.2.3