7 #include <sys/nearptr.h>
9 static int driver_init(
char *title,
int w,
int h,
int depth,
int refresh_rate,
int flags);
38 static int driver_init(
char *title,
int w,
int h,
int depth_arg,
int refresh_rate,
int flags)
40 int depth =
MAX(8, depth_arg);
42 int red_pos, blue_pos;
77 is_rgb = (depth > 8) && (red_pos == 0);
79 if (blue_pos == 10 || red_pos == 10)
81 else if (blue_pos == 11 || red_pos == 11)
94 __djgpp_nearptr_enable();
99 if (__dpmi_physical_address_mapping(&
mapping) != 0)
102 video = (
unsigned char *)(
mapping.address - __djgpp_base_address);
104 return fb_dos_init(title, w, h, depth, refresh_rate, flags);
111 __dpmi_free_physical_address_mapping(&
mapping);
117 __djgpp_nearptr_disable();