OpenGLContext.triangleutilities
index
p:\openglcontext\triangleutilities.py

Utility functions for processing triangle vertex arrays

 
Functions
            
basisVectors(vertices)
Calculate the basis vectors for the given triangle vertices
 
vertices -- x*3 array of vertex coordinates, with x a multiple of 3
 
returns two arrays of vectors, [second minus first, third minus second]
centers(vertices)
Calculate the center of each triangle for the given triangle vertices
 
vertices -- x*3 array of vertex coordinates, with x a multiple of 3
 
returns array of center vectors
normalPerFace(vertices)
Calculate the triangle normals for the given triangle vertices
 
vertices -- x*3 array of vertex coordinates, with x a multiple of 3
 
returns array of normal vectors

 
Data
             __file__ = r'p:\OpenGLContext\triangleutilities.pyc'
__name__ = 'OpenGLContext.triangleutilities'