Path: utzoo!mnetor!tmsoft!torsqnt!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!ucsd!ucbvax!bloom-beacon!eru!hagbard!sunic!news.funet.fi!korppi.tut.fi!jk87377 From: jk87377@korppi.tut.fi (Kouhia Juhana Krister) Newsgroups: comp.graphics Subject: Hypertextures Message-ID: <1991Jan2.195806.25330@funet.fi> Date: 2 Jan 91 19:58:06 GMT Sender: news@funet.fi (#News ) Reply-To: jk87377@korppi.tut.fi (Kouhia Juhana Krister) Organization: Tampere University of Technology, Finland Lines: 103 Hi, I'm implementing hypertextures descriped in "Hypertexture" by Ken Perlin and Eric Hoffert in SIGGRAPH '89. Here's some what I have got now. I describe minimally, because my English language isn't that good, but I'm sure you understand if you read the above paper and start to implement that algorithm. I'm not sure that everything is correct or you understand - I post this anyway. Density in point x is D(x). D(x) = f(dis(x)) Where dis(x) is a "distance" from object. And f() is a function which define is the object soft or what ever. For example f() for the solid unit sphere is: if (dis(x) < 1.0) f = 1.0 else f = 0.0 /* or f = 1.0 - dis(x) */ That negative f in outside of the sphere can be used for the special functions that are not possible when there's zero density in outside. Sphere: ------- dis(x) = sqrt(x*x+y*y+z*z)) Cube: ----- dis(x) = max(abs(x),abs(y),abs(z)) Cylinder: --------- dis(x) = max(abs(z),sqrt(x*x+y*y)) Torus: ------ r = sqrt(x*x+y*y) p = a-r dis(x) = sqrt(z*z+p*p) Torus is in xy-plane; center is (0,0,0), big radius = a Cone: ----- u = 2.0*sqrt(x*x+y*y)+z v = abs(z) if (u < v) dis(x) = v else dis(x) = u Polyhedrons: ------------ A nearest distance to polyhedron is calculated. This causes that polyhedron's corners and edges are rounded when point x moves away from polyhedron. If point x is in inside of the polyhedron then corners and edges are sharp unless the polyhedron is concave. Another method is move the planes in direction of the normal of the plane and find a state where x is on the plane of the polyhedron. There is not a rounded corners in this model. (This is under study now.) Spline-patches: --------------- Distances from the point x are calculated to the points of the patch where the normal is toward point x. Nearest distance is dis(x). As stated in the Perlin/Hoffert paper it is very slow compute this using ray tracing. I'm now thinking about the functions which are recursively calculated and in each recursive step the details of the texture increases. This means that we can calculate a texture fast with few recursions first and when we are close enough we increase recursions to get more details. (Like as in mandelbrot set calculation; I have allready calculated it in 4D --- hmmmm... how about furry mandelbrot? :-) I'm not sure works above but somehow I try decrease calculations with the rough mode. I'm too looking the article "Global and Local Deformations of Solid Primitives" by A.H. Barr for deformations of the hyperobjects. Any ideas for implementing hypertextures? Experiences in implementing hypertextures, anyone? I'm interested in to know what is in SIGGRAPH '90 about this subject. Oh yeah, this is not my exercise. Juhana Kouhia jk87377@tut.fi