Search
lxdream.org :: lxdream :: r306:818c11570593
lxdream 0.9.1
released Jun 29
Download Now
changeset306:818c11570593
parent305:1191085c5988
child307:a357a469f5ff
authornkeynes
dateSun Jan 21 05:23:53 2007 +0000 (17 years ago)
Add general draw_grid function
test/pvr.c
1.1 --- a/test/pvr.c Thu Jan 18 11:14:01 2007 +0000
1.2 +++ b/test/pvr.c Sun Jan 21 05:23:53 2007 +0000
1.3 @@ -1,5 +1,5 @@
1.4 /**
1.5 - * $Id: pvr.c,v 1.3 2006-08-18 09:33:19 nkeynes Exp $
1.6 + * $Id: pvr.c,v 1.4 2007-01-21 05:23:53 nkeynes Exp $
1.7 *
1.8 * PVR support code
1.9 *
1.10 @@ -475,3 +475,19 @@
1.11 pvr_init_video(pvr_check_cable(), 1, 2);
1.12 }
1.13
1.14 +void draw_grid( unsigned short *addr, unsigned short colour )
1.15 +{
1.16 + int x,y;
1.17 + unsigned int linesize = 640;
1.18 + for( x=0; x<640; x+=32 ) {
1.19 + for( y=0; y<480; y++ ) {
1.20 + addr[(linesize*y) + x] = colour;
1.21 + }
1.22 + }
1.23 + for( y=0; y<480; y+=32 ) {
1.24 + for( x=0; x<640; x++ ) {
1.25 + addr[(linesize*y) + x] = colour;
1.26 + }
1.27 + }
1.28 +
1.29 +}
.