CUGL 3.0
Cornell University Game Library
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
cugl::scene3::GroupInfo Class Reference

#include <CUObjModel.h>

Public Member Functions

 GroupInfo ()
 

Public Attributes

bool touched
 
unsigned index
 
GLenum command
 
std::string object
 
std::string material
 
std::unordered_set< std::string > tags
 
std::vector< VertexInfovertices
 
std::vector< GLuint > indices
 
std::unordered_map< VertexInfo, GLuint, VertexHashervertCache
 

Detailed Description

This class represents the attributes of an OBJ render group.

OBJ models are broken up into multiple groups for rendering. A group corresponds to a single draw call to the graphics pipeline. Therefore, we need a new group whenever we have a new material. In addition, OBJ files can explicitly create new groups with the "g" or "s" command. We also create new groups with an "o" command, though that is not standard.

Constructor & Destructor Documentation

◆ GroupInfo()

cugl::scene3::GroupInfo::GroupInfo ( )
inline

Creates an unintialized GroupInfo with default values

Member Data Documentation

◆ command

GLenum cugl::scene3::GroupInfo::command

The drawing command for this group (GL_FALSE for undefined)

◆ index

unsigned cugl::scene3::GroupInfo::index

The smoothing index of for this render group (the OBJ s value)

◆ indices

std::vector<GLuint> cugl::scene3::GroupInfo::indices

The render group shape represented as indexed vertices

◆ material

std::string cugl::scene3::GroupInfo::material

The material name for this render group

◆ object

std::string cugl::scene3::GroupInfo::object

The object group (the OBJ o value)

◆ tags

std::unordered_set<std::string> cugl::scene3::GroupInfo::tags

The tags for this render group (the OBJ g values)

◆ touched

bool cugl::scene3::GroupInfo::touched

Whether this info has received any vertex information (for parsing)

◆ vertCache

std::unordered_map<VertexInfo,GLuint,VertexHasher> cugl::scene3::GroupInfo::vertCache

A vertex cache to eliminate redundancy

◆ vertices

std::vector<VertexInfo> cugl::scene3::GroupInfo::vertices

The vertices associated with this group


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