Parent Directory
|
Revision Log
|
Revision Graph
|
Patch
--- MITgcm_contrib/darwinview/src/darwin.c 2007/08/03 19:14:34 1.9
+++ MITgcm_contrib/darwinview/src/darwin.c 2009/01/08 13:34:48 1.10
@@ -29,7 +29,7 @@
#define DOWN 103
#define RIGHT 102
#define LEFT 100
-#define MAX 700
+#define MAX 100
#define SCALE .06
int NX, NY, NZ;
@@ -40,7 +40,7 @@
void readnames( char[] ), readjet(), readdepths( char[] );
float data[MAX][MAX*MAX], mxval, mnval, jet[64][3], globalmx=0, globalmn=100;
-int glo=0, usr=0, anim=0, endian=0, logscale=0, xz=0, yz=0, nonegs=1, scaledepth=0;
+int glo=0, usr=0, anim=0, endian=1, logscale=0, xz=0, yz=0, nonegs=1, scaledepth=0;
int win[MAX], depths[MAX], ilev=1, howmany, sets, count=0, xmax, ymax, yoffset=0, xoffset=0;
int totaldepth=0, scalecount=0;
char initfns[MAX][MAX], fns[MAX][MAX][MAX];
@@ -567,13 +567,16 @@
char str[MAX], filename[MAX];
FILE* fp;
+ printf("Hello 1\n");
if( strcmp(argv[1], "binary") == 0 ) // if data files are binary open binconfig
fp=fopen( ".darwinview/binconfig", "r" );
else
if( strcmp(argv[1],"netcdf") == 0 ) // if data files are netcdf open ncconfig
fp=fopen( ".darwinview/ncconfig", "r" );
+ printf("Hello 2\n");
fscanf( fp, "%dx%d ", &winx, &winy ); // read in screen resolution
+ printf("Hello 3\n");
winy-=60; winx-=20; // adjust resolution so edges won't get cut off
fscanf( fp, "%d %d %d ", &NX, &NY, &NZ ); // read in dimensions of data
fscanf( fp, "%dx%d ", &setsx, &setsy ); // read in dimensions of subwindows
@@ -582,10 +585,14 @@
fclose( fp ); // close file
xmax=NX; ymax=NY; // default to xy
+ printf("Hello 4\n");
readjet(); // stores color values
+ printf("Hello 5\n");
readnames( filename ); // gets list of filenames to read from
+ printf("Hello 6\n");
global(); // calculates max and min for all data
+ printf("Hello 7\n");
glutInit( &argc, argv );
glutInitDisplayMode( GLUT_RGB | GLUT_DOUBLE ); // set rgb mode and double buffering
| ViewVC Help | |
| Powered by ViewVC 1.1.22 |