rulimine/stage23/lib/fb.c

15 lines
412 B
C
Raw Normal View History

2021-03-02 08:21:05 +03:00
#include <stdint.h>
#include <stdbool.h>
#include <lib/fb.h>
#include <drivers/vbe.h>
2021-03-02 12:23:43 +03:00
#include <drivers/gop.h>
2021-03-02 08:21:05 +03:00
bool fb_init(struct fb_info *ret,
uint16_t target_width, uint16_t target_height, uint16_t target_bpp) {
2021-03-02 12:23:43 +03:00
#if defined (bios)
2021-03-02 08:21:05 +03:00
return init_vbe(ret, target_width, target_height, target_bpp);
2021-03-02 12:23:43 +03:00
#elif defined (uefi)
return init_gop(ret, target_width, target_height, target_bpp);
#endif
2021-03-02 08:21:05 +03:00
}