|
|
Hi,
I have scene in example
scene.pov
in some directory like dir/. Scene includes some local files, so
include "data.inc" inside dir/scene.pov refers to dir/data.inc
If I open scene.pov and render it - it works.
If I create a file render.pov and from it include dir/scene.pov - it doesnt
work, since #include in dir/scene.pov refers to data.inc not dir/data.inc
I can fix it by adding #declare root="dir/" inside render.pov, and then
change all #includes in files in dir/* to
#include concat( root , "something" );
But if there are several files inside dir/ and there have several includes,
in example - files exported using Polyray, it become annoying.
Is there some future to include file where file-name is relative to current
file, not to main .pov file? Or - how about adding some SetRoot() option,
it would be used like:
#declare oldRoot = getfileroot();
setfileroot("car10")
#include "main.pov" // includes car10/main.pov and other includes there are
// relative to car10/ so they work o.k.
setfileroot(oldRoot); // restore root
--
http://www.raf256.com/3d/
Rafal Maj 'Raf256', home page - http://www.raf256.com/me/
Computer Graphics
Post a reply to this message
|
|
|
|
I'm guessing you are not overlooking the obvious solution, Library_Path, as
used in the povray.ini file and instead want a way to do this from within a
scene file.
Only thing besides, I can think of, might be a Pre_Scene_Command to change
the working directory (of Windows). Unfortunately, while trying a test of
this before replying to you I couldn't use that idea, POV-Ray crashes. There
had been problems with that feature during beta testing which I thought had
been corrected but using it like in the documentation I'm not able to use
it. Tried with/without quotes.
Bob H.
Post a reply to this message
|
|