Urho.CustomGeometry Class

Custom geometry component.

See Also: CustomGeometry

Syntax

public class CustomGeometry : Drawable

Requirements

Namespace: Urho
Assembly: Urho (in Urho.dll)
Assembly Versions: 1.0.0.0

The members of Urho.CustomGeometry are listed below.

See Also: Drawable

Public Constructors

Constructs a new instance of Urho.CustomGeometry which is tied to the Application.CurrentContext.
Constructs a new instance of Urho.CustomGeometry, given a raw pointer to an unmanaged object
Constructs a new instance of Urho.CustomGeometry linked to a specific Context.

Protected Constructors

Empty constructor, chain to this constructor when you provide your own constructor that sets the handle field.

Public Properties

DynamicBoolean. Determines whether vertex buffer dynamic mode is enabled.
NumGeometriesUInt32. Return number of geometries. Or Set number of geometries.
[read-only]
override
NumOccluderTrianglesUInt32. Return number of occlusion geometry triangles.
[read-only]
override
TypeStringHash. Urho's type system type.
[read-only]
override
TypeNameString. Urho's low-level type name.
[read-only]
static
TypeNameStaticString. Urho's low-level type name, accessible as a static method.
[read-only]
static
TypeStaticStringHash. Urho's low-level type, accessible as a static method.

Public Methods

BeginGeometry(UInt32, PrimitiveType)
Begin defining a geometry. Clears existing vertices in that index.
Clear()
Clear all geometries.
Commit()
Update vertex buffer and calculate the bounding box. Call after finishing defining geometry.
DefineColor(Color)
Define a vertex color.
DefineGeometry(UInt32, PrimitiveType, UInt32, Boolean, Boolean, Boolean, Boolean)
Set the primitive type, number of vertices and elements in a geometry, after which the vertices can be edited with GetVertex(). An alternative to BeginGeometry() / DefineVertex().
DefineNormal(Vector3)
Define a vertex normal.
DefineTangent(Vector4)
Define a vertex tangent.
DefineTexCoord(Vector2)
Define a vertex UV coordinate.
DefineVertex(Vector3)
Define a vertex position. This begins a new vertex.
override
DrawOcclusion(OcclusionBuffer) : Boolean
Draw to occlusion buffer. Return true if did not run out of triangles.
override
GetLodGeometry(UInt32, UInt32) : Geometry
Return the geometry for a specific LOD level.
GetMaterial(UInt32) : Material
Return material by geometry index.
GetNumVertices(UInt32) : UInt32
Return number of vertices in a geometry.
GetVertex(UInt32, UInt32) : CustomGeometryVertex*
Return a vertex in a geometry for editing, or null if out of bounds. After the edits are finished, calling Commit() updates the vertex buffer.
static
RegisterObject(Context)
Register object factory. Drawable must be registered first.
SetMaterial(Material)
Set material on all geometries.
SetMaterial(UInt32, Material) : Boolean
Set material on one geometry. Return true if successful.