aboutsummaryrefslogtreecommitdiff
path: root/src/graphics
diff options
context:
space:
mode:
authorChristian Cunningham <cc@localhost>2022-03-02 15:36:24 -0700
committerChristian Cunningham <cc@localhost>2022-03-02 15:36:24 -0700
commit4c74418b1d97b2e9f7daeea365d5018db199fca7 (patch)
treecf3c2672343c6dd75e316003d2cf4242a30c3d40 /src/graphics
parentc31227d9046c3ab853255f89358966fe0721e957 (diff)
Ensure one test is added
Mount and export make
Diffstat (limited to 'src/graphics')
-rw-r--r--src/graphics/lfb.c22
1 files changed, 4 insertions, 18 deletions
diff --git a/src/graphics/lfb.c b/src/graphics/lfb.c
index 8f7ad06..8c9c395 100644
--- a/src/graphics/lfb.c
+++ b/src/graphics/lfb.c
@@ -3,12 +3,9 @@
#include <graphics/glyphs.h>
#include <graphics/lfb.h>
#include <graphics/mbox.h>
-#include <graphics/philosopher_toad.h>
unsigned char *lfb; /* raw frame buffer address */
-//#define SCR_WIDTH 1024
-//#define SCR_HEIGHT 768
#define SCR_WIDTH 1920
#define SCR_HEIGHT 1080
@@ -92,21 +89,10 @@ void clear_screen(void)
void lfb_showpicture(void)
{
clear_screen();
- unsigned int x,y;
- unsigned char *ptr=lfb;
- char *data=toad_data, pixel[4];
-
- ptr = lfb + (gheight-toad_height)*gpitch + (gwidth-toad_width)*4;
- for(y=0;y<toad_height;y++) {
- for(x=0;x<toad_width;x++) {
- HEADER_PIXEL(data, pixel);
- // the image is in RGB. So if we have an RGB framebuffer, we can copy the pixels
- // directly, but for BGR we must swap R (pixel[0]) and B (pixel[2]) channels.
- *((unsigned int*)ptr)=gisrgb ? *((unsigned int *)&pixel) : (unsigned int)(pixel[0]<<16 | pixel[1]<<8 | pixel[2]);
- ptr+=4;
- }
- ptr+=gpitch-toad_width*4;
- }
+#define FWIDTH 240
+#define FHEIGHT 80
+ draw_cbox(SCR_WIDTH-FWIDTH, SCR_HEIGHT-FHEIGHT*2, FWIDTH, FHEIGHT, 0x0057b7);
+ draw_cbox(SCR_WIDTH-FWIDTH, SCR_HEIGHT-FHEIGHT, FWIDTH, FHEIGHT, 0xffd700);
}
void draw_cpixel(unsigned long lx, unsigned long ly, unsigned int c)