Triangles and Vertices

Blitz3D Forums/Blitz3D Programming/Triangles and Vertices

_PJ_(Posted 2011) [#1]
Not the best topic title, so sorry :)

I was wondering if there's an easy/specific (popular even?) metohod of identifying triangles which share vertices with a particular one, or perhaps, the triangles of which a particular vertex is 'part of' ?
So far, the only thing I have been able to come up with is to iterate through each triangle each and every time:



Is there a simpler, or quicker method?


Rroff(Posted 2011) [#2]
Short of pre-computing a lookup list at load (or design) time I don't know of any other approach other than what you've come up with - and you'd basically still have to do the same as what your doing it would just be faster on subsequent lookups.

Last edited 2011


_PJ_(Posted 2011) [#3]
Thanks, Rroff. A pre-compiled lookup sounds good, at least, storing the intial triangle verts, though for complicated meshes of thousands of verts, that's a fair chunk of data duplicated, but as you say, it doesn't seem like there's much option...