00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef __VOXEL_0_H__
00022 #define __VOXEL_0_H__
00023
00024 #include "voxel.h"
00025
00040 class voxel_0_c : public voxel_c {
00041
00042 public:
00043
00044 voxel_0_c(unsigned int x, unsigned int y, unsigned int z, const gridType_c * gt, voxel_type init = 0) : voxel_c(x, y, z, gt, init) {}
00045 voxel_0_c(xmlParser_c & pars, const gridType_c * gt) : voxel_c(pars, gt) {}
00046 voxel_0_c(const voxel_c & orig) : voxel_c(orig) { }
00047 voxel_0_c(const voxel_c * orig) : voxel_c(orig) { }
00048
00049 void transformPoint(int * x, int * y, int * z, unsigned int trans) const;
00050 bool transform(unsigned int nr);
00051
00052 bool getNeighbor(unsigned int idx, unsigned int typ, int x, int y, int z, int * xn, int *yn, int *zn) const;
00053
00054 virtual void scale(unsigned int amount, bool grid);
00055 bool scaleDown(unsigned char by, bool action);
00056 void resizeInclude(int & px, int & py, int & pz);
00057
00058 bool validCoordinate(int x, int y, int z) const;
00059 bool onGrid(int x, int y, int z) const;
00060
00061 virtual void getConnectionFace(int x, int y, int z, int n, double bevel, double offset, std::vector<float> & faceCorners) const;
00062 virtual void calculateSize(float * x, float * y, float * z) const;
00063 virtual bool meshParamsValid(double bevel, double offset) const;
00064
00065 private:
00066
00067
00068 void operator=(const voxel_0_c&);
00069 };
00070
00071 #endif