Title: 3D IFS and Hart's method Post by: David Makin on August 25, 2011, 10:47:40 PM This is by way of an apology for not recognising this optimisation previously and to actually point out the optimisation itself to those interested.
Hart's method using divergent transforms (i.e. inverses of the normal convergent ones) relies on intersecting a ray with the IFS attractor by performing a "full" IFS tree calculation but culling those branches where the viewing ray being tested is outside the bounds for that point in the tree. The method is fairly optimum even when using plain bounding spheres. However normally and in the way I implemented it in Ultra Fractal each viewing ray is intersected with the IFS attractor using the viewpoint (or other point on the ray) and the normalised viewing direction vector of the ray *but* I just realised that there is a more optimum method to perform the intersection. If for each pixel/viewing ray one transforms the base IFS transforms such that they are in a coordinate system such that the viewing ray is the x axis i.e. passes through (0,0,0) with viewing vector (1,0,0) then the intersection/bounding checks *at every step through the IFS tree* will be vastly more optimum greatly outweighing the measly 2n transforms of the n base transforms required to give the specific transforms for the particular pixel/ray. Title: Re: 3D IFS and Hart's method Post by: David Makin on August 26, 2011, 05:20:33 AM Erm - I just realised that the optimisation requires more modification than I first thought - the advantage of the viewing ray being the x-axis is only maintained throughout if the intersections are performed between the fixed axis and the transformed bounding volumes - of course it actually makes more sense in "normal" 3D orientation to transform the IFS transforms such that they're in a space such that the viewing ray is the z-axis rather than the x. i.e. the method requires that the bounding volumes are transformed rather than the viewing rays, in which case it's perhaps not as much more optimum as I thought and will depend on the number of IFS transforms involved and the complexity of the bounding volume definition - of course plain spherical bounds would be fairly simple to transform i.e. new centre and new radius. |