Polycode
Polycode::ScenePrimitive Class Reference

3D primitive mesh. More...

Inherits Polycode::SceneMesh.

Inherited by Polycode::SceneLabel.

List of all members.

Public Member Functions

 ScenePrimitive (int type, Number v1=1.0f, Number v2=1.0f, Number v3=1.0f, Number v4=0.0f, Number v5=0.0f)
 Create a primitive mesh of specified type and size.

Static Public Attributes

static const int TYPE_BOX = 0
 A cube.
static const int TYPE_PLANE = 1
 A horizontal plane.
static const int TYPE_SPHERE = 2
 A sphere.
static const int TYPE_CYLINDER = 3
 A cylinder.
static const int TYPE_CONE = 4
 A cone.
static const int TYPE_VPLANE = 5
 A vertical plane.
static const int TYPE_TORUS = 6
 A torus.
static const int TYPE_UNCAPPED_CYLINDER = 7
 A cylinder.

Detailed Description

3D primitive mesh.


Constructor & Destructor Documentation

ScenePrimitive::ScenePrimitive ( int  type,
Number  v1 = 1.0f,
Number  v2 = 1.0f,
Number  v3 = 1.0f,
Number  v4 = 0.0f,
Number  v5 = 0.0f 
)

Create a primitive mesh of specified type and size.

Parameters:
typeType of primitive to create. Current types are ScenePrimitive::TYPE_BOX, ScenePrimitive::TYPE_PLANE, ScenePrimitive::TYPE_VPLANE, ScenePrimitive::TYPE_SPHERE, ScenePrimitive::TYPE_CYLINDER, ScenePrimitive::TYPE_CONE and ScenePrimitive::TYPE_TORUS
v1See the constant primitive types for values for these parameters
v2See the constant primitive types for values for these parameters
v3See the constant primitive types for values for these parameters
v4See the constant primitive types for values for these parameters
v5See the constant primitive types for values for these parameters

Member Data Documentation

const int Polycode::ScenePrimitive::TYPE_BOX = 0 [static]

A cube.

v1 - X size v2 - Y size v3 - Z size

const int Polycode::ScenePrimitive::TYPE_CONE = 4 [static]

A cone.

v1 - Cone length. v2 - Cone raidus. v3 - Number of segments.

A cylinder.

v1 - Cylinder length v2 - Cylinder radius v3 - Number of segments.

const int Polycode::ScenePrimitive::TYPE_PLANE = 1 [static]

A horizontal plane.

v1 - X size v2 - Z size

const int Polycode::ScenePrimitive::TYPE_SPHERE = 2 [static]

A sphere.

v1 - Sphere radius v2 - Lat segments v3 - Long segments

const int Polycode::ScenePrimitive::TYPE_TORUS = 6 [static]

A torus.

v1 - Torus radius. v2 - Pipe radius. v3 - Number of ring segments. v4- Number of pipe segments.

A cylinder.

v1 - Cylinder length v2 - Cylinder radius v3 - Number of segments.

const int Polycode::ScenePrimitive::TYPE_VPLANE = 5 [static]

A vertical plane.

v1 - X size v2 - Y size