#define _SYSLINUX_VESACON_H
int vesacon_default_background(void);
+void vesacon_set_resolution(int, int);
int vesacon_load_background(const char *);
int vesacon_set_background(unsigned int);
reinitialization. */
static int vesacon_counter = 0;
+static struct {
+ int x, y;
+} vesacon_resolution = {
+ .x = DEFAULT_VESA_X_SIZE,
+ .y = DEFAULT_VESA_Y_SIZE,
+};
+
+/* Set desired resolution - requires a full close/open cycle */
+void vesacon_set_resolution(int x, int y)
+{
+ vesacon_resolution.x = x;
+ vesacon_resolution.y = y;
+}
+
/* Common setup */
int __vesacon_open(struct file_info *fp)
{
ti.cols = 80;
} else {
/* Switch mode */
- if (__vesacon_init(DEFAULT_VESA_X_SIZE, DEFAULT_VESA_Y_SIZE)) {
+ if (__vesacon_init(vesacon_resolution.x, vesacon_resolution.y)) {
vesacon_counter = -1;
return EAGAIN;
}