#ifndef _TEMPARRAY_H_ #define _TEMPARRAY_H_ #include "Cubehole.h" #include "gl.h" #include "Triangle.h" #include #include class Temparray { public: Temparray(float initialtemp, int x0, int y0, int z0); Temparray(){} ~Temparray(){} void calcTemp(); float& temperatureold(int x, int y, int z, int line, int pos) { return temparrayold[x*sy*sz*6*4 + y*sz*6*4 + z*6*4 + line*4 + pos]; } float& temperaturenew(int x, int y, int z, int line, int pos) { return temparraynew[x*sy*sz*6*4 + y*sz*6*4 + z*6*4 + line*4 + pos]; } std::list getTriangles(); void coloring(); void setprobetemp(float t){probetemp = t;} void setinput(float input0){input = input0;} private: float *temparrayold, *temparraynew; Cubehole *cubearray; int sx, sy, sz; float averagetemp, earthtemp, probetemp, input; Cubehole& cubehole(int x, int y, int z, int line) { return cubearray[x*sy*sz*6 + y*sz*6 + z*6 + line]; } void mergetemperature(){ for(int i=0; i