|
![](/i/fill.gif) |
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/fill.gif) |