/demos/trunk/mesatex/mesatex.c |
---|
33,7 → 33,7 |
#endif |
#define WIDTH 640 |
#define HEIGHT 480 |
#define HEIGHT 430 |
#define BYTES_PP 2 //BytesPerPixel |
OSMesaContext ctx; |
57,8 → 57,8 |
unsigned long int VMEMLONG = WIDTH * HEIGHT * BYTES_PP / 4; // Used by copy_videomem_16to16 |
unsigned long int RGB565MEM = WIDTH * HEIGHT * BYTES_PP; // Total video mem |
unsigned long int PERIOD_REFRESH = 60000; |
unsigned long int PERIOD_DISEGNA = 60000; |
unsigned long int PERIOD_REFRESH = 30000; |
unsigned long int PERIOD_DISEGNA = 30000; |
unsigned long int WCET_REFRESH, WCET_DISEGNA; |
123,24 → 123,24 |
static int twidth=8, theight=8; |
static GLubyte tex1[] = { |
0, 0, 0, 0, 0, 0, 0, 0, |
0, 0, 0, 0, 1, 0, 0, 0, |
0, 0, 0, 1, 1, 0, 0, 0, |
0, 0, 0, 0, 1, 0, 0, 0, |
0, 0, 0, 0, 1, 0, 0, 0, |
0, 0, 0, 0, 1, 0, 0, 0, |
0, 0, 0, 1, 1, 1, 0, 0, |
0, 0, 0, 0, 0, 0, 0, 0 }; |
0, 0, 1, 0, 0, 0, 0, 0, |
0, 0, 1, 0, 0, 0, 0, 0, |
0, 0, 1, 0, 0, 0, 0, 0, |
0, 0, 1, 0, 0, 0, 0, 0, |
0, 0, 1, 0, 0, 0, 0, 0, |
0, 0, 1, 0, 0, 0, 0, 0, |
0, 0, 0, 1, 1, 1, 0, 0 }; |
static GLubyte tex2[] = { |
0, 0, 0, 0, 0, 0, 0, 0, |
0, 0, 0, 2, 2, 0, 0, 0, |
0, 0, 2, 0, 0, 2, 0, 0, |
0, 0, 0, 2, 2, 2, 0, 0, |
0, 0, 2, 0, 0, 0, 0, 0, |
0, 0, 2, 0, 0, 0, 0, 0, |
0, 0, 0, 2, 0, 0, 0, 0, |
0, 0, 0, 0, 2, 0, 0, 0, |
0, 0, 0, 0, 0, 2, 0, 0, |
0, 0, 0, 0, 2, 0, 0, 0, |
0, 0, 0, 2, 0, 0, 0, 0, |
0, 0, 2, 2, 2, 2, 0, 0, |
0, 0, 0, 0, 0, 0, 0, 0 }; |
0, 0, 0, 0, 0, 2, 0, 0, |
0, 0, 2, 2, 2, 0, 0, 0 }; |
GLubyte tex[64][3]; |
GLint i, j; |
295,7 → 295,7 |
while(1) { |
memcpy(rgb_565_buf, video_buf, RGB565MEM); |
memcpy((video_buf+40*WIDTH*2), rgb_565_buf, RGB565MEM); |
task_endcycle(); |
} |
/demos/trunk/mesademo/mesademo.c |
---|
33,7 → 33,7 |
#endif |
#define WIDTH 640 |
#define HEIGHT 480 |
#define HEIGHT 430 |
#define BYTES_PP 2 //BytesPerPixel |
OSMesaContext ctx; |
44,8 → 44,8 |
unsigned long int VMEMLONG = WIDTH * HEIGHT * BYTES_PP / 4; // Used by copy_videomem_16to16 |
unsigned long int RGB565MEM = WIDTH * HEIGHT * BYTES_PP; // Total video mem |
unsigned long int PERIOD_REFRESH = 100000; |
unsigned long int PERIOD_DISEGNA = 100000; |
unsigned long int PERIOD_REFRESH = 45000; |
unsigned long int PERIOD_DISEGNA = 45000; |
unsigned long int WCET_REFRESH, WCET_DISEGNA; |
300,7 → 300,7 |
while(1) { |
memcpy(rgb_565_buf, video_buf, RGB565MEM); |
memcpy((video_buf+40*WIDTH*2), rgb_565_buf, RGB565MEM); |
task_endcycle(); |
} |
326,9 → 326,9 |
draw(); |
sprintf(text,"Hard Task Refresh PER:%6d us EX:%6d us",(int)PERIOD_REFRESH,(int)refresh_TIME); |
grx_text(text,10,5,rgb16(0,0,255),0); |
grx_text(text,10,5,color16(0,0,255),0); |
sprintf(text,"Hard Task Draw PER:%6d us EX:%6d us",(int)PERIOD_DISEGNA,(int)disegna_TIME); |
grx_text(text,10,15,rgb16(0,0,255),0); |
grx_text(text,10,15,color16(0,0,255),0); |
task_endcycle(); |
347,7 → 347,7 |
clear(); |
WCET_REFRESH =((long int) PERIOD_REFRESH * (0.25)); |
WCET_REFRESH =((long int) PERIOD_REFRESH * (0.35)); |
WCET_DISEGNA =((long int) PERIOD_DISEGNA * (0.6)); |
hard_task_default_model(ht_refresh); |