POV-Ray : Newsgroups : povray.general : SDL processing speed : Re: SDL processing speed Server Time
26 Apr 2024 10:42:04 EDT (-0400)
  Re: SDL processing speed  
From: Kenneth
Date: 21 Apr 2018 16:00:00
Message: <web.5adb9711af45eceba47873e10@news.povray.org>
Alain <kua### [at] videotronca> wrote:

>
> Parsing is strictly iterative and can only use a single thread.
>
> If you use any macro in a loop, it will get expanded and parsed each
> time it's used.
>
> If that macro is in an include file, that file will get opened and read
> each time the macro is invoked. EVERYTHING before the macro definition
> need to be read and skipped. Example : If you use any colour
> manipulation macro from colors.inc, they are located at the end, forcing
> the parser to read the whole include every time they are used...
> Cure : Copy any macro that is used in a loop into
> your main file. Remove any comment located within the macro, or move them
> before the macro definition.
>

That's a really good and concise explanation of what occurs. IMO, it should be
part of the POV-Ray documentation, at "1.7-- Speed Considerations."

And perhaps this as well: For using a particular function in "math.inc" (or some
other include file), copy that entity into your main scene file, rather than
#including the entire #math.inc" file. (It can get complicated of course, if the
particular entity uses *another* entity within it.)


Post a reply to this message

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