RenderPrimitiveList

References
obsoleteUse RenderPrimitives

Finalizer

~RenderPrimitiveList

#
~RenderPrimitiveList()

Properties

Count

#Since v5.7 Obsolete v8.0
public int Count { get; }
Number of meshes in this list

RhinoObject

#Since v5.7 Obsolete v8.0
public RhinoObject RhinoObject { get; }
The Rhino object associated with this list

UseObjectsMappingChannels

#Since v5.7 Obsolete v8.0
public bool UseObjectsMappingChannels { get; set; }
Returns true if the texture mapping will be taken from the Rhino object otherwise; the texture mapping will use the texture coordinates on the mesh only.

Methods

Add

#Since v5.7 Obsolete v8.0
public void Add(Box box, RenderMaterial material)
Add primitive box and material.
box (Box)Box to add.
material (RenderMaterial)Material to add, may be null if not needed.

Add

#Since v5.7 Obsolete v8.0
public void Add(Cone cone, Plane truncation, RenderMaterial material)
Add primitive cone and material.
cone (Cone)Cone to add.
truncation (Plane)The plane used to cut the cone (the non-apex end is kept). Should be equal to cone.plane if not truncated.
material (RenderMaterial)Material to add, may be null if not needed.

Add

#Since v7.5 Obsolete v8.0
public void Add(IEnumerable<Mesh> meshes, RenderMaterial material)
meshes (IEnumerable<Mesh>)
material (RenderMaterial)

Add

#Since v6.12 Obsolete v8.0
public void Add(Mesh mesh, RenderMaterial material, Transform t)
Add mesh and material.
mesh (Mesh)Mesh to add.
material (RenderMaterial)Transformation of this mesh. Material to add, may be null if not needed.
t (Transform)

Add

#Since v5.7 Obsolete v8.0
public void Add(Mesh mesh, RenderMaterial material)
Add mesh and material.
mesh (Mesh)Mesh to add.
material (RenderMaterial)Material to add, may be null if not needed.

Add

#Since v5.7 Obsolete v8.0
public void Add(PlaneSurface plane, RenderMaterial material)
Add primitive plane and material.
plane (PlaneSurface)Plane to add.
material (RenderMaterial)Material to add, may be null if not needed.

Add

#Since v5.7 Obsolete v8.0
public void Add(Sphere sphere, RenderMaterial material)
Add primitive sphere and material.
sphere (Sphere)Sphere to add.
material (RenderMaterial)Material to add, may be null if not needed.

AutoDeleteMaterialsOn

#Since v6.0 Obsolete v8.0
public bool AutoDeleteMaterialsOn()

AutoDeleteMeshesOn

#Since v6.0 Obsolete v8.0
public bool AutoDeleteMeshesOn()

Clear

#Since v5.7 Obsolete v8.0
public void Clear()
Remove all primitives from this list

ConvertMeshesToTriangles

#Since v5.7 Obsolete v8.0
public void ConvertMeshesToTriangles()
Convert mesh quad faces to triangle faces.

Dispose

#Since v5.7 Obsolete v8.0
public void Dispose()

GetInstanceTransform

#Since v6.0 Obsolete v8.0
public Transform GetInstanceTransform(int index)
index (int)

Material

#Since v5.7 Obsolete v8.0
public RenderMaterial Material(int index)
Call this method to get the render material associated with the mesh at the specified index. Will return null if there is no material associated with the requested mesh.
index (int)The zero based index of the item in the list. Valid values are greater than or equal to 0 and less than Count.
If there is a render material associated at the requested index then the material is returned otherwise null is returned.

Mesh

#Since v5.7 Obsolete v8.0
public Mesh Mesh(int index)
Get the mesh for the primitive at the specified index. If the item at this index is a primitive type other than a mesh then it mesh representation is returned.
index (int)The zero based index of the item in the list. Valid values are greater than or equal to 0 and less than Count.
Returns the mesh for the primitive at the specified index. If the item at this index is a primitive type other than a mesh then it mesh representation is returned.

MeshInstance

#Since v6.12 Obsolete v8.0
public Mesh MeshInstance(int index, out Transform instance_transform)
Get the mesh for the primitive at the specified index. If the item at this index is a primitive type other than a mesh then it mesh representation is returned.
index (int)The zero based index of the item in the list. Valid values are greater than or equal to 0 and less than Count.
instance_transform (out Transform)Receives the transformation of this mesh.
Returns the mesh for the primitive at the specified index. If the item at this index is a primitive type other than a mesh then it mesh representation is returned.

PrimitiveType

#Since v5.7 Obsolete v8.0
public RenderPrimitiveType PrimitiveType(int index)
Type of primitive object at this index.
index (int)The zero based index of the item in the list. Valid values are greater than or equal to 0 and less than Count.
Primitive type of the item at this index.

SetInstanceTransform

#Since v6.0 Obsolete v8.0
public void SetInstanceTransform(int index, Transform xform)
index (int)
xform (Transform)

ToMaterialArray

#Since v5.7 Obsolete v8.0
public RenderMaterial[] ToMaterialArray()
Call this method to see if there are any RenderMaterials associated with the meshes. Each primitive can optionally have a RenderMaterial associated with it, if the RenderMaterial is null then check for a RhinoObject.RenderMaterial.
Return an array that of the same size as the ToMeshArray() containing the RenderMaterial associated with the mesh, may contain null entries if there is no RenderMaterial associated with the custom mesh.

ToMeshArray

#Since v5.7 Obsolete v8.0
public Mesh[] ToMeshArray()
Call this method to get a array of meshes, all primitives will get meshed and the meshes will get included in the returned array.
Return an array of meshes from this list, this will convert all primitives to meshes.

TryGetBox

#Since v5.7 Obsolete v8.0
public bool TryGetBox(int index, out Box box)
Call this method to get a box at the specified index.
index (int)The zero based index of the item in the list. Valid values are greater than or equal to 0 and less than Count.
box (out Box)Will contain the box at the requested index if the index is in range and the primitive at the requested index is a box.
Return true if the index is in range and the primitive at the requested index is a box otherwise returns false.

TryGetCone

#Since v5.7 Obsolete v8.0
public bool TryGetCone(int index, out Cone cone, out Plane truncation)
Call this method to get a box at the specified index.
index (int)The zero based index of the item in the list. Valid values are greater than or equal to 0 and less than Count.
cone (out Cone)Will contain the cone at the requested index if the index is in range and the primitive at the requested index is a box.
truncation (out Plane)
Return true if the index is in range and the primitive at the requested index is a box otherwise returns false.

TryGetPlane

#Since v5.7 Obsolete v8.0
public bool TryGetPlane(int index, out PlaneSurface plane)
Call this method to get a box at the specified index.
index (int)The zero based index of the item in the list. Valid values are greater than or equal to 0 and less than Count.
plane (out PlaneSurface)Will contain the plane at the requested index if the index is in range and the primitive at the requested index is a plane.
Return true if the index is in range and the primitive at the requested index is a plane otherwise returns false.

TryGetSphere

#Since v5.7 Obsolete v8.0
public bool TryGetSphere(int index, out Sphere sphere)
Call this method to get a box at the specified index.
index (int)The zero based index of the item in the list. Valid values are greater than or equal to 0 and less than Count.
sphere (out Sphere)Will contain the sphere at the requested index if the index is in range and the primitive at the requested index is a box.
Return true if the index is in range and the primitive at the requested index is a box otherwise returns false.