/* Bruce Maxwell Fall 2014 2D View test function */ #include #include #include #include "graphics.h" void setWhite( Image *src ); void setWhite( Image *src ) { int i, j; Color White; color_set(&White, 1.0, 1.0, 1.0); for(i=0;irows;i++) { for(j=0;jcols;j++) { image_setColor( src, i, j, White ); } } } int main(int argc, char *argv[]) { const int nLines = 50; const int nFrames = 50; const int rows = 180; const int cols = 320; View2D view; Matrix vtm; Matrix ltm; Line line[nLines]; Line tline; float orient[nLines]; float freq[nLines]; Color color[nLines]; int i, t; char filename[256]; Image *src; src = image_create( rows, cols ); srand48(0x01234ABCD); // make a bunch of random lines in the [0,1] square for(i=0;i