[Bf-python] Transfrom... why I bothered :)

cpbarton at iinet.net.au cpbarton at iinet.net.au
Sun Feb 6 03:01:23 CET 2005


Its all very well to say- Use map() or some such other function to speed up the loop
The problem is that at the moment VecMultiMat requires you to make a copy of the
Vert to a vector object and resize it to 4D so it can be operated on, if you
want to use map then the entire mesh must be copied into 4D vector objects, then
back to the verts.
This requires a compleate copy in memory and using 1/3 more space BEFORE its
operated on.

My method creates 3 floats in C, then operates on the entire mesh, no making
duplicate data.

Even if optimixed I dont think a python implimentation could come close to the
speed of C.

Transforming 3D data by a mesh isnt an obscure function, its done all the time
when exporting. I would say for most exporters.

- Cam





More information about the Bf-python mailing list