1.1 --- a/include/display_config.h Tue Oct 23 23:25:47 2018 +0200
1.2 +++ b/include/display_config.h Wed Oct 24 00:50:48 2018 +0200
1.3 @@ -1,5 +1,5 @@
1.4 /*
1.5 - * VGA-specific display-related functions.
1.6 + * Initialisation of application-specific display configuration.
1.7 *
1.8 * Copyright (C) 2018 Paul Boddie <paul@boddie.org.uk>
1.9 *
1.10 @@ -17,22 +17,36 @@
1.11 * along with this program. If not, see <http://www.gnu.org/licenses/>.
1.12 */
1.13
1.14 -#ifndef __DISPLAY_VGA_H__
1.15 -#define __DISPLAY_VGA_H__
1.16 +#ifndef __DISPLAY_CONFIG_H__
1.17 +#define __DISPLAY_CONFIG_H__
1.18
1.19 #include "display.h"
1.20
1.21 uint8_t framebuffer[SCREEN_SIZE];
1.22
1.23 display_config_t display_config = {
1.24 +
1.25 + /* Set the reserved memory as the framebuffer. */
1.26 +
1.27 .framebuffer = framebuffer,
1.28 + .screen_start = framebuffer,
1.29 + .screen_limit = framebuffer + SCREEN_SIZE,
1.30 +
1.31 + /* Define screen dimensions and properties. */
1.32 +
1.33 .screen_size = SCREEN_SIZE,
1.34 .line_length = LINE_LENGTH,
1.35 .line_count = LINE_COUNT,
1.36 .line_multiplier = LINE_MULTIPLIER,
1.37 .cell_size = CELL_SIZE,
1.38 - .screen_start = framebuffer,
1.39 - .screen_limit = framebuffer + SCREEN_SIZE,
1.40 +
1.41 + /* Define display region properties. */
1.42 +
1.43 + .visible_start = VISIBLE_START,
1.44 + .vfp_start = VFP_START,
1.45 + .vsync_start = VSYNC_START,
1.46 + .vsync_end = VSYNC_END,
1.47 +
1.48 };
1.49
1.50 -#endif /* __DISPLAY_VGA_H__ */
1.51 +#endif /* __DISPLAY_CONFIG_H__ */