POV-Ray : Newsgroups : povray.general : Cubic Spline Question Server Time
4 Nov 2024 21:26:43 EST (-0500)
  Cubic Spline Question (Message 1 to 7 of 7)  
From: Mike Metheny
Subject: Cubic Spline Question
Date: 19 Jan 1999 14:15:19
Message: <36a4d9c7.0@news.povray.org>
Hey all; got a small problem with some spline code.  Here it is.

//begin file
#include "colors.inc"

camera{location <5,30,-60>
       look_at<0,0,0>
      }


light_source{<1000,1000,-1000> White}

 background{Gray50}


prism {
    conic_sweep
    linear_spline
    .5, // sweep the following shape from here ...
    1, // ... up through here
    9, // the number of points making up the shape ...
<0,1.5>,<1.5,0>,<31,0>,<32.5,1.5>,<32.5,15>,<31,16.5>,<1.5,16.5>,<0,15>,<0,1
.5>
translate<-16.25,0,-8.25>
rotate <180, 0, 0>
    translate <0, 1, 0>
    scale <1,6,1>
pigment{Green}}

//end file

Now I tried this without the first translate statement, and it was not
symmetrical, it seemed to extrude the spline strangely; so I thought my
points needed to center around the origin, which is what the first translate
should do; but I noticed no change.  Also; is there a way that I can specify
the angle the spline extrudes at?  And this question is mainly for Ken:
1)how do you export something from AutoCad to a format POV can use, and when
you do it is mesh based correct?  2)can you still do CSG and transparent
textures and all that with such objects?

Thanks guys.



Mike Metheny
lon### [at] vtedu
http://loneshepherd.ml.org/

"When one's words are no better than silence, one should keep silent."


Post a reply to this message

From: Ken
Subject: Re: Cubic Spline Question
Date: 19 Jan 1999 14:28:22
Message: <36A4DC4B.2E8D7293@pacbell.net>
Mike Metheny wrote:
  And this question is mainly for Ken:
> 1)how do you export something from AutoCad to a format POV can use, and when
> you do it is mesh based correct?  2)can you still do CSG and transparent
> textures and all that with such objects?
> 
> Thanks guys.
> 
> Mike Metheny

You can export either .DXF or .3DS. 3DS will all you to keep
your color information and then use a 3d conversion program
like CrossRoads3D or 3DWin to convert to pov mesh. I don't
believe you can use csg on meshes - you will get a message
saying "cannot use cgs with patch objecs" or something like that.
Yes you can use any pigment/texture/normal type with meshes.

http://www.europa.com/~keithr/crossroads/

http://ourworld.compuserve.com/homepages/thbaier/tools.htm

-- 
Ken Tyler

tyl### [at] pacbellnet


Post a reply to this message

From: Ken
Subject: Re: Cubic Spline Question
Date: 19 Jan 1999 21:09:05
Message: <36A53A31.926EBAF9@pacbell.net>
Mike Metheny wrote:
> 
> Hey all; got a small problem with some spline code.  Here it is.

What kind of shape were you looking for here ?


-- 
Ken Tyler

tyl### [at] pacbellnet


Post a reply to this message

From: Mike Metheny
Subject: Re: Cubic Spline Question
Date: 19 Jan 1999 21:39:50
Message: <36a541f6.0@news.povray.org>
<<What kind of shape were you looking for here ?>>

Well eventually it's gonna be an emerald.



Mike Metheny
lon### [at] vtedu
http://loneshepherd.ml.org/

"When one's words are no better than silence, one should keep silent."


Post a reply to this message

From: Ken
Subject: Re: Cubic Spline Question
Date: 19 Jan 1999 21:50:08
Message: <36A543CE.E42EEA38@pacbell.net>
Mike Metheny wrote:
> 
> <<What kind of shape were you looking for here ?>>
> 
> Well eventually it's gonna be an emerald.
> 
> Mike Metheny
> lon### [at] vtedu
> http://loneshepherd.ml.org/
> 
> "When one's words are no better than silence, one should keep silent."

There are much easier ways of going about making a complex
multifaceted object than with a prism. The first would be
with my diamonds.inc files. One is in macro form and the other
is a standard include file. The macro is in the macrostation
at http://twysted.net and the inc file is in the pov objects
collection at the same site. The second alternative is to use
the brilliant gem stone cuts posted recently in the one of the
scene files groups.

I'm not altogether sure you will ever be succesfull unless
its a very simple like four sided two bevel stone. It all
depends on what the shape is. You might also be better off
trying a lathe instead of a prism. Again it depends on the
desired shape. An intersection of planes is also an easier
approach than the one you have under taken and will in most
cases render faster than the rest listed.



-- 
Ken Tyler

tyl### [at] pacbellnet


Post a reply to this message

From: Mike Metheny
Subject: Re: Cubic Spline Question
Date: 19 Jan 1999 22:19:26
Message: <36a54b3e.0@news.povray.org>
<<There are much easier ways of going about making a complex
multifaceted object than with a prism. The first would be
with my diamonds.inc files. One is in macro form and the other
is a standard include file. The macro is in the macrostation
at http://twysted.net and the inc file is in the pov objects
collection at the same site. The second alternative is to use
the brilliant gem stone cuts posted recently in the one of the
scene files groups.>>

Well, an emerald cut is relatively simple.  I was trying to do that
intersection of planes thing but i couldn't even make a box.  I fooled
around a lot w/the planes and it was definately very screwy.  But like I say
I don't know what I'm doing.  A lathe I don't think would work; as it's all
sharp cuts and stuff.  Do you know why the prism object sweeps funny like
that rather than symmetric?



Mike Metheny
lon### [at] vtedu
http://loneshepherd.ml.org/

"When one's words are no better than silence, one should keep silent."


Post a reply to this message

From: Ken
Subject: Re: Cubic Spline Question
Date: 19 Jan 1999 23:44:05
Message: <36A55E83.AAD03568@pacbell.net>
Mike Metheny wrote:
> 
> Well, an emerald cut is relatively simple.  I was trying to do that
> intersection of planes thing but i couldn't even make a box.  I fooled
> around a lot w/the planes and it was definately very screwy.  But like I say
> I don't know what I'm doing.  A lathe I don't think would work; as it's all
> sharp cuts and stuff.  Do you know why the prism object sweeps funny like
> that rather than symmetric?
> 
> Mike Metheny
> lon### [at] vtedu
> http://loneshepherd.ml.org/
> 
> "When one's words are no better than silence, one should keep silent."

I have only touched on them in a general way. I played with your
code a bit but had no idea what the shape was supposed to be so
stopped.

Some excellen examples of using planes to create multi-sided
objects lie in the shapes.inc files. Shapes.old, shapes.inc,
and shapes2.inc. Everything from 4 sided to 20 sided shapes.
It's a good learning exersize. So are the brilliant cut diamonds
I referred you to in the scenes files groups which are constructed
using planes.


-- 
Ken Tyler

tyl### [at] pacbellnet


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.