POV-Ray : Newsgroups : povray.newusers : Spline Macro Server Time
31 Oct 2024 08:18:56 EDT (-0400)
  Spline Macro (Message 1 to 3 of 3)  
From: quoderatd
Subject: Spline Macro
Date: 15 Jul 2009 18:50:00
Message: <web.4a5e5c9e472605c67c859cee0@news.povray.org>
Hello,

I am trying to apply transformations to a spline macro object.

I used the macro file from the following link:

http://www.geocities.com/ccolefax/spline/index.html

////////////////////////////code/////////////////////////////////
#include "spline.mcr"

#declare ObjectSpline = create_spline (
   array[4] {<0, 0, 0>, <0, 2, 0>, <0, 3, -.25>, <0, 5, -.25>},
   create_hermite_spline + spline_sampling (4) +spline_rotate(180*y) +
spline_translate (.8*z)  )


#declare link_object = superellipsoid {<.3, .3>  rotate 90*y
   pigment {rgb <1, 0, 0>}
   //finish {reflection 0.4 specular 0.5 metallic}
   }

object{link_spline (ObjectSpline, spline_step_size (0.07) ) translate 1*x}

/////////////////////////////end of code //////////////////////////

This is basically a back support of a chair.

I wanted to have couple of them, so I tried translating the object, and

there seems to be conflict with the macro file...

How could I apply transformations on it?

Thanks


Post a reply to this message

From: Tim Attwood
Subject: Re: Spline Macro
Date: 16 Jul 2009 07:17:53
Message: <4a5f0c61$1@news.povray.org>
> Hello,
>
> I am trying to apply transformations to a spline macro object.
>
> I used the macro file from the following link:
>
> http://www.geocities.com/ccolefax/spline/index.html
>
> ////////////////////////////code/////////////////////////////////
> #include "spline.mcr"
>
> #declare ObjectSpline = create_spline (
>   array[4] {<0, 0, 0>, <0, 2, 0>, <0, 3, -.25>, <0, 5, -.25>},
>   create_hermite_spline + spline_sampling (4) +spline_rotate(180*y) +
> spline_translate (.8*z)  )
>
>
> #declare link_object = superellipsoid {<.3, .3>  rotate 90*y
>   pigment {rgb <1, 0, 0>}
>   //finish {reflection 0.4 specular 0.5 metallic}
>   }
>
> object{link_spline (ObjectSpline, spline_step_size (0.07) ) translate 1*x}
>
> /////////////////////////////end of code //////////////////////////
>
> This is basically a back support of a chair.
>
> I wanted to have couple of them, so I tried translating the object, and
>
> there seems to be conflict with the macro file...
>
> How could I apply transformations on it?

The link_spline macro places multiple link_objects, just
use a union instead of object...

union{link_spline (ObjectSpline, spline_step_size (0.07) ) translate 1*x}


Post a reply to this message

From: quoderatd
Subject: Re: Spline Macro
Date: 16 Jul 2009 11:05:00
Message: <web.4a5f418d24974b497c859cee0@news.povray.org>
lol you are so right...


Post a reply to this message

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