Terminus
Public Member Functions | Protected Attributes | List of all members
terminus::IndexTriple Class Reference

The IndexTriple class is used as a temporary geometry data storage, while parsing .obj files in the resourcemanager class. More...

#include <indextriple.h>

Public Member Functions

 IndexTriple (std::string positionSpec, std::string textureSpec, std::string normalSpec)
 
 ~IndexTriple ()
 
int positionIndex () const
 
int textureIndex () const
 
int normalIndex () const
 
bool validTexture () const
 
bool validNormal () const
 
bool operator< (const IndexTriple &compareTriple) const
 Returns true, if one of the attributes position, texture, or normal of the comparedTriple is larger, than the triple it is compared to. More...
 
bool operator== (const IndexTriple &compareTriple) const
 Returns true, if the compared attributes position, texture and normal have the same value between the compared triples. More...
 

Protected Attributes

int m_positionIndex
 
int m_textureIndex
 
int m_normalIndex
 
bool m_validTexture
 
bool m_validNormal
 

Detailed Description

The IndexTriple class is used as a temporary geometry data storage, while parsing .obj files in the resourcemanager class.

The important relational operators " < " and " == " are implemented in order to decide, whether this specific vertex data has already been stored.

Constructor & Destructor Documentation

terminus::IndexTriple::IndexTriple ( std::string  positionSpec,
std::string  textureSpec,
std::string  normalSpec 
)
terminus::IndexTriple::~IndexTriple ( )

Member Function Documentation

int terminus::IndexTriple::normalIndex ( ) const
bool terminus::IndexTriple::operator< ( const IndexTriple compareTriple) const

Returns true, if one of the attributes position, texture, or normal of the comparedTriple is larger, than the triple it is compared to.

Parameters
compareTriple
bool terminus::IndexTriple::operator== ( const IndexTriple compareTriple) const

Returns true, if the compared attributes position, texture and normal have the same value between the compared triples.

Parameters
compareTriple
int terminus::IndexTriple::positionIndex ( ) const
int terminus::IndexTriple::textureIndex ( ) const
bool terminus::IndexTriple::validNormal ( ) const
bool terminus::IndexTriple::validTexture ( ) const

Member Data Documentation

int terminus::IndexTriple::m_normalIndex
protected
int terminus::IndexTriple::m_positionIndex
protected
int terminus::IndexTriple::m_textureIndex
protected
bool terminus::IndexTriple::m_validNormal
protected
bool terminus::IndexTriple::m_validTexture
protected

The documentation for this class was generated from the following files: