CanvasObject ObjectThe CanvasObject object represents a 3D Canvas Object.
Gets the unique identifier for the object. Syntax object.GetID() As Variant
Gets the name of the object. Syntax object.GetName() As Variant
Sets the name of the object. Syntax object.SetName(Name As Variant) Remarks An object must be made a child of a group using the AddObject method before it can be named.
Reduces the number of points in the object using Direct3D's mesh simplification function. Note that this will result in object being triangulated. Syntax object.Reduce(Level as Variant) Remarks Level is the percentage of points you would like to retain in the object. For example a level of 50 would retain 50% of the original points in the object.
Optimizes the object to remove unused points, duplicate points, and faces with two or fewer points. Syntax object.Optimize()
Gets the object type. Syntax object.GetType() As Variant Remarks 0 = 3D Canvas Object
Clears the contents of the object. Syntax object.Clear()
Adds a CanvasObject object to the object. Syntax object.AddObject(Object As Variant)
Transforms the object from model coordinates to world coordinates. Syntax object.Transform()
Transforms the object from world coordinates to model coordinates. Syntax object.InverseTransform()
Gets the object's bounding box. Syntax object.GetBoundingBox(MinX As Variant,
Writes a Script Operation Layer for the object. Syntax object.WriteScriptOperationLayer() Remarks After you make any change to an object you must use this method to notify 3D Canvas
that the change should be saved the next time 3D Canvas saves the document. This method does not need to be done after changes made while animating.
Creates a CanvasFace object and adds it to the object. Syntax object.CreateFace() As CanvasFace
Gets the number of CanvasFace objects in the object. Syntax object.GetFaceCount() As Variant
Gets the specified CanvasFace object. Syntax object.GetFace(Index As Variant) As CanvasFace
Deletes the specified CanvasFace from the object. Syntax object.DeleteFace(Index As Variant)
Gets the number of points in the object. Syntax object.GetPointCount() As Variant
Gets the specified point. Syntax object.GetPoint(Index As Variant,
Sets the specified point. Syntax object.SetPoint(Index As Variant,
Adds a point to the object and returns its index. If an identical point is found the index of the existing point is returned. Syntax object.AddOptimizedPoint(X As Variant,
AddOptimizedNormal Adds a normal to the object and returns its index. If an identical normal is found the index of the existing normal is returned. Syntax object.AddOptimizedNormal(X As Variant,
Gets the number of UVs in the object. Syntax object.GetUVCount() As Variant
Gets the specified UV. Syntax object.GetUV(Index As Variant,
Sets the specified UV. Syntax object.SetUV(Index As Variant,
Adds a uv to the object and returns its index. If an identical uv is found the index of the existing uv is returned. Syntax object.AddOptimizedUV(U As Variant,
GenerateNormals Generates normals for the object. Syntax object.GenerateNormals(CreaseAngle As Variant) Remarks The crease angle is in Radians. pi Radians = 180 degrees.
Gets the crease factor for the object. Syntax object.GetCreaseFactor() As Variant Remarks This is a value from 0 to 100. When 3D Canvas generates creasing it considers 100 to mean pi Radians (180 degrees).
Sets the crease factor for the object. Syntax object.SetCreaseFactor(CreaseFactor As Variant) Remarks This is a value from 0 to 100. When 3D Canvas generates creasing it considers 100 to mean pi Radians (180 degrees).
Gets the number of normals in the object. Syntax object.GetNormalCount() As Variant
Gets the specified normal. Syntax object.GetNormal(Index As Variant,
Sets the specified normal. Syntax object.SetNormal(Index As Variant,
Gets the number of bones that affect this object. Syntax object.GetBoneCount() As Variant
Gets the specified CanvasBone object. Syntax object.GetBone(Index As Variant) As CanvasBone
Gets the number of materials used by this object. Syntax object.GetMaterialCount() As Variant
Gets the specified CanvasMaterial object. Syntax object.GetMaterial(Index As Variant) As CanvasMaterial
Sets a material for the object. Syntax object.SetMaterial(Material As Variant) Remarks This material will be applied to each face that makes up the object.
Gets an index to the material that has been applied to a face. Syntax object.GetFaceMaterialIndex(FaceIndex As Variant) As Variant Remarks Use this in conjunction with GetMaterial to retrieve the specific material applied to a face.
GetParentGroup Gets the CanvasGroup that is the parent group of the object. Syntax object.GetParentGroup() As CanvasGroup
Gets the value of a custom field. Syntax object.GetCustomFieldValue(FieldID as Variant) As Variant Remarks The FieldID can be determined using GetObjectCustomFieldID of the CanvasApplication object.
Sets the value of a custom field. Syntax object.SetCustomFieldValue(FieldID as Variant, FieldValue As Variant) Remarks The FieldID can be determined using GetObjectCustomFieldID of the CanvasApplication object.
|