-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.c
27 lines (23 loc) · 960 Bytes
/
main.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#include <reg52.h>
#include <graphics.h>
#include <math.h>
#include <stdlib.h>
void main()
{
graphics_init();
draw_line(0, 0, SCREEN_RESOLUTION_X_MAX, SCREEN_RESOLUTION_Y_MAX, RGB(RGBMAX, RGBMAX, RGBMAX));
draw_line(SCREEN_RESOLUTION_X_MAX, 0, 0, SCREEN_RESOLUTION_Y_MAX, RGB(RGBMAX, RGBMAX, RGBMAX));
draw_line(0, 0, SCREEN_RESOLUTION_X_MAX, 0, RGB(RGBMAX, RGBMAX, RGBMAX));
draw_line(SCREEN_RESOLUTION_X_MAX, 0, SCREEN_RESOLUTION_X_MAX, SCREEN_RESOLUTION_Y_MAX, RGB(RGBMAX, RGBMAX, RGBMAX));
draw_line(SCREEN_RESOLUTION_X_MAX, SCREEN_RESOLUTION_Y_MAX, 0, SCREEN_RESOLUTION_Y_MAX, RGB(RGBMAX, RGBMAX, RGBMAX));
draw_line(0, SCREEN_RESOLUTION_Y_MAX, 0, 0, RGB(RGBMAX, RGBMAX, RGBMAX));
while (1)
{
// uint color = RGB(rand() % RGBMAX, rand() % RGBMAX, rand() % RGBMAX);
// int i = 0;
// for (i = 0; i <= SCREEN_RESOLUTION_Y_MAX; i++)
// {
// draw_line(0, i, SCREEN_RESOLUTION_X_MAX, i, color);
// }
}
}