|
![](/i/fill.gif) |
> I still do not quite understand, what you want.
I'm sorry if I don't explain myself correctly...
> I assume at least that it could be described by
> some 2-dimensional shape that is rotated around
> the z-axis as it moves along the same.
That's it...
> In that
> case you need to describe the 2D shape by some
> 2D isosurface (isoperimeter, that is). Lets say
> that is described by f(x,y)=c. Then the 3D-shape
> is described by
> f(x*cos(w*z)+y*sin(w*z),y*cos(w*z)-x*sin(w*z))=c
> which gives an isosurface all right. Now what I
> need to know is: What is your 2D-shape? In your
> scene it is defined by
> a*(x^2+y^2)+b*x=c
> or, equivalently,
> (x+b/2a)^2+y^2=c/a+(b/2a)^2
> Now this is a circle with center (-b/2a,0) and
> radius sqrt(c/a+(b/2a)^2). Maybe you would be
> more happy with an ellipse? To define one with
> radii rx in x-direction, ry in y-direction and
> center (cx,cy) take
> f(x,y)=((x-cx)/rx)^2+((y-cy)/ry)^2
> and threshold 1. I do not know the scale in your
> scene, but maybe you would like to try
> w=1/3, cx=2, cy=0, rx=3, ry=1
The circle is the shape I'm looking for, probably an elipse would make a
better result but it would have to rotate onto its center to make the
scene look right. The circle is good!
So grabbing what you showed me, I guess this might give the results I'm
looking for...
#declare R = 0.1;
#declare Circle = function { pow(((x)/R),2)+pow(((y)/R), 2) }
isosurface {
function { Circle(x*cos(w*z)+y*sin(w*z),y*cos(w*z)-x*sin(w*z)) }
[...]
}
Though, this gives me error in MegaPov, so I wasn't able to see the
results, I believe I missed something somewhere. It tells me that
instead of the first pow in the Circle function, it was looking for a
float factor. What should I do?
Thanks,
Simon
Post a reply to this message
|
![](/i/fill.gif) |