Support Forum       G3D Web Page     
Public Member Functions | Public Attributes | List of all members
G3D::MD2Model::Specification Class Reference

Public Member Functions

 Specification ()
 
 Specification (const String &trisFilename)
 Infers the rest of the specification from the path to (and including) the tris.md2 file. More...
 
 Specification (const Any &any)
 Example .any file format: More...
 

Public Attributes

String filename
 Main part .md2 filename. More...
 
shared_ptr< UniversalMaterialmaterial
 Cannot be nullptr. More...
 
bool negateNormals
 If true, negate the normal direction on this object when rendering. More...
 
float scale
 
String weaponFilename
 Optional second part .md2 filename, which is typically the weapon. More...
 
shared_ptr< UniversalMaterialweaponMaterial
 May be nullptr if weaponFilename is the empty string. More...
 

Constructor & Destructor Documentation

◆ Specification() [1/3]

G3D::MD2Model::Specification::Specification ( )

◆ Specification() [2/3]

G3D::MD2Model::Specification::Specification ( const String trisFilename)

Infers the rest of the specification from the path to (and including) the tris.md2 file.

◆ Specification() [3/3]

G3D::MD2Model::Specification::Specification ( const Any any)

Example .any file format:

MD2Model::Specification {
filename = "md2/bauul/tris.md2",
material = UniversalMaterial::Specification {
lambertian = "md2/bauul/ctf_b.pcx"
}
weaponFilename = "md2/bauul/weapon.md2",
weaponMaterial = "md2/bauul/weapon.pcx"
}

Member Data Documentation

◆ filename

String G3D::MD2Model::Specification::filename

Main part .md2 filename.

This typically ends in tris.md2.

◆ material

shared_ptr<UniversalMaterial> G3D::MD2Model::Specification::material

Cannot be nullptr.

◆ negateNormals

bool G3D::MD2Model::Specification::negateNormals

If true, negate the normal direction on this object when rendering.

Most models do not need this. An example of one that does is the "suw" model included with the G3D data pack.

◆ scale

float G3D::MD2Model::Specification::scale

◆ weaponFilename

String G3D::MD2Model::Specification::weaponFilename

Optional second part .md2 filename, which is typically the weapon.

◆ weaponMaterial

shared_ptr<UniversalMaterial> G3D::MD2Model::Specification::weaponMaterial

May be nullptr if weaponFilename is the empty string.


documentation generated on Wed Nov 24 2021 08:01:58 using doxygen 1.8.15