|
|
I stuck with it and disabused my mind of whatever was plaguing it.
Primarily, it was a problem caused by evaluating the latitude using the
cartesian coordinates of the full volume of the isosurface contained_by shape.
That threw everything out of the valid -1 to 1 input range for the acos
function.
Just for future reference:
#declare Length = function (X, Y, Z) {sqrt(pow(X,2)+pow(Y,2)+pow(Z,2))}
#declare Lat = function (X, Y, Z) {acos ( min(Y/Length(X, Y, Z), 1) )}
#declare Long = function (X, Y, Z) {atan2 (Z, X)}
The displacement-map isosurface is on the left, and the bump_map from the same
image is on the right.
{whew}
Post a reply to this message
Attachments:
Download 'sphericalheightfieldtest.png' (211 KB)
Preview of image 'sphericalheightfieldtest.png'
|
|