konrad_ha wrote:
AFAIK there's plenty of integer-based calculating going on in 3D-engines as well. What about physics, softbodies, particles, occlusion etc.? All done in ultra-precise floating-point-math? I didn't think so.
hum... if you know so much about blender and rendering, why dont sign up to the developer team?
i have to confess, i am no developer myself, BUT i had a close look at the code for my intel compiler based build of blender. i ran several profiling on modules and analysed the results.
for further information read these threads:
http://www.blender.org/modules.php?op=m ... pic&t=3778
http://www.blender.org/modules.php?op=m ... pic&t=4310
ANY important subroutine in blender which is used in rendering process is using floating point operations or more specific single-precision floating point untis or just "floats" in programmer slang. (btw, ultra-precise floating-point-math is nonsense)
you metioned several example which you think are based on integer arithmetic....
first of all "physics", for which i wont even need the blender code.
just a question: what grade did/do you have at school? i guess a very bad one, if you think that physics can be managed with integers.
physics is one of the mayor areas where you actually need floating point math.
*starting-up-notebook*
now have a look at your example in the code:
i am searching for "occlusion" and "ray.c" shows up. searching for "occlusion" again and guess what i first see? vectors defined as floats within function ray_ao(...)
next... searching in "rendercore.c" for "occlusion". function static void ambient_occlusion(...) and again floats everywhere.
perhaps you meant z-buffer and not occlusion. but since z-buffer offset in blender is again using a floating point unit this would also be wrong.
ok next one... particles:
searching in "particle.c"... again floats everywhere...
so exactly where would 64bit integer be relevant here?
(particle position, life time, offsets, vectors, ...)
just some examples where you need integers:
1.cryptography (already mentioned)
2.string comparison
3.control structures (loops, logic)
4.address arithmentic
5.data arithmetic
6.bit masks/bit rotations
anyway.. 64bit is only an advantage if you really need the values space of 2^64 or you manage to do some 32bit based operations parallel which can often only be achieved by hand and must of course be supported by the instruction set. thus 32bit are sufficient everywhere.
and before i gonna buy a 64 bit processor, i take a good intel processor with intel compiler optimized software for it.
konrad_ha wrote:
sorry, i am right you are wrong.

hum... i am currently the best in my computer science semester (#4).
i wrote my own bit integer arithmetic and i am programming assembler for 3 years now. i know very well what i am talking about.
and one of the fastest blender builds out there carries my name.
now it's your turn to tell me where you got your insights from.