![](/i/fill.gif) |
![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Hmm, I think I will just stick to the isosurfaces. :-)
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Chris Huff wrote:
>
> Hmm, I think I will just stick to the isosurfaces. :-)
Must be a way to fake it with a csg if you ask me ;^ }
--
Ken Tyler
mailto://tylereng@pacbell.net
http://home.pacbell.net/tylereng/links.htm
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
It's nice to know someone actually understands it enough to work with
the math. All I've ever done is put some numbers in to these sort of
primitives. Got a hat shape I wanted that way though ;) pure luck and
then a little tweaking.
Nieminen Mika wrote:
>
> The formula of an elliptical cylinder along the z-axis is the following:
>
> x^2/r1^2 + y^2/r2^2 = 1
>
> where 'r1' and 'r2' are the radiuses of the ellipse.
> What we want is this kind of cylinder which changes linearly from z=0 to
> z=1 so that in z=0 the ellipse has radiuses 'a' and 'b' and in z=1 radiuses
> 'c' and 'd'.
> This means that when z=0, r1=a and r2=b. Then r1 and r2 should linearly
> change so that when z=1, r1=c and r2=d.
> This can be expressed this way:
>
> r1 = a*(1-z)+c*z
> r2 = b*(1-z)+d*z
>
> Substituting in the above formula we get:
>
> x^2/(a*(1-z)+c*z)^2 + y^2/(b*(1-z)+d*z)^2 = 1
>
> That's it. Now we have to reduce that to polynomial form so that we can
> write the quartic. This is a quite laborious job. I will not type the
> polynom here because it's so long, but it begins this way:
>
> b^2*x^2 + 2*(b*d-b^2)*x^2*z + (b^2-2*b*d+d^2)*x^2*z^2 + ... and so on
>
> Now, to write the polynomial, we look at the table in the page 212 of the
> povray manual (the "Poly, Cubic and Quartic"-section). We place all the
> terms of the polynomial in the right places in the vector. The result is:
>
> quartic
> { <0, 0, 0, 0, 0, 0, 0, b*b-2*b*d+d*d, 2*(b*d-b*b), b*b,
> 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
> 0, 0, 0, a*a-2*a*c+c*c, 2*(a*c-a*a), a*a, 0, 0, 0, 0,
> -(a*a-2*a*c+c*c)*(b*b-2*b*d+d*d),
> -(2*((b*d-b*b)*(a*a-2*a*c+c*c)+(a*c-a*a)*(b*b-2*b*d+d*d))),
> -(b*b*(a*a-2*a*c+c*c)+4*(a*c-a*a)*(b*d-b*b)+a*a*(b*b-2*b*d+d*d)),
> -(2*(b*b*(a*c-a*a)+a*a*(b*d-b*b))), -a*a*b*b>
> }
>
> Now we only have to cut the unwanted parts out (ie. everything that is
> at z<0 and z>1) and bound with a proper object for speedup.
>
> --
> main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
> ):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/
--
omniVERSE: beyond the universe
http://members.aol.com/inversez/homepage.htm
mailto://inversez@aol.com?Subject=PoV-News
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Ken wrote in message <37A078B1.E8D53C7C@pacbell.net>...
>
>
>Chris Huff wrote:
>>
>> Hmm, I think I will just stick to the isosurfaces. :-)
>
>Must be a way to fake it with a csg if you ask me ;^ }
Yes, by using the integral method -- use an infinite number of
infinitesmally thin elliptical cylinders with infinitesmal differences
between adjoining cylinders.
Mark
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Chris Huff <Chr### [at] compuserve com> wrote:
: Hmm, I think I will just stick to the isosurfaces. :-)
Are isosurfaces as fast as quartics?
--
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
I don't know, that sounds like it would take a while to parse, and would
take an awful lot of memory...
;-)
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
I don't know, they may be faster with simple functions, but you can make
extremely complex functions. Also depends on if you are using built in
functions or parsing functions, and what method you are using to
calculate(there are 2, one requires the maximum gradient of the
function.)
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Chris Huff wrote in message <37A19164.FC7F7672@compuserve.com>...
>I don't know, that sounds like it would take a while to parse, and would
>take an awful lot of memory...
>;-)
True :-)
Mark
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
That is a great solution... I've jsut been trying to remember how to take all
those formulas from algebra and turn them into poly and cubic statements.... I
thought it was based on the standard forms of the equaitons, but that didn't
seem to work. I'll have to look into that again
Joshua
eng### [at] spiritone com
Nieminen Mika wrote:
> The formula of an elliptical cylinder along the z-axis is the following:
>
> x^2/r1^2 + y^2/r2^2 = 1
>
> where 'r1' and 'r2' are the radiuses of the ellipse.
> What we want is this kind of cylinder which changes linearly from z=0 to
> z=1 so that in z=0 the ellipse has radiuses 'a' and 'b' and in z=1 radiuses
> 'c' and 'd'.
> This means that when z=0, r1=a and r2=b. Then r1 and r2 should linearly
> change so that when z=1, r1=c and r2=d.
> This can be expressed this way:
>
> r1 = a*(1-z)+c*z
> r2 = b*(1-z)+d*z
>
> Substituting in the above formula we get:
>
> x^2/(a*(1-z)+c*z)^2 + y^2/(b*(1-z)+d*z)^2 = 1
>
> That's it. Now we have to reduce that to polynomial form so that we can
> write the quartic. This is a quite laborious job. I will not type the
> polynom here because it's so long, but it begins this way:
>
> b^2*x^2 + 2*(b*d-b^2)*x^2*z + (b^2-2*b*d+d^2)*x^2*z^2 + ... and so on
>
> Now, to write the polynomial, we look at the table in the page 212 of the
> povray manual (the "Poly, Cubic and Quartic"-section). We place all the
> terms of the polynomial in the right places in the vector. The result is:
>
> quartic
> { <0, 0, 0, 0, 0, 0, 0, b*b-2*b*d+d*d, 2*(b*d-b*b), b*b,
> 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
> 0, 0, 0, a*a-2*a*c+c*c, 2*(a*c-a*a), a*a, 0, 0, 0, 0,
> -(a*a-2*a*c+c*c)*(b*b-2*b*d+d*d),
> -(2*((b*d-b*b)*(a*a-2*a*c+c*c)+(a*c-a*a)*(b*b-2*b*d+d*d))),
> -(b*b*(a*a-2*a*c+c*c)+4*(a*c-a*a)*(b*d-b*b)+a*a*(b*b-2*b*d+d*d)),
> -(2*(b*b*(a*c-a*a)+a*a*(b*d-b*b))), -a*a*b*b>
> }
>
> Now we only have to cut the unwanted parts out (ie. everything that is
> at z<0 and z>1) and bound with a proper object for speedup.
>
> --
> main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
> ):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
In article <37A02A80.FC2CCB77@panama.phoenix.net>, TonyB
<ben### [at] panama phoenix net> wrote:
> One thing I've noticed is that these 'quartics' can do some of
> the stuff that an isosurface can do. Am I correct in assuming this?
Quartics are polynomials with x, y and z as variables. When the
coordinates of a given point are plugged in the polynomial, the
polynomial evaluates to some numerical value.
If the value is zero, the point is on the surface of the object
represented by the polynomial. If the value is less than zero, the point
is inside the object. If the value is greater than zero, the point is
outside the object.
Thus the surface of the object consists of all the points in space with
which the polynomial evaluates to zero.
--
Henri Sivonen
hen### [at] clinet fi
http://www.clinet.fi/~henris/
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |