|
import peasy.org.apache.commons.math.*;
import peasy.*;
import peasy.org.apache.commons.math.geometry.*;
import processing.opengl.*;
import toxi.geom.*;
import toxi.geom.mesh.*;
import toxi.volume.*;
import toxi.math.noise.*;
import processing.opengl.*;
int DIMX=100;
int DIMY=100;
int DIMZ=100;
float ISO_THRESHOLD = 0.02;
float NS=0.05;
Vec3D SCALE=new Vec3D(DIMX,DIMY,DIMZ).scaleSelf(1);
boolean isWireframe=false;
float currScale=1;
VolumetricSpace volume=new VolumetricSpace(SCALE,DIMX,DIMY,DIMZ);
IsoSurface surface=new IsoSurface(volume);
TriangleMesh mesh;
PeasyCam cam;
void setup() {
size(800,600,OPENGL);
hint(ENABLE_OPENGL_4X_SMOOTH);
cam = new PeasyCam(this, 200);
cam.setMinimumDistance(50);
cam.setMaximumDistance(500);
float[] volumeData=volume.getData();
for(int z=0,index=0; z |
评分
-
查看全部评分
|