//*** GLOBAL VARIABLES *** // Written by Jarek Rossignac, June 2006 // CAMERA pt Origin=new pt(0,0,0); pt Eye=new pt(0,0,800); cam C = new cam(Eye, Origin); cam C1 = new cam(Eye, Origin); cam C2 = new cam(Eye, Origin); float svd=800; //float fov=atan2(width/2,svd); float fov=PI/3; pt Cbox = new pt(width/2,height/2,0); // mini-max box center float Rbox=1000; pt mark = new pt(0,0,0); pt eye = new pt(0,0,0); // MOUSE pt Mouse = new pt(0,0,0); // current mouse position float xr, yr = 0; // mouse coordinates relative to center of window int px=0, py=0; // coordinats of mouse when it was last pressed // DISPLAY vec labelD=new vec(-10,-10, 2); // offset vector for drawing labels int showSkeletOnly=1; boolean jumps=false; int r=10; // radius of spheres for displaying vertices // VERTICES pt[] G = new pt [maxnv]; // geometry table (vertices) vec[] Nv = new vec [maxnv]; // vertex normals or laplace vectors // TRIANGLES int nt = 2*(w-1)*(w-1), maxnt = maxnv*2; // current and max number of triangles vec[] Nt = new vec [maxnt]; // vtriangles normals int[] SMt = new int[maxnt]; // sum of triangle markers for isolation boolean flipOrientation=false; // if set, save will flip all triangles boolean[] visible = new boolean[maxnt]; // set if triangle visible // CORNERS int nc = nt*3; // current number of corners (3 per triangle) int[] V = new int [3*maxnt]; // V table (triangle/vertex indices) int[] O = new int [3*maxnt]; // O table (opposite corner indices) int[] W = new int [3*maxnt]; // mid-edge vertex indices for subdivision (associated with corner opposite to edge) //COMPRESSION char[] triangleSymbol = new char[maxnt]; char[] CLERS = new char[maxnt]; int symbols=0;