I understand.
But in my case, the mesh seems to be parsed again even if
I use #ifndef directive as you explained.
And it takes the same time for parsing.
I tested simple one as follows instead of putting the mesh.
#ifndef (done)
#warning "parsing started"
sphere {<0 0 0>, 1}
#declare done = 1;
#warning "parsing ended"
#end
It prints out "parsing started" and "parsing ended" in every frame.
I think these messages should not be printed from the second frame
if the variable "done" remains in the rendering of the second frame.
I am sure that I wrote "Persistent_Animation=yes" in the INI file.
What did I miss now?
Thanks for your help.
Pabs wrote:
>
> >Any idea? Please...
> With the persistence option in MegaPOV you must remember that the whole file
> is reparsed for each frame so you must use something like the following.
> This will ensure that once the mesh has been parsed once it will never be
> parsed again.
>
> camera{...}
> light_source{...}
>
> #ifndef (mymeshparsed)
> mesh{
> ...
> ..
> .
> label TheMesh
> }
> #declare mymeshparsed = 1;//doesn't matter what the value is but you can't
> do just #declare mymeshparsed
> #end
>
> Hope I've been of some help
> --
> Bye
> Pabs
Post a reply to this message
|