OGLplus (0.52.0) a C++ wrapper for OpenGL

oglplus::shapes::Grid Class Reference

Class providing vertex attributes and instructions for rendering of a grid. More...

#include </home/chochlik/devel/oglplus/include/oglplus/shapes/grid.hpp>

Inherits oglplus::shapes::DrawingInstructionWriter, and oglplus::shapes::DrawMode.

Public Types

typedef VertexAttribsInfo< GridVertexAttribs
 Vertex attribute information for this shape builder. More...
 
typedef std::vector< GLuint > IndexArray
 The type of index container returned by Indices()
 

Public Member Functions

 Grid (void)
 Creates a default grid.
 
 Grid (const Vec3f u, const Vec3f v)
 Creates a grid with going through origin specified by u and v.
 
 Grid (const Vec3f p, const Vec3f u, const Vec3f v, unsigned udiv, unsigned vdiv)
 Creates a grid with going through p specified by u and v.
 
FaceOrientation FaceWinding (void) const
 Returns the winding direction of faces (unused)
 
template<typename T >
GLuint Positions (std::vector< T > &dest) const
 Makes vertex coordinates and returns number of values per vertex.
 
template<typename T >
GLuint TexCoordinates (std::vector< T > &dest) const
 Makes texture-coorinates and returns number of values per vertex.
 
template<typename T >
void BoundingSphere (oglplus::Sphere< T > &bounding_sphere) const
 Queries the bounding sphere coordinates and dimensions.
 
IndexArray Indices (Default=Default()) const
 Returns element indices that are used with the drawing instructions.
 
DrawingInstructions Instructions (Default=Default()) const
 Returns the instructions for rendering.
 

Detailed Description

Class providing vertex attributes and instructions for rendering of a grid.

Member Typedef Documentation

typedef VertexAttribsInfo<Grid> oglplus::shapes::Grid::VertexAttribs

Vertex attribute information for this shape builder.

Grid provides build functions for the following named vertex attributes:

  • "Position" the vertex positions (Positions)
  • "TexCoord" the ST texture coordinates (TexCoordinates)

The documentation for this class was generated from the following file:
  • /home/chochlik/devel/oglplus/include/oglplus/shapes/grid.hpp

Copyright © 2010-2014 Matúš Chochlík, University of Žilina, Žilina, Slovakia.
<matus.chochlik -at- fri.uniza.sk>
<chochlik -at -gmail.com>
Documentation generated on Mon Sep 22 2014 by Doxygen (version 1.8.6).