Mouse selection using vertex information

Started by ErDetEnAnd?, May 19, 2008, 06:04:56 PM

Previous topic - Next topic

ErDetEnAnd?

Hello.

How do I access the transformed vertex information? I understand a IVertexController implementation operates in object space, but could it somehow work in the world? The PolygonManager delivers the transformed vertex, but it assumes that one is operating on polygons. I wouldn't expect the PolygonManager is the obviously choise for this kind of job - the current approach would then give 3x CPU overhead (for triangles).

By custom selection the transformed mesh should be directly accessible, but I can't figure out how...

Thanks in advance!

EgonOlsen

You can get the current world transformation from an object and use that in the vertex controller to calculate the vertex in world space (vertex.matMal(obj.getWorldTransformation())).

ErDetEnAnd?

Thank you for your fast reply - that's excellent.