POV-Ray : Newsgroups : povray.newusers : Translate include files? Server Time
30 Jul 2024 04:22:10 EDT (-0400)
  Translate include files? (Message 1 to 4 of 4)  
From: PaulB
Subject: Translate include files?
Date: 8 Nov 2004 04:35:01
Message: <web.418f3d0bf0a0efb8a1ddd0d50@news.povray.org>
I have an include file in the wrong place on the x direction.
Rather then change every single x in the file, can I translate the include
file in the main scene?
TIA.


Post a reply to this message

From: Warp
Subject: Re: Translate include files?
Date: 8 Nov 2004 04:48:50
Message: <418f4102@news.povray.org>
PaulB <jet### [at] yahoocouk> wrote:
> I have an include file in the wrong place on the x direction.
> Rather then change every single x in the file, can I translate the include
> file in the main scene?

  I think you are using the wrong terminology. An "include file" has no
location, orientation or anything. An include file is just a file like
any other file which you can include into your main scene file.
  You are probably talking about an *object* inside that include file,
but without knowing how that object has been declared it's difficult
to give a definite answer.

-- 
plane{-x+y,-1pigment{bozo color_map{[0rgb x][1rgb x+y]}turbulence 1}}
sphere{0,2pigment{rgbt 1}interior{media{emission 1density{spherical
density_map{[0rgb 0][.5rgb<1,.5>][1rgb 1]}turbulence.9}}}scale
<1,1,3>hollow}text{ttf"timrom""Warp".1,0translate<-1,-.1,2>}//  - Warp -


Post a reply to this message

From: PaulB
Subject: Re: Translate include files?
Date: 8 Nov 2004 05:00:01
Message: <web.418f42de621770a6a1ddd0d50@news.povray.org>
You're right.
The include file is objects/differences/etc. In this case the centre spindle
bit of a CD case (the bit you press). But stupidly I got the x value wrong
and it's off centre when the whole CD (base and lid) is rendered.
At the end of my cd.pov, is the line...

#include "cd3.pov"

I'd rather not edit cd3.pov and change every x value. (But it looks like I
will)


Post a reply to this message

From: Slime
Subject: Re: Translate include files?
Date: 8 Nov 2004 09:11:10
Message: <418f7e7e$1@news.povray.org>
> #include "cd3.pov"
>
> I'd rather not edit cd3.pov and change every x value. (But it looks like I
> will)

This will probably work:

union {
#include "cd3.pov"
translate x*whatever
}

Or you could just put the union {} block inside cd3.pov to be cleaner.

 - Slime
 [ http://www.slimeland.com/ ]


Post a reply to this message

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