mirror of
https://github.com/marqs85/ossc
synced 2026-11-05 14:40:08 +03:00
advanced OSD implementation
This commit is contained in:
1 parent
b26b213ead
commit
9c5e7b5b83
25 files changed
+9287
-8726
No files matched your search
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// Copyright (C) 2019 Markus Hiienkari <mhiienka@niksula.hut.fi>
|
||||
// Copyright (C) 2019-2020 Markus Hiienkari <mhiienka@niksula.hut.fi>
|
||||
//
|
||||
// This file is part of Open Source Scan Converter project.
|
||||
//
|
||||
@@ -20,32 +20,42 @@
|
||||
#ifndef OSD_GENERATOR_REGS_H_
|
||||
#define OSD_GENERATOR_REGS_H_
|
||||
|
||||
#include <alt_types.h>
|
||||
#define OSD_CHAR_ROWS 30
|
||||
#define OSD_CHAR_COLS 16
|
||||
#define OSD_CHAR_SECTIONS 2
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
typedef union {
|
||||
struct {
|
||||
alt_u8 enable:1;
|
||||
alt_u8 status_refresh:1;
|
||||
alt_u8 menu_active:1;
|
||||
alt_u8 status_timeout:2;
|
||||
alt_u8 x_offset:3;
|
||||
alt_u8 y_offset:3;
|
||||
alt_u8 x_size:2;
|
||||
alt_u8 y_size:2;
|
||||
alt_u32 osd_rsv:17;
|
||||
uint8_t enable:1;
|
||||
uint8_t status_refresh:1;
|
||||
uint8_t menu_active:1;
|
||||
uint8_t status_timeout:2;
|
||||
uint8_t x_offset:3;
|
||||
uint8_t y_offset:3;
|
||||
uint8_t x_size:2;
|
||||
uint8_t y_size:2;
|
||||
uint8_t border_color:2;
|
||||
uint32_t osd_rsv:15;
|
||||
} __attribute__((packed, __may_alias__));
|
||||
alt_u32 data;
|
||||
uint32_t data;
|
||||
} osd_config_reg;
|
||||
|
||||
// char regs
|
||||
typedef struct {
|
||||
char row1[16];
|
||||
char row2[16];
|
||||
} osd_char_regs;
|
||||
char data[OSD_CHAR_ROWS][OSD_CHAR_SECTIONS][OSD_CHAR_COLS];
|
||||
} osd_char_array;
|
||||
|
||||
typedef struct {
|
||||
uint32_t mask;
|
||||
} osd_enable_color_reg;
|
||||
|
||||
typedef struct {
|
||||
osd_char_array osd_array;
|
||||
osd_config_reg osd_config;
|
||||
osd_char_regs osd_chars;
|
||||
osd_enable_color_reg osd_sec_enable[OSD_CHAR_SECTIONS];
|
||||
osd_enable_color_reg osd_row_color;
|
||||
} __attribute__((packed, __may_alias__)) osd_regs;
|
||||
|
||||
#endif //OSD_GENERATOR_REGS_H_
|
||||
Reference in new issue
Block a user