#ifndef VIRTUALTRIANGLE_H
#define VIRTUALTRIANGLE_H

#include <typedefs.h>

//  Brief:  A virtual triangle with local indexes to another data
//          structure. 
//
class virtualtriangle
{

public:

  // Local indexes to points.  Can have values of {0,1,2} only.
  uint v[3];

  // Constructor
  virtualtriangle();

  // Each of the triangles verticies refers to a local point.
  void set(uintc a, uintc b, uintc c);

  // {0,1,2} sets the triangles orientation.
  void set(uintc base);

  // Rotate the triangle clockwise.
  void clockwise();

  // Rotate the triangle anticlockwise.
  void anticlockwise();

  // Has v[] with {0,1,2} in any order.
  bool const validstate() const;
};



#endif



