Ok this is the BYU format (well at least this is what I think is the BYU format.) Line 1 has the number of parts, number of vertices, number of polygons and number of elements in the connectivity array. Line 2 has the start polygon number and end polygon number for part 1 Line 3 has the start polygon number and end polygon number for part 2 . . . Line 18 has the x y z coordinates for vertex 1 and vertex 2 Line 19 has the x y z coordinates for vertex 3 and vertex 4 . . . Line 12715 has the connectivity array for the first polygon example: 1 2 3 -4 vertex 1 to vertex 2 to vertex 3 to vertex 4 and back to vertex 1 a negative number show the last vertex of a polygon ------------------------------------------------------------------------- /* source to read in BYU format written by Kalvin Quinkert kalvin@uswest.com sometime between January 1992 and May 1992 */ #include #include int np,nj,npt,ncon; /* number of parts,vertices,polygons,connectivity*/ int npl[3][MAX_PARTS];/* start and end polygons for each part*/ float xpp[MAX_VERTICES]; float ypp[MAX_VERTICES]; float zpp[MAX_VERTICES]; int ivq[MAX_VERTICES];/*connectivity array*/ rwmovi(filename) char *filename; { readasc(filename); } readasc(filename) char *filename; { FILE *fp; int i; if(np>0)return 1; printf("opening %s\n",filename); if(!(fp=fopen(filename,"r"))) { fprintf(stderr,"cannot open %s\n",filename); exit(1); } fscanf(fp,"%d%d%d%d\n",&np,&nj,&npt,&ncon); for(i=0;i='0'&&ch<='9')) break; } while(1) { if(ch=='+') sign=1; else if(ch=='-') sign=-1; else if(ch>='0'&&ch<='9') value = (value*10)+(ch-'0'); return(value); } ch=fgetc(fp); } } }