|
![](/i/fill.gif) |
In article <3A9550F9.80FAA811@gmx.de>, Christoph Hormann
<chr### [at] gmx de> wrote:
> The hardcoded version would probably be much faster so i think it's quite
> a good idea when it should be used for collision detection where it would
> be called quite often.
The patch I posted compiled and ran fine.
I tested the speed with a file that called the function or macro 64^3
(262144) times.
The macro version used 238 seconds, and the function version used 208
seconds, so the function version takes about 87% as long as the macro.
It seems macros don't have that much overhead...at least, the MegaPOV
macros, which have been optimized. However, in a collision detection
algorithm, which could easily use even more calls, this small
improvement would still be helpful.
--
Christopher James Huff
Personal: chr### [at] mac com, http://homepage.mac.com/chrishuff/
TAG: chr### [at] tag povray org, http://tag.povray.org/
<><
Post a reply to this message
|
![](/i/fill.gif) |