Class SceneInterface
Inherited Members
Namespace: UnityEngine.Pixyz.Scene
Syntax
public class SceneInterface : Interface
Methods
AddAnimation(uint)
Add an animation in Animation library
Declaration
[HandleProcessCorruptedStateExceptions]
public void AddAnimation(uint animation)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | Animation to add |
AddAnimationAddedCallback(AnimationAddedDelegate, IntPtr)
Declaration
public uint AddAnimationAddedCallback(SceneInterface.AnimationAddedDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.AnimationAddedDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddAnimationChangedCallback(AnimationChangedDelegate, IntPtr)
Declaration
public uint AddAnimationChangedCallback(SceneInterface.AnimationChangedDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.AnimationChangedDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddAnimationClearedCallback(AnimationClearedDelegate, IntPtr)
Declaration
public uint AddAnimationClearedCallback(SceneInterface.AnimationClearedDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.AnimationClearedDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddAnimationRemovedCallback(AnimationRemovedDelegate, IntPtr)
Declaration
public uint AddAnimationRemovedCallback(SceneInterface.AnimationRemovedDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.AnimationRemovedDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddAnnotationGroup(uint, string)
add a Annotation Group to the pmi component
Declaration
[HandleProcessCorruptedStateExceptions]
public uint AddAnnotationGroup(uint component, string name)
Parameters
Type | Name | Description |
---|---|---|
uint | component | Component to add the Annotation Group |
string | name | Name of the annotation group |
Returns
Type | Description |
---|---|
uint |
AddComponent(uint, ComponentType)
Add a component to an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint AddComponent(uint occurrence, ComponentType componentType)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence to add the new component |
ComponentType | componentType | Type of the component |
Returns
Type | Description |
---|---|
uint |
AddComponentChangedCallback(ComponentChangedDelegate, IntPtr)
Declaration
public uint AddComponentChangedCallback(SceneInterface.ComponentChangedDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.ComponentChangedDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddComponents(OccurrenceList, ComponentType)
Add a components to each occurrence in the array
Declaration
[HandleProcessCorruptedStateExceptions]
public ComponentList AddComponents(OccurrenceList occurrences, ComponentType componentType)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Occurrences that need the component to be added |
ComponentType | componentType | Type of the component |
Returns
Type | Description |
---|---|
ComponentList |
AddFilterToLibrary(string, string)
Add a filter to the filters library
Declaration
[HandleProcessCorruptedStateExceptions]
public uint AddFilterToLibrary(string name, string expr)
Parameters
Type | Name | Description |
---|---|---|
string | name | Name of the filter |
string | expr | The filter expression |
Returns
Type | Description |
---|---|
uint |
AddInParentInstances(uint)
Add an instance of prototype's child as child in current occurrence recursively
Declaration
[HandleProcessCorruptedStateExceptions]
public void AddInParentInstances(uint root)
Parameters
Type | Name | Description |
---|---|---|
uint | root | The occurrence to test. |
AddKeyframe(uint, ulong, double)
Adds a keyframe in the curve
Declaration
[HandleProcessCorruptedStateExceptions]
public uint AddKeyframe(uint channel, ulong time, double value)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel one wants to add a keyframe in |
ulong | time | The time |
double | value | The value |
Returns
Type | Description |
---|---|
uint |
AddKeyframeFromCurrentPosition(uint, ulong)
Adds keyframes in a given AnimChannel based on current position
Declaration
[HandleProcessCorruptedStateExceptions]
public void AddKeyframeFromCurrentPosition(uint channel, ulong time)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel one wants to add a keyframe in |
ulong | time | The time |
AddLightComponent(uint, LightType, Color, double, double)
Add a light component to an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint AddLightComponent(uint occurrence, LightType lightType, Color color, double power = 1, double cutOff = 20)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence to add the new component |
LightType | lightType | The type of the light |
Color | color | Color of the light |
double | power | The power of the light |
double | cutOff | The cutoff angle of the light |
Returns
Type | Description |
---|---|
uint |
AddMeshToAnnotation(uint, uint, uint)
add a mesh and its material to a annotation
Declaration
[HandleProcessCorruptedStateExceptions]
public void AddMeshToAnnotation(uint annotation, uint material, uint staticmesh)
Parameters
Type | Name | Description |
---|---|---|
uint | annotation | |
uint | material | |
uint | staticmesh |
AddMetadata(uint, string, string)
Add a new metadata property to a metadata component
Declaration
[HandleProcessCorruptedStateExceptions]
public void AddMetadata(uint metadata, string name, string value)
Parameters
Type | Name | Description |
---|---|---|
uint | metadata | The metadata component |
string | name | The new property name |
string | value | The new property value |
AddMetadataBlock(uint, StringList, StringList)
Add a new metadata property to a metadata component
Declaration
[HandleProcessCorruptedStateExceptions]
public void AddMetadataBlock(uint metadata, StringList names, StringList values)
Parameters
Type | Name | Description |
---|---|---|
uint | metadata | The metadata component |
StringList | names | The new properties names |
StringList | values | The new properties values |
AddSceneChangedCallback(SceneChangedDelegate, IntPtr)
Declaration
public uint AddSceneChangedCallback(SceneInterface.SceneChangedDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.SceneChangedDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddSelectionChangedCallback(SelectionChangedDelegate, IntPtr)
Declaration
public uint AddSelectionChangedCallback(SceneInterface.SelectionChangedDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.SelectionChangedDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddVariant(string)
Create a new variant
Declaration
[HandleProcessCorruptedStateExceptions]
public uint AddVariant(string name)
Parameters
Type | Name | Description |
---|---|---|
string | name | The name of the new variant |
Returns
Type | Description |
---|---|
uint |
AddVariantChangedCallback(VariantChangedDelegate, IntPtr)
Declaration
public uint AddVariantChangedCallback(SceneInterface.VariantChangedDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.VariantChangedDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddonRayProbeCallback(onRayProbeDelegate, IntPtr)
Declaration
public uint AddonRayProbeCallback(SceneInterface.onRayProbeDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.onRayProbeDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AddonSphereProbeCallback(onSphereProbeDelegate, IntPtr)
Declaration
public uint AddonSphereProbeCallback(SceneInterface.onSphereProbeDelegate callback, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
SceneInterface.onSphereProbeDelegate | callback | |
IntPtr | userData |
Returns
Type | Description |
---|---|
uint |
AlignPivotPointToWorld(OccurrenceList, bool)
Re-orient the Pivot Point straight to world origin (the grid)
Declaration
[HandleProcessCorruptedStateExceptions]
public void AlignPivotPointToWorld(OccurrenceList occurrences, bool applyToChildren)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrences to modify |
bool | applyToChildren | If True, all the pivot of the descending occurrences from occurrence will be affected |
AnimatesThisOccurrence(uint, uint)
Does this Animation animates this Occurrence - or one of its parents (thus animating it indirectly) ?
Declaration
[HandleProcessCorruptedStateExceptions]
public bool AnimatesThisOccurrence(uint animation, uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The Animation |
uint | occurrence | The supposedly animated occurrence |
Returns
Type | Description |
---|---|
bool |
ApplyTransformation(uint, Matrix4)
apply a transformation to the local matrix of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void ApplyTransformation(uint occurrence, Matrix4 matrix)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Occurrence to apply the matrix on |
Matrix4 | matrix | Transformation to matrix |
BakeAnimation(uint, uint, uint, ulong)
WARNING: this function is tagged as 'EXPERIMENTAL'
Bake an animation. The values are now precalculated and no longer interpolated.
Declaration
[HandleProcessCorruptedStateExceptions]
public void BakeAnimation(uint animation, uint occurrence, uint end, ulong interval)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The Animation |
uint | occurrence | The occurrence |
uint | end | The parent occurrence |
ulong | interval | The interval |
CleanInstances(bool, bool, uint)
Clean prototypes and instances (lonely instances, overriding their prototypes hierarchies...).
Declaration
[HandleProcessCorruptedStateExceptions]
public void CleanInstances(bool removeUselessInstances, bool removeHierarchyOverridingInstances, uint occurrence = 0)
Parameters
Type | Name | Description |
---|---|---|
bool | removeUselessInstances | Remove instances where they are not needed (prototype referenced once, ...) |
bool | removeHierarchyOverridingInstances | Remove instances overriding their prototypes sub-hierarchies. |
uint | occurrence | Root occurrence for the process |
CleanUnusedImages()
Remove unused images from texture library
Declaration
[HandleProcessCorruptedStateExceptions]
public int CleanUnusedImages()
Returns
Type | Description |
---|---|
int |
CleanUnusedMaterials(bool)
Remove unused materials from material library
Declaration
[HandleProcessCorruptedStateExceptions]
public int CleanUnusedMaterials(bool cleanImages = false)
Parameters
Type | Name | Description |
---|---|---|
bool | cleanImages | Call cleanUnusedImages if true |
Returns
Type | Description |
---|---|
int |
ClearSelection()
Clear the current selection
Declaration
[HandleProcessCorruptedStateExceptions]
public void ClearSelection()
Compress(uint)
Compress a sub-tree by removing occurrence containing only one Child or empty, and by removing useless instances (see removeUselessInstances)
Declaration
[HandleProcessCorruptedStateExceptions]
public uint Compress(uint occurrence = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Root occurrence for the process |
Returns
Type | Description |
---|---|
uint |
ComputeSubTreeChecksum(uint)
Compute the checksum of a sub-tree
Declaration
[HandleProcessCorruptedStateExceptions]
public string ComputeSubTreeChecksum(uint root = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Occurrence to compute |
Returns
Type | Description |
---|---|
string |
ConfigureFunctionLogger(string, bool, bool, bool)
Declaration
[HandleProcessCorruptedStateExceptions]
public void ConfigureFunctionLogger(string functionName, bool enableFunction, bool enableParameters, bool enableExecutionTime)
Parameters
Type | Name | Description |
---|---|---|
string | functionName | |
bool | enableFunction | |
bool | enableParameters | |
bool | enableExecutionTime |
ConvertMaterialsToColor(MaterialList)
Convert all materials to materials with a color pattern, trying to keep the visual aspect as similar as possible
Declaration
[HandleProcessCorruptedStateExceptions]
public void ConvertMaterialsToColor(MaterialList materials = null)
Parameters
Type | Name | Description |
---|---|---|
MaterialList | materials | Materials to merge (merge all materials if empty) |
ConvertMaterialsToPBR(MaterialList)
Convert all materials to materials with a PBR pattern, trying to keep the visual aspect as similar as possible
Declaration
[HandleProcessCorruptedStateExceptions]
public void ConvertMaterialsToPBR(MaterialList materials = null)
Parameters
Type | Name | Description |
---|---|---|
MaterialList | materials | Materials to merge (merge all materials if empty) |
ConvertPMIToOccurrences(OccurrenceList, bool)
Convert each PMI component into a set of occurrences with mesh geometries
Declaration
[HandleProcessCorruptedStateExceptions]
public void ConvertPMIToOccurrences(OccurrenceList occurrences, bool convertVisibility = false)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Occurrence selection |
bool | convertVisibility | If True, the visibility will be converted (useful to select a specific view/variant), else all occurrences will be visible |
ConvertToOldSchoolVisibility(uint)
Modify the visible properties of the sub-tree to look like old school visibility (only hidden/inherited)
Declaration
[HandleProcessCorruptedStateExceptions]
public void ConvertToOldSchoolVisibility(uint root = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root occurrence |
CreateAlternativeTree(string, uint)
Create a new alternative tree
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateAlternativeTree(string name, uint root = 0)
Parameters
Type | Name | Description |
---|---|---|
string | name | The name of the new alternative tree |
uint | root | The root occurrence |
Returns
Type | Description |
---|---|
uint |
CreateAnimation(string)
Creates an animation, need to use addAnimation when animation is filled
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateAnimation(string name)
Parameters
Type | Name | Description |
---|---|---|
string | name | Name of the animation |
Returns
Type | Description |
---|---|
uint |
CreateAnnotationFromDefinition(AnnotationDefinition)
Create Annotation from definition
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateAnnotationFromDefinition(AnnotationDefinition definition)
Parameters
Type | Name | Description |
---|---|---|
AnnotationDefinition | definition | Annotation definition |
Returns
Type | Description |
---|---|
uint |
CreateCapsule(double, double, int, int, bool)
Create a new capsule
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateCapsule(double radius, double height, int subdivisionLatitude = 16, int subdivisionLongitude = 16, bool generateUV = true)
Parameters
Type | Name | Description |
---|---|---|
double | radius | Radius of the Capsule |
double | height | Height of the Capsule (excluding the two size of half spheres) |
int | subdivisionLatitude | Subdivision of the Capsule on the Latitude |
int | subdivisionLongitude | Subdivision of the Capsule (two half spheres) on the Longitude |
bool | generateUV | Generation of the UV |
Returns
Type | Description |
---|---|
uint |
CreateCone(double, double, int, bool)
Create a new cone
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateCone(double bottomRadius, double height, int sides = 16, bool generateUV = true)
Parameters
Type | Name | Description |
---|---|---|
double | bottomRadius | Radius of the bottom of the cone |
double | height | Height of the cone |
int | sides | Number of sides of the cone |
bool | generateUV | Generation of the UV |
Returns
Type | Description |
---|---|
uint |
CreateCube(double, double, double, int, bool)
Create a new cube
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateCube(double sizeX, double sizeY, double sizeZ, int subdivision = 1, bool generateUV = true)
Parameters
Type | Name | Description |
---|---|---|
double | sizeX | Size of the Cube on the x axis |
double | sizeY | Size of the Cube on the y axis |
double | sizeZ | Size of the Cube on the z axis |
int | subdivision | Subdivision of the Cube on all the axis |
bool | generateUV | Generation of the UV |
Returns
Type | Description |
---|---|
uint |
CreateCylinder(double, double, int, bool)
Create a new cylinder
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateCylinder(double radius, double height, int sides = 16, bool generateUV = true)
Parameters
Type | Name | Description |
---|---|---|
double | radius | Radius of the Cylinder |
double | height | Height of the Cylinder |
int | sides | Number of Sides of the Cylinder |
bool | generateUV | Generation of the UV |
Returns
Type | Description |
---|---|
uint |
CreateHierarchicalClusters(uint, int, double)
Reorganize a sub tree with hierarchical clustering
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateHierarchicalClusters(uint root, int childrenCountByNode = 2, double minFitting = -1)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root of the sub-tree to reorganize |
int | childrenCountByNode | Order of the hierarchical tree |
double | minFitting | Minimal fitting coefficient to allow 2 nodes to be merged/clustered |
Returns
Type | Description |
---|---|
uint |
CreateImmersion(double, int, int)
Create a new bagel klein
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateImmersion(double radius, int subdivisionX, int subdivisionY)
Parameters
Type | Name | Description |
---|---|---|
double | radius | Radius of the Immersion |
int | subdivisionX | Subdivision of the Immersion on the Latitude |
int | subdivisionY | Subdivision of the Immersion on the Longitude |
Returns
Type | Description |
---|---|
uint |
CreateLight(string, LightType, Color, double, double, uint)
Create an occurrence with a light component
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateLight(string name, LightType lightType, Color color, double power = 1, double cutOff = 20, uint parent = 0)
Parameters
Type | Name | Description |
---|---|---|
string | name | Name of the light |
LightType | lightType | The type of the light |
Color | color | Color of the light |
double | power | The power of the light |
double | cutOff | The cutoff angle of the light |
uint | parent | The parent of the light occurrence |
Returns
Type | Description |
---|---|
uint |
CreateMetadatasFromDefinitions(OccurrenceList, MetadataDefinitionList)
Create Metadata components from definitions
Declaration
[HandleProcessCorruptedStateExceptions]
public MetadataList CreateMetadatasFromDefinitions(OccurrenceList occurrences, MetadataDefinitionList definitions)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | List of occurrences to add the metadata components |
MetadataDefinitionList | definitions | List of metadata definition |
Returns
Type | Description |
---|---|
MetadataList |
CreateOBBMesh(uint)
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateOBBMesh(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence |
Returns
Type | Description |
---|---|
uint |
CreateOccurrence(string, uint)
Create a new occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateOccurrence(string name, uint parent = 0)
Parameters
Type | Name | Description |
---|---|---|
string | name | Name of the new occurrence |
uint | parent | Create the occurrence as a child of parent, if not set the parent will be root |
Returns
Type | Description |
---|---|
uint |
CreateOccurrenceFromAnnotation(uint, bool)
Convert a single annotation on an occurrence into an occurrence with mesh geometry
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateOccurrenceFromAnnotation(uint annotation, bool convertVisibility = false)
Parameters
Type | Name | Description |
---|---|---|
uint | annotation | Annotation that shall be converted to an occurrence with mesh geometry |
bool | convertVisibility | If True, the visibility will be converted (useful to select a specific view/variant), else all occurrences will be visible |
Returns
Type | Description |
---|---|
uint |
CreateOccurrenceFromSelection(string, OccurrenceList, uint, bool)
Create a new occurrence and add the given occurrences as children
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateOccurrenceFromSelection(string name, OccurrenceList children, uint parent, bool keepMaterialAssignment = true)
Parameters
Type | Name | Description |
---|---|---|
string | name | Name of the new occurrence |
OccurrenceList | children | Add given occurrence as children (if any) |
uint | parent | If defined, the new occurrence will be created as a child of this parent. Else if children are defined, the first common parent of children will be used as a parent for this new occurrence. Last resort will be to use the root as parent |
bool | keepMaterialAssignment | If defined, material assignation will be updated to keep the visual same aspect |
Returns
Type | Description |
---|---|
uint |
CreateOccurrenceFromText(string, string, int, ColorAlpha?, double)
Creates an occurrence from string
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateOccurrenceFromText(string text, string font = "ChicFont", int fontSize = 64, ColorAlpha? color = null, double heigth3D = 40)
Parameters
Type | Name | Description |
---|---|---|
string | text | The occurrence's name |
string | font | The font to use |
int | fontSize | The font size |
ColorAlpha? | color | The occurrence color |
double | heigth3D | 3D height of text |
Returns
Type | Description |
---|---|
uint |
CreateOccurrences(string, OccurrenceList)
Create one new occurrence under each given parent
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList CreateOccurrences(string name, OccurrenceList parents = null)
Parameters
Type | Name | Description |
---|---|---|
string | name | Name of the new occurrence |
OccurrenceList | parents | Create the occurrences as a child of each parent. If empty, one occurrence will be created with root as parent |
Returns
Type | Description |
---|---|
OccurrenceList |
CreatePartsFromMeshes(OccurrenceList, MeshList)
Create a set of Parts given meshes and occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public PartList CreatePartsFromMeshes(OccurrenceList occurrences, MeshList meshes)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrence which will contains the part component of the mesh at the same index |
MeshList | meshes | List of mesh to create part, if the mesh is invalid (e.g 0) no part will be created and 0 will be returned in the parts list at this index |
Returns
Type | Description |
---|---|
PartList |
CreatePlane(double, double, int, int, bool)
Create a new plane
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreatePlane(double sizeY, double sizeX, int subdivisionX = 1, int subdivisionY = 1, bool generateUV = true)
Parameters
Type | Name | Description |
---|---|---|
double | sizeY | Size of the Plane on the y axis |
double | sizeX | Size of the Plane on the x axis |
int | subdivisionX | Subdivision of the Plane on the x axis |
int | subdivisionY | Subdivision of the Plane on the y axis |
bool | generateUV | Generation of the UV |
Returns
Type | Description |
---|---|
uint |
CreateProductView(ProductViewDefinition)
Create a productview from definition
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateProductView(ProductViewDefinition definition)
Parameters
Type | Name | Description |
---|---|---|
ProductViewDefinition | definition |
Returns
Type | Description |
---|---|
uint |
CreateRayProber()
Creates a ray prober
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateRayProber()
Returns
Type | Description |
---|---|
uint |
CreateSceneFromMeshes(MeshList, Matrix4List, bool)
Create a scene tree with a list of meshes, all meshes becomes part occurrences with the same root. The same mesh Id can be used several times to handle create instances (prototypes)
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateSceneFromMeshes(MeshList meshes, Matrix4List matrices, bool centerPartPivots = true)
Parameters
Type | Name | Description |
---|---|---|
MeshList | meshes | List of input meshes |
Matrix4List | matrices | List of matrices of input meshes (if empty Identity will be used) |
bool | centerPartPivots | If True, the input meshes will be centered in their local coordinate system and the translation will be set as part matrix. If you want to rollback the meshes to their initial pivots use 'resetPartTransform' function |
Returns
Type | Description |
---|---|
uint |
CreateSkeletonMesh(uint)
Create a skeleton mesh from a joint component tree
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateSkeletonMesh(uint root)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root joint component node |
Returns
Type | Description |
---|---|
uint |
CreateSphere(double, int, int, bool)
Create a new sphere
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateSphere(double radius, int subdivisionLatitude = 16, int subdivisionLongitude = 16, bool generateUV = true)
Parameters
Type | Name | Description |
---|---|---|
double | radius | Radius of the Sphere |
int | subdivisionLatitude | Subdivision of the Sphere on the Latitude |
int | subdivisionLongitude | Subdivision of the Sphere on the Longitude |
bool | generateUV | Generation of the UV |
Returns
Type | Description |
---|---|
uint |
CreateSphereProber()
Creates a sphere prober
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateSphereProber()
Returns
Type | Description |
---|---|
uint |
CreateSubTree(PackedTree, uint, bool)
Create a complete scene tree
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList CreateSubTree(PackedTree tree, uint root = 0, bool replaceRoot = true)
Parameters
Type | Name | Description |
---|---|---|
PackedTree | tree | |
uint | root | Specify the root occurrence of the scene |
bool | replaceRoot | If true, the root occurrence will be replaced by the root of the given tree, else it will be added as a child |
Returns
Type | Description |
---|---|
OccurrenceList |
CreateSymmetry(OccurrenceList, AxisPlane)
Create symmetries from selection
Declaration
[HandleProcessCorruptedStateExceptions]
public void CreateSymmetry(OccurrenceList occurrences, AxisPlane plane)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Selection of occurrences |
AxisPlane | plane | Symmetry plane |
CreateTorus(double, double, int, int, bool)
Create a new torus
Declaration
[HandleProcessCorruptedStateExceptions]
public uint CreateTorus(double majorRadius, double minorRadius, int subdivisionLatitude = 16, int subdivisionLongitude = 16, bool generateUV = true)
Parameters
Type | Name | Description |
---|---|---|
double | majorRadius | Major Radius |
double | minorRadius | Minor Radius |
int | subdivisionLatitude | Subdivision of the Torus on the Latitude |
int | subdivisionLongitude | Subdivision of the Torus on the Longitude |
bool | generateUV | Generation of the UV |
Returns
Type | Description |
---|---|
uint |
DecimateAnimChannelBySegment(uint, double)
Decimates by segment a given AnimChannel
Declaration
[HandleProcessCorruptedStateExceptions]
public void DecimateAnimChannelBySegment(uint channel, double precision)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel |
double | precision | The precision |
DeleteAnimation(uint)
Deletes an animation
Declaration
[HandleProcessCorruptedStateExceptions]
public void DeleteAnimation(uint animation)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The created animation |
DeleteComponentByType(ComponentType, uint, bool)
Delete component from type
Declaration
[HandleProcessCorruptedStateExceptions]
public void DeleteComponentByType(ComponentType componentType, uint occurrence, bool followPrototypes = true)
Parameters
Type | Name | Description |
---|---|---|
ComponentType | componentType | Type of the component |
uint | occurrence | The occurrence to remove components from |
bool | followPrototypes | If true and if the component is not set on the occurrence, try to find it on its prototyping chain |
DeleteComponentsByType(ComponentType, uint)
Delete all components on subtree from type
Declaration
[HandleProcessCorruptedStateExceptions]
public void DeleteComponentsByType(ComponentType componentType, uint rootOccurrence = 0)
Parameters
Type | Name | Description |
---|---|---|
ComponentType | componentType | Type of the component |
uint | rootOccurrence | The root occurrence to remove components from |
DeleteEmptyAnimation()
Delete all animation that contain 0 keyframes
Declaration
[HandleProcessCorruptedStateExceptions]
public void DeleteEmptyAnimation()
DeleteEmptyOccurrences(uint)
Delete all empty assemblies
Declaration
[HandleProcessCorruptedStateExceptions]
public void DeleteEmptyOccurrences(uint root = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root occurrence for the process |
DeleteOccurrences(OccurrenceList)
Delete a liste of occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void DeleteOccurrences(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Occurrences to delete |
DeleteSelection()
Delete all selected occurrences, and/or sub-occurrence elements
Declaration
[HandleProcessCorruptedStateExceptions]
public void DeleteSelection()
DisplayAllKeyframesFromAnimChannel(uint)
Displays info on the selected AnimChannel
Declaration
[HandleProcessCorruptedStateExceptions]
public void DisplayAllKeyframesFromAnimChannel(uint channel)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel |
DisplayAllKeyframesFromAnimation(uint)
Displays info on the selected animation
Declaration
[HandleProcessCorruptedStateExceptions]
public void DisplayAllKeyframesFromAnimation(uint animation)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The animation |
DisplayValueFromAnimChannelAtTime(uint, ulong, bool)
Displays the value
Declaration
[HandleProcessCorruptedStateExceptions]
public void DisplayValueFromAnimChannelAtTime(uint channel, ulong time, bool defaultValue = false)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel |
ulong | time | The time |
bool | defaultValue | Show default instead ? |
DuplicateVariant(uint, string)
Create a new variant which is a copy of an existing variant
Declaration
[HandleProcessCorruptedStateExceptions]
public uint DuplicateVariant(uint variant, string name)
Parameters
Type | Name | Description |
---|---|---|
uint | variant | The variant to duplicated |
string | name | Name of the new variant |
Returns
Type | Description |
---|---|
uint |
EndModifyAllVariants()
Call this function to disable the modifications of all variants at the same time.
Declaration
[HandleProcessCorruptedStateExceptions]
public void EndModifyAllVariants()
EvaluateExpression(string)
Evaluate the given filter expression
Declaration
[HandleProcessCorruptedStateExceptions]
public string EvaluateExpression(string filter)
Parameters
Type | Name | Description |
---|---|---|
string | filter | The filter expression |
Returns
Type | Description |
---|---|
string |
EvaluateExpressionOnOccurrences(OccurrenceList, string)
evaluate the given filter expression on all occurrences under the given occurrence and returns the result
Declaration
[HandleProcessCorruptedStateExceptions]
public StringList EvaluateExpressionOnOccurrences(OccurrenceList occurrences, string filter)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Occurrences on which to evaluate the expression |
string | filter | The filter expression |
Returns
Type | Description |
---|---|
StringList |
EvaluateExpressionOnSubTree(string, uint)
evaluate the given filter expression on all occurrences under the given occurrence and returns the result
Declaration
[HandleProcessCorruptedStateExceptions]
public EvaluateExpressionOnSubTreeReturn EvaluateExpressionOnSubTree(string filter, uint fromOcc = 0)
Parameters
Type | Name | Description |
---|---|---|
string | filter | The filter expression |
uint | fromOcc | Source occurrence of the recursion |
Returns
Type | Description |
---|---|
EvaluateExpressionOnSubTreeReturn |
ExplodeSelection()
For each occurrence, create a new occurrence with the selected sub-occurrence elements and remove them from the original occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void ExplodeSelection()
ExportFilterLibrary(string)
Export filters from a given file
Declaration
[HandleProcessCorruptedStateExceptions]
public void ExportFilterLibrary(string file)
Parameters
Type | Name | Description |
---|---|---|
string | file | File path to export |
FindDuplicatedPartOccurrences(uint, double, double, double, double)
Get duplicated parts
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindDuplicatedPartOccurrences(uint root = 0, double acceptVolumeRatio = 0.01, double acceptPolycountRatio = 0.1, double acceptAABBAxisRatio = 0.01, double acceptAABBCenterDistance = 0.1)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root occurrence for the process |
double | acceptVolumeRatio | If the ratio of volumes of two part is lower than acceptVolumeRatio, they will be considered duplicated |
double | acceptPolycountRatio | If the ratio of polygon counts of two part is lower than acceptPolycountRatio, they will be considered duplicated |
double | acceptAABBAxisRatio | If the ratio of AABB axis of two part is lower than acceptAABBAxisRatio, they will be considered duplicated |
double | acceptAABBCenterDistance | If the ratio of AABB centers of two part is lower than acceptAABBCenterRatio, they will be considered duplicated |
Returns
Type | Description |
---|---|
OccurrenceList |
FindFilterByName(string)
Returns the first filter in the filter library with the given name
Declaration
[HandleProcessCorruptedStateExceptions]
public Filter FindFilterByName(string name)
Parameters
Type | Name | Description |
---|---|---|
string | name | Name of the filter to retrieve (case sensitive) |
Returns
Type | Description |
---|---|
Filter |
FindOccurrencesByMaterial(uint)
get occurrences for which the property "Material" is the given material
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindOccurrencesByMaterial(uint material)
Parameters
Type | Name | Description |
---|---|---|
uint | material | A material |
Returns
Type | Description |
---|---|
OccurrenceList |
FindOccurrencesByMetadata(string, string, OccurrenceList, bool)
Returns all occurrences which a metadata property value matches the given regular expression (ECMAScript)
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindOccurrencesByMetadata(string property, string regex, OccurrenceList roots = null, bool caseInsensitive = false)
Parameters
Type | Name | Description |
---|---|---|
string | property | Property name |
string | regex | Regular expression (ECMAScript) |
OccurrenceList | roots | If specified, restrict the search from the given roots |
bool | caseInsensitive | If True, the regex will be insensitive to upper and lower cases |
Returns
Type | Description |
---|---|
OccurrenceList |
FindOccurrencesByMetadataValue(string, OccurrenceList, bool)
Returns all occurrences with a metadata value matching the given regular expression (ECMAScript)
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindOccurrencesByMetadataValue(string regex, OccurrenceList roots = null, bool caseInsensitive = false)
Parameters
Type | Name | Description |
---|---|---|
string | regex | Regular expression (ECMAScript) |
OccurrenceList | roots | If specified, restrict the search from the given roots |
bool | caseInsensitive | If True, the regex will be insensitive to upper and lower cases |
Returns
Type | Description |
---|---|
OccurrenceList |
FindOccurrencesByProperty(string, string, OccurrenceList, bool)
Returns all occurrences which a property value matches the given regular expression (ECMAScript)
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindOccurrencesByProperty(string property, string regex, OccurrenceList roots = null, bool caseInsensitive = false)
Parameters
Type | Name | Description |
---|---|---|
string | property | Property name |
string | regex | Regular expression (ECMAScript) |
OccurrenceList | roots | If specified, restrict the search from the given roots |
bool | caseInsensitive | If True, the regex will be insensitive to upper and lower cases |
Returns
Type | Description |
---|---|
OccurrenceList |
FindPartOccurrencesByActiveMaterial(uint, OccurrenceList)
Find all part occurrence with a given material as active material (i.e. as seen in the rendering)
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindPartOccurrencesByActiveMaterial(uint material, OccurrenceList roots = null)
Parameters
Type | Name | Description |
---|---|---|
uint | material | A material |
OccurrenceList | roots | If specified, restrict the search from the given roots |
Returns
Type | Description |
---|---|
OccurrenceList |
FindPartOccurrencesByMaximumSize(OccurrenceList, double, double, bool)
Get part occurrences by size
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindPartOccurrencesByMaximumSize(OccurrenceList roots, double maxDiagLength, double maxSize = -1, bool getHidden = false)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | Roots occurrences for the process |
double | maxDiagLength | If the diagonal axis of the bounding box is less than maxDiagLength, part will be filtered. -1 to ignore |
double | maxSize | If the longer axis of the box is less than maxLength, part will be filtered. -1 to ignore |
bool | getHidden | If true, hidden part occurrences meeting the criteria will be filtered as well |
Returns
Type | Description |
---|---|
OccurrenceList |
FindPartOccurrencesByMinimumNumberOfInstances(int)
get part occurrences with more than "minInstanciationCount" occurrence on the scene
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindPartOccurrencesByMinimumNumberOfInstances(int minInstanciationCount)
Parameters
Type | Name | Description |
---|---|---|
int | minInstanciationCount | Min occurrence count |
Returns
Type | Description |
---|---|
OccurrenceList |
FindPartOccurrencesByVisibleMaterial(uint)
get part occurrences for which the given material is visible in the viewer
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindPartOccurrencesByVisibleMaterial(uint material)
Parameters
Type | Name | Description |
---|---|---|
uint | material | A material |
Returns
Type | Description |
---|---|
OccurrenceList |
FindPartOccurrencesInAABB(AABB)
find part occurrences in the scene in a given axis aligned bounding box
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindPartOccurrencesInAABB(AABB aabb)
Parameters
Type | Name | Description |
---|---|---|
AABB | aabb | The axis aligned bounding box |
Returns
Type | Description |
---|---|
OccurrenceList |
FindPartOccurrencesInBox(ExtendedBox, bool)
get part occurrences contained in a given box
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindPartOccurrencesInBox(ExtendedBox box, bool strictlyIncludes)
Parameters
Type | Name | Description |
---|---|---|
ExtendedBox | box | The extension box |
bool | strictlyIncludes | If false, parts only need to intersect the box to be selected |
Returns
Type | Description |
---|---|
OccurrenceList |
FindPartOccurrencesWithUnstitchedOpenShells(uint)
Find Part occurrences containing multiple unstitched openShell entities
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList FindPartOccurrencesWithUnstitchedOpenShells(uint root)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root occurrence |
Returns
Type | Description |
---|---|
OccurrenceList |
GenerateOctaViews(double, int, int, bool)
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GenerateOctaViews(double radius, int XFrames, int YFrames, bool hemi = false)
Parameters
Type | Name | Description |
---|---|---|
double | radius | |
int | XFrames | |
int | YFrames | |
bool | hemi |
Returns
Type | Description |
---|---|
uint |
GenerateOctree(uint, int, double)
Generate a loose octree from the given sub-tree
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GenerateOctree(uint occurrence, int maxDepth = 5, double looseFactor = 2)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Root occurrence of the sub-tree |
int | maxDepth | Defines the depth maximum of the octree |
double | looseFactor | Defines the loose factor of the octree |
Returns
Type | Description |
---|---|
uint |
GetAABB(OccurrenceList, bool)
Returns the axis aligned bounding box of a list of occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public AABB GetAABB(OccurrenceList occurrences, bool precise = false)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | List of occurrences to retrieve the AABB |
bool | precise | If true, will take more time but returns the minimal AABB and use the current animation pose. If false, fast but the AABB is approximated and multiple rotation matrices in the tree structure may extend it a lot, also the static pose of the meshes will be used. |
Returns
Type | Description |
---|---|
AABB |
GetActiveMaterial(uint)
Get the active material on occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetActiveMaterial(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
Returns
Type | Description |
---|---|
uint |
GetActiveMaterials(OccurrenceList)
Get the active materials on multiple occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public MaterialList GetActiveMaterials(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrences to retrieve active material on |
Returns
Type | Description |
---|---|
MaterialList |
GetActivePropertyValue(uint, string, bool)
Get the value of a property on the first parent that own it
Declaration
[HandleProcessCorruptedStateExceptions]
public string GetActivePropertyValue(uint occurrence, string propertyName, bool cacheProperty = false)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | An occurrence |
string | propertyName | Property name |
bool | cacheProperty | If true, the property will be copied on all ancestor of occurrence below the property owner to speed up future calls |
Returns
Type | Description |
---|---|
string |
GetActivePropertyValues(OccurrenceList, string, bool)
Get the value of a property on the first parent that own it for each given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public StringList GetActivePropertyValues(OccurrenceList occurrences, string propertyName, bool cacheProperty = false)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | List of occurrences |
string | propertyName | Property name |
bool | cacheProperty | If true, the property will be copied on all ancestor of occurrence below the property owner to speed up future calls |
Returns
Type | Description |
---|---|
StringList |
GetAlternativeTreeRoot(uint)
Returns the root occurrence associated with the given AlternativeTree
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetAlternativeTreeRoot(uint tree)
Parameters
Type | Name | Description |
---|---|---|
uint | tree | Targeted alternative tree |
Returns
Type | Description |
---|---|
uint |
GetAncestors(uint)
Returns the list of ancestors for one occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetAncestors(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence to test. |
Returns
Type | Description |
---|---|
OccurrenceList |
GetAnimChannelIfExists(uint, uint)
Returns the main AnimChannel of an Occurrence according to a given Animation
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetAnimChannelIfExists(uint animation, uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The Animation |
uint | occurrence | The Occurrence |
Returns
Type | Description |
---|---|
uint |
GetAnimChannelInfo(uint)
WARNING: this function is tagged as 'EXPERIMENTAL'
get an animation channel informations
Declaration
[HandleProcessCorruptedStateExceptions]
public AnimChannelInfo GetAnimChannelInfo(uint channel)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | Animation to get info of |
Returns
Type | Description |
---|---|
AnimChannelInfo |
GetAnimChannelOccurrence(uint)
Returns the Occurrence related to a given AnimChannel
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetAnimChannelOccurrence(uint channel)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel |
Returns
Type | Description |
---|---|
uint |
GetAnimationComponentPropertyBinderLists(uint)
WARNING: this function is tagged as 'EXPERIMENTAL'
packs all animation-related info in an object
Declaration
[HandleProcessCorruptedStateExceptions]
public AnimPropertyBinderList GetAnimationComponentPropertyBinderLists(uint animationComponent)
Parameters
Type | Name | Description |
---|---|---|
uint | animationComponent | Animation to get info of |
Returns
Type | Description |
---|---|
AnimPropertyBinderList |
GetAnimationInfo(uint)
WARNING: this function is tagged as 'EXPERIMENTAL'
packs all animation-related info in an object
Declaration
[HandleProcessCorruptedStateExceptions]
public AnimationInfo GetAnimationInfo(uint animation)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | Animation to get info of |
Returns
Type | Description |
---|---|
AnimationInfo |
GetAnimationPropertyBinderLists(uint)
WARNING: this function is tagged as 'EXPERIMENTAL'
packs all animation-related info in an object
Declaration
[HandleProcessCorruptedStateExceptions]
public AnimPropertyBinderList GetAnimationPropertyBinderLists(uint animation)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | Animation to get info of |
Returns
Type | Description |
---|---|
AnimPropertyBinderList |
GetAnnotationDefinition(uint)
get definition of given annotation
Declaration
[HandleProcessCorruptedStateExceptions]
public AnnotationDefinition GetAnnotationDefinition(uint annotation)
Parameters
Type | Name | Description |
---|---|---|
uint | annotation |
Returns
Type | Description |
---|---|
AnnotationDefinition |
GetAnnotationGroups(uint)
Returns the list of the AnnotationGroup from a PMIComponent
Declaration
[HandleProcessCorruptedStateExceptions]
public AnnotationGroupList GetAnnotationGroups(uint pmiComponent)
Parameters
Type | Name | Description |
---|---|---|
uint | pmiComponent | The pmi component |
Returns
Type | Description |
---|---|
AnnotationGroupList |
GetAnnotationListAABB(AnnotationList)
get the AABB of the annotation list
Declaration
[HandleProcessCorruptedStateExceptions]
public AABB GetAnnotationListAABB(AnnotationList annotationList)
Parameters
Type | Name | Description |
---|---|---|
AnnotationList | annotationList |
Returns
Type | Description |
---|---|
AABB |
GetAnnotations(uint)
Returns the list of the Annotation from a AnnotationGroup
Declaration
[HandleProcessCorruptedStateExceptions]
public AnnotationList GetAnnotations(uint group)
Parameters
Type | Name | Description |
---|---|---|
uint | group | The AnnotationGroup |
Returns
Type | Description |
---|---|
AnnotationList |
GetBRepInfos()
Get BRep info
Declaration
[HandleProcessCorruptedStateExceptions]
public GetBRepInfosReturn GetBRepInfos()
Returns
Type | Description |
---|---|
GetBRepInfosReturn |
GetBrepShape(uint)
Returns the Brep shape of a part
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetBrepShape(uint part)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The Part |
Returns
Type | Description |
---|---|
uint |
GetChildren(uint)
Get the children of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetChildren(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
Returns
Type | Description |
---|---|
OccurrenceList |
GetChildrenCount(uint)
Get the children count of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public int GetChildrenCount(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
Returns
Type | Description |
---|---|
int |
GetComponent(uint, ComponentType, bool)
Returns a component on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetComponent(uint occurrence, ComponentType componentType, bool followPrototypes = true)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
ComponentType | componentType | Type of the component |
bool | followPrototypes | If true and if the component is not set on the occurrence, try to find it on its prototyping chain |
Returns
Type | Description |
---|---|
uint |
GetComponentByOccurrence(OccurrenceList, ComponentType, bool)
Returns one component of the specified type by occurrence if it exists
Declaration
[HandleProcessCorruptedStateExceptions]
public ComponentList GetComponentByOccurrence(OccurrenceList occurrences, ComponentType componentType, bool followPrototypes = true)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrences list |
ComponentType | componentType | Type of the component |
bool | followPrototypes | If true and if the component is not set on the occurrence, try to find it on its prototyping chain |
Returns
Type | Description |
---|---|
ComponentList |
GetComponentOccurrence(uint)
Get the occurrence that own a component
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetComponentOccurrence(uint component)
Parameters
Type | Name | Description |
---|---|---|
uint | component | The component |
Returns
Type | Description |
---|---|
uint |
GetComponentType(uint)
Get the type of a component
Declaration
[HandleProcessCorruptedStateExceptions]
public ComponentType GetComponentType(uint component)
Parameters
Type | Name | Description |
---|---|---|
uint | component | The component |
Returns
Type | Description |
---|---|
ComponentType |
GetCurrentVariantRoot()
Get the current active root. Returns active variant's root if one or global root.
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetCurrentVariantRoot()
Returns
Type | Description |
---|---|
uint |
GetDirectInstances(uint)
Returns all the occurrences prototyping the given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetDirectInstances(uint prototype)
Parameters
Type | Name | Description |
---|---|---|
uint | prototype | The prototype occurrence |
Returns
Type | Description |
---|---|
OccurrenceList |
GetFilterExpression(uint)
Returns the filter expression (string) from a filter id stored in the library
Declaration
[HandleProcessCorruptedStateExceptions]
public string GetFilterExpression(uint filterId)
Parameters
Type | Name | Description |
---|---|---|
uint | filterId | Identifier of the filter to fetch |
Returns
Type | Description |
---|---|
string |
GetFilterFromLibrary(uint)
Retrieve a filter from the library with its identifier
Declaration
[HandleProcessCorruptedStateExceptions]
public Filter GetFilterFromLibrary(uint filterId)
Parameters
Type | Name | Description |
---|---|---|
uint | filterId | Identifier of the filter to retrieve |
Returns
Type | Description |
---|---|
Filter |
GetFilteredOccurrences(string, uint)
Recursively get all the occurrences validating the given filter expression
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetFilteredOccurrences(string filter, uint fromOcc = 0)
Parameters
Type | Name | Description |
---|---|---|
string | filter | The filter expression |
uint | fromOcc | Source occurrence of the recursion |
Returns
Type | Description |
---|---|
OccurrenceList |
GetFirstChild(uint)
Get the children of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetFirstChild(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
Returns
Type | Description |
---|---|
uint |
GetGlobalMatrices(OccurrenceList)
Returns the global matrix for each given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public Matrix4List GetGlobalMatrices(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Nodes to get the local matrix |
Returns
Type | Description |
---|---|
Matrix4List |
GetGlobalMatrix(uint)
Returns the global matrix on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public Matrix4 GetGlobalMatrix(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Occurrence to get the global matrix |
Returns
Type | Description |
---|---|
Matrix4 |
GetGlobalVisibility(uint)
Returns the global visibility of a given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public bool GetGlobalVisibility(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Occurrence to get the global visibility |
Returns
Type | Description |
---|---|
bool |
GetHiddenPartOccurrences(OccurrenceList)
Get hidden part occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetHiddenPartOccurrences(OccurrenceList roots = null)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | Roots occurrences for the process |
Returns
Type | Description |
---|---|
OccurrenceList |
GetInstances(uint)
Get occurrences sharing the same prototype as the given one
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetInstances(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Reference part occurrence |
Returns
Type | Description |
---|---|
OccurrenceList |
GetJointDefinition(uint)
Get joint definition from id
Declaration
[HandleProcessCorruptedStateExceptions]
public JointDefinition GetJointDefinition(uint joint)
Parameters
Type | Name | Description |
---|---|---|
uint | joint | Id of the joint |
Returns
Type | Description |
---|---|
JointDefinition |
GetJointDefinitions(JointList)
Get joint definition from id
Declaration
[HandleProcessCorruptedStateExceptions]
public JointDefinitionList GetJointDefinitions(JointList joints)
Parameters
Type | Name | Description |
---|---|---|
JointList | joints | Ids of joints |
Returns
Type | Description |
---|---|
JointDefinitionList |
GetKeyframeParentAnimChannel(uint)
Returns the parent AnimChannel of a given Keyframe
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetKeyframeParentAnimChannel(uint keyframe)
Parameters
Type | Name | Description |
---|---|---|
uint | keyframe | The keyframe one wants the parent of |
Returns
Type | Description |
---|---|
uint |
GetKeyframes(uint)
Returns a list of all keyframes of a simple animChannel
Declaration
[HandleProcessCorruptedStateExceptions]
public KeyframeList GetKeyframes(uint channel)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel one wants to extract the keyframs from |
Returns
Type | Description |
---|---|
KeyframeList |
GetLastError()
Declaration
public static string GetLastError()
Returns
Type | Description |
---|---|
string |
GetLocalMatrices(OccurrenceList)
Returns the local matrix for each given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public Matrix4List GetLocalMatrices(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Nodes to get the local matrix |
Returns
Type | Description |
---|---|
Matrix4List |
GetLocalMatrix(uint)
Returns the local matrix on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public Matrix4 GetLocalMatrix(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Node to get the local matrix |
Returns
Type | Description |
---|---|
Matrix4 |
GetMBB(OccurrenceList, Point3?)
Returns the Minimum Bounding Box of a list of occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public OBB GetMBB(OccurrenceList occurrences, Point3? forcedAxis = null)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | List of occurrences to retrieve the MBB |
Point3? | forcedAxis | Forced axis of the mbb |
Returns
Type | Description |
---|---|
OBB |
GetMainChannel(uint)
Returns the main AnimChannel of a given AnimChannel
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetMainChannel(uint channel)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel one wants the main of |
Returns
Type | Description |
---|---|
uint |
GetMaterialsFromSubtree(uint)
Declaration
[HandleProcessCorruptedStateExceptions]
public MaterialList GetMaterialsFromSubtree(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Root occurrence of the subtree on which to get the materials and images |
Returns
Type | Description |
---|---|
MaterialList |
GetMetadata(uint, string)
Get a metadata property value from a metadata component
Declaration
[HandleProcessCorruptedStateExceptions]
public string GetMetadata(uint metadata, string name)
Parameters
Type | Name | Description |
---|---|---|
uint | metadata | The metadata component |
string | name | The metadata property name |
Returns
Type | Description |
---|---|
string |
GetMetadatasDefinitions(MetadataList)
Returns definition of Metadata components
Declaration
[HandleProcessCorruptedStateExceptions]
public MetadataDefinitionList GetMetadatasDefinitions(MetadataList metadatas)
Parameters
Type | Name | Description |
---|---|---|
MetadataList | metadatas | List of metadata component to retrieve definition |
Returns
Type | Description |
---|---|
MetadataDefinitionList |
GetMultipleOccurrenceUserData(uint, OccurrenceList)
Batch version of getOccurrenceUserData
Declaration
[HandleProcessCorruptedStateExceptions]
public PtrList GetMultipleOccurrenceUserData(uint userDataId, OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier provided by subscribeToOccurrenceUserData |
OccurrenceList | occurrences | Occurrences that store the user data |
Returns
Type | Description |
---|---|
PtrList |
GetNextSibling(uint)
Get the children of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetNextSibling(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
Returns
Type | Description |
---|---|
uint |
GetOBB(OccurrenceList)
Returns the Oriented Bounding Box of a list of occurrences (works only on meshes, fast method, not the Minimum Volume Box)
Declaration
[HandleProcessCorruptedStateExceptions]
public OBB GetOBB(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | List of occurrences to retrieve the OBB |
Returns
Type | Description |
---|---|
OBB |
GetOccurrenceActiveMaterial(uint)
Returns the active material on a given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetOccurrenceActiveMaterial(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Occurrence to get the active material |
Returns
Type | Description |
---|---|
uint |
GetOccurrenceAncestors(uint)
Get all ancestors from occurrence until root (occurrence is not included)
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetOccurrenceAncestors(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence to find ancestors |
Returns
Type | Description |
---|---|
OccurrenceList |
GetOccurrenceAnnotationDefinitions(uint)
get all annotations definition of given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public AnnotationDefinitionList GetOccurrenceAnnotationDefinitions(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence |
Returns
Type | Description |
---|---|
AnnotationDefinitionList |
GetOccurrenceJoint(uint)
Returns the Joint assigned to an occurrence if any
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetOccurrenceJoint(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
Returns
Type | Description |
---|---|
uint |
GetOccurrenceName(uint)
Returns the name of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public string GetOccurrenceName(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence to get the name |
Returns
Type | Description |
---|---|
string |
GetOccurrenceUserData(uint, uint)
Set or replace a userdata stored on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public IntPtr GetOccurrenceUserData(uint userDataId, uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier provided by subscribeToOccurrenceUserData |
uint | occurrence | Occurrence that store the user data |
Returns
Type | Description |
---|---|
IntPtr |
GetOccurrencesAncestors(OccurrenceList)
Batch version of getOccurrenceAncestors
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceListList GetOccurrencesAncestors(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The list of occurrences to find ancestors |
Returns
Type | Description |
---|---|
OccurrenceListList |
GetOccurrencesWithComponent(ComponentType, uint)
Recursively get all the occurrences containing a component of the specified type
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetOccurrencesWithComponent(ComponentType componentType, uint fromOcc = 0)
Parameters
Type | Name | Description |
---|---|---|
ComponentType | componentType | The component type |
uint | fromOcc | Source occurrence of the recursion |
Returns
Type | Description |
---|---|
OccurrenceList |
GetParent(uint)
Get the parent of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetParent(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
Returns
Type | Description |
---|---|
uint |
GetParentChannel(uint)
Returns (if exists) the parent AnimChannel of a given AnimChannel
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetParentChannel(uint channel)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel one wants the parent of |
Returns
Type | Description |
---|---|
uint |
GetPartActiveShape(uint)
Returns the active shape of a part
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetPartActiveShape(uint part)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The part |
Returns
Type | Description |
---|---|
uint |
GetPartMesh(uint)
Return the mesh of the TesselatedShape
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetPartMesh(uint part)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The part component |
Returns
Type | Description |
---|---|
uint |
GetPartModel(uint)
Return the model of the BRepShape
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetPartModel(uint part)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The part component |
Returns
Type | Description |
---|---|
uint |
GetPartOccurrences(uint)
Recursively get all the occurrences containing a part component
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetPartOccurrences(uint fromOcc = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | fromOcc | Source occurrence of the recursion |
Returns
Type | Description |
---|---|
OccurrenceList |
GetPartShapeType(uint)
Get the part's shape type
Declaration
[HandleProcessCorruptedStateExceptions]
public ShapeType GetPartShapeType(uint part)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The part to test |
Returns
Type | Description |
---|---|
ShapeType |
GetPartialLoadingStatus(uint)
Get the current status of a partial loading component
Declaration
[HandleProcessCorruptedStateExceptions]
public PartialLoad_Status GetPartialLoadingStatus(uint component)
Parameters
Type | Name | Description |
---|---|---|
uint | component | Referenced Data component |
Returns
Type | Description |
---|---|
PartialLoad_Status |
GetPartsMeshes(PartList)
Return the meshes of the TesselatedShape for each given parts if any
Declaration
[HandleProcessCorruptedStateExceptions]
public MeshList GetPartsMeshes(PartList parts)
Parameters
Type | Name | Description |
---|---|---|
PartList | parts | The list of part component |
Returns
Type | Description |
---|---|
MeshList |
GetPartsModels(PartList)
Return the models of the BRepShape for each given parts if any
Declaration
[HandleProcessCorruptedStateExceptions]
public ModelList GetPartsModels(PartList parts)
Parameters
Type | Name | Description |
---|---|---|
PartList | parts | The list of part component |
Returns
Type | Description |
---|---|
ModelList |
GetPartsTransforms(PartList)
Returns the transform matrix of each given parts
Declaration
[HandleProcessCorruptedStateExceptions]
public Matrix4List GetPartsTransforms(PartList parts)
Parameters
Type | Name | Description |
---|---|---|
PartList | parts | The parts to retrieve transform |
Returns
Type | Description |
---|---|
Matrix4List |
GetPartsTransformsIndexed(PartList)
Returns the transform matrix of each given parts (indexed mode)
Declaration
[HandleProcessCorruptedStateExceptions]
public GetPartsTransformsIndexedReturn GetPartsTransformsIndexed(PartList parts)
Parameters
Type | Name | Description |
---|---|---|
PartList | parts | The parts to retrieve transform |
Returns
Type | Description |
---|---|
GetPartsTransformsIndexedReturn |
GetPolygonCount(OccurrenceList, bool, bool, bool)
Returns the number of polygon in the parts meshes
Declaration
[HandleProcessCorruptedStateExceptions]
public ulong GetPolygonCount(OccurrenceList occurrences, bool asTriangleCount = false, bool countOnceEachInstance = false, bool countHidden = false)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The part occurrences |
bool | asTriangleCount | If true count the equivalent of triangles for each polygon |
bool | countOnceEachInstance | If true ignore multiple instance of each tessellation |
bool | countHidden | If true, also count hidden components |
Returns
Type | Description |
---|---|
ulong |
GetProductViewDefinition(uint)
get productview definition
Declaration
[HandleProcessCorruptedStateExceptions]
public ProductViewDefinition GetProductViewDefinition(uint view)
Parameters
Type | Name | Description |
---|---|---|
uint | view | The product view |
Returns
Type | Description |
---|---|
ProductViewDefinition |
GetProductViewDefinitions()
get all productviews definitions
Declaration
[HandleProcessCorruptedStateExceptions]
public ProductViewDefinitionList GetProductViewDefinitions()
Returns
Type | Description |
---|---|
ProductViewDefinitionList |
GetPrototype(uint)
Returns the prototype of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetPrototype(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
Returns
Type | Description |
---|---|
uint |
GetPrototypes(OccurrenceList)
Returns the prototype for each given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetPrototypes(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrence |
Returns
Type | Description |
---|---|
OccurrenceList |
GetRoot()
Get the root occurrence of the product structure
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetRoot()
Returns
Type | Description |
---|---|
uint |
GetSelectedOccurrences(bool)
Returns all the selected occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetSelectedOccurrences(bool keepAncestors = false)
Parameters
Type | Name | Description |
---|---|---|
bool | keepAncestors | If True, occurrences with ancestors selected will be remove from the list |
Returns
Type | Description |
---|---|
OccurrenceList |
GetSelectedPolygonCount()
Returns the number of selected polygons
Declaration
[HandleProcessCorruptedStateExceptions]
public ulong GetSelectedPolygonCount()
Returns
Type | Description |
---|---|
ulong |
GetSubChannel(uint, string)
Returns the subchannel of a given name from an AnimChannel
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetSubChannel(uint channel, string name)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel one wants the subchannel of |
string | name | The name of the subchannel |
Returns
Type | Description |
---|---|
uint |
GetSubChannels(uint)
Returns all the sub channel of an AnimChannel
Declaration
[HandleProcessCorruptedStateExceptions]
public AnimChannelList GetSubChannels(uint channel)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel one wants the subchannel of |
Returns
Type | Description |
---|---|
AnimChannelList |
GetSubTree(uint, VisibilityMode, int)
Returns a packed version of the whole scene tree
Declaration
[HandleProcessCorruptedStateExceptions]
public PackedTree GetSubTree(uint root = 0, VisibilityMode visibilityMode = VisibilityMode.Hide, int depth = -1)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Specify the root of the returned scene |
VisibilityMode | visibilityMode | The visibility mode |
int | depth | Maximum depth |
Returns
Type | Description |
---|---|
PackedTree |
GetSubTreeStats(OccurrenceList)
Returns some stats of a sub tree
Declaration
[HandleProcessCorruptedStateExceptions]
public GetSubTreeStatsReturn GetSubTreeStats(OccurrenceList roots)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | The root occurrences to get stats on. |
Returns
Type | Description |
---|---|
GetSubTreeStatsReturn |
GetSubpartMaterial(uint, uint)
Get a subpart material assignment according to overrides on the scene tree with SubpartMaterial components
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetSubpartMaterial(uint occurrence, uint subpartIndex)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The Occurrence |
uint | subpartIndex | The subpart index |
Returns
Type | Description |
---|---|
uint |
GetTessellationInfos(uint)
Get tessellation info
Declaration
[HandleProcessCorruptedStateExceptions]
public GetTessellationInfosReturn GetTessellationInfos(uint root = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Occurrence tree root |
Returns
Type | Description |
---|---|
GetTessellationInfosReturn |
GetTessellationParameters(uint)
Get tessellation parameters
Declaration
[HandleProcessCorruptedStateExceptions]
public GetTessellationParametersReturn GetTessellationParameters(uint part)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The tessellated part |
Returns
Type | Description |
---|---|
GetTessellationParametersReturn |
GetVariantComponentsDefinitions(VariantComponentList)
Returns the definitions of multiple variant components
Declaration
[HandleProcessCorruptedStateExceptions]
public VariantDefinitionListList GetVariantComponentsDefinitions(VariantComponentList variantComponents)
Parameters
Type | Name | Description |
---|---|---|
VariantComponentList | variantComponents | The list of variant components to retrieve definitions |
Returns
Type | Description |
---|---|
VariantDefinitionListList |
GetVariantTree(uint)
Get the alternative tree used by this variant
Declaration
[HandleProcessCorruptedStateExceptions]
public uint GetVariantTree(uint variant)
Parameters
Type | Name | Description |
---|---|---|
uint | variant | The variant |
Returns
Type | Description |
---|---|
uint |
GetVertexCount(OccurrenceList, bool, bool, bool, bool)
Returns the number of vertices in the parts meshes
Declaration
[HandleProcessCorruptedStateExceptions]
public ulong GetVertexCount(OccurrenceList occurrences, bool countOnceEachInstance = false, bool countHidden = false, bool countPoints = false, bool countMergedVertices = false)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The part occurrences |
bool | countOnceEachInstance | If true ignore multiple instance of each tessellation |
bool | countHidden | If true, also count hidden components |
bool | countPoints | If true, also count points (for points cloud) |
bool | countMergedVertices | If true count all merged vertices in each tessellation |
Returns
Type | Description |
---|---|
ulong |
GetViewpointsFromCavities(double, double)
Returns viewpoints from model cavities
Declaration
[HandleProcessCorruptedStateExceptions]
public GetViewpointsFromCavitiesReturn GetViewpointsFromCavities(double voxelSize, double minCavityVolume)
Parameters
Type | Name | Description |
---|---|---|
double | voxelSize | Precision for cavities detection |
double | minCavityVolume | Minimum volume for a cavity to be returned |
Returns
Type | Description |
---|---|
GetViewpointsFromCavitiesReturn |
GetVisiblePartOccurrences(OccurrenceList)
Get visible part occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList GetVisiblePartOccurrences(OccurrenceList roots = null)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | Roots occurrences for the process |
Returns
Type | Description |
---|---|
OccurrenceList |
GetVolume(uint)
Return the volume of the occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public double GetVolume(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Entry occurrence |
Returns
Type | Description |
---|---|
double |
GetVolumes(OccurrenceList)
Return the volume of a set of root occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public DoubleList GetVolumes(OccurrenceList iRoots)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | iRoots | List of roots |
Returns
Type | Description |
---|---|
DoubleList |
HasComponent(uint, ComponentType, bool)
Returns True if the given occurrence has the given component type
Declaration
[HandleProcessCorruptedStateExceptions]
public bool HasComponent(uint occurrence, ComponentType componentType, bool followPrototypes = true)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
ComponentType | componentType | Type of the component |
bool | followPrototypes | If true and if the component is not set on the occurrence, try to find it on its prototyping chain |
Returns
Type | Description |
---|---|
bool |
HasMultipleOccurrenceUserData(uint, OccurrenceList)
Batch version of hasOccurrenceUserData
Declaration
[HandleProcessCorruptedStateExceptions]
public BoolList HasMultipleOccurrenceUserData(uint userDataId, OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier provided by subscribeToOccurrenceUserData |
OccurrenceList | occurrences | Occurrences that potentially store the user data |
Returns
Type | Description |
---|---|
BoolList |
HasOccurrenceUserData(uint, uint)
Set or replace a userdata stored on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public bool HasOccurrenceUserData(uint userDataId, uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier provided by subscribeToOccurrenceUserData |
uint | occurrence | Occurrence that potentially store the user data |
Returns
Type | Description |
---|---|
bool |
Hide(OccurrenceList)
Hide the given occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void Hide(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The list of occurrences to hide |
ImportFilterLibrary(string)
Import filters from a given file
Declaration
[HandleProcessCorruptedStateExceptions]
public void ImportFilterLibrary(string file)
Parameters
Type | Name | Description |
---|---|---|
string | file | File containing the filter library |
InverseVisibility(OccurrenceList)
Inverse the visibility of the given occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void InverseVisibility(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The list of occurrences |
InvertOrientationSelection()
Invert the orientation of each selected item (occurrences and/or sub-occurrence elements
Declaration
[HandleProcessCorruptedStateExceptions]
public void InvertOrientationSelection()
InvertSelect(OccurrenceList)
Invert occurrences to selection
Declaration
[HandleProcessCorruptedStateExceptions]
public void InvertSelect(OccurrenceList occurrence)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrence | Occurrences to invert from the selection |
InvertSelection()
Replace the selection by all unselected part occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void InvertSelection()
IsAncestorOf(uint, uint)
Test if an occurrence is an ancestor of another one.
Declaration
[HandleProcessCorruptedStateExceptions]
public bool IsAncestorOf(uint maybeAncestor, uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | maybeAncestor | The potential ancestor of the occurrence |
uint | occurrence | The occurrence to test |
Returns
Type | Description |
---|---|
bool |
Isolate(OccurrenceList)
Enter isolate mode by isolating a subset of the scene for process, export, viewer, ...
Declaration
[HandleProcessCorruptedStateExceptions]
public void Isolate(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Occurrences to isolate |
KeepAncestors(OccurrenceList)
Filter a list of occurrences by removing all occurrences which have an ancestor inside the list.
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList KeepAncestors(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The list that shall be filtered. |
Returns
Type | Description |
---|---|
OccurrenceList |
LinkPropertyToAnimation(uint, uint, string)
Creates a Binder in an Animation stack to animate an entity's property
Declaration
[HandleProcessCorruptedStateExceptions]
public uint LinkPropertyToAnimation(uint animation, uint entity, string propertyName)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The Animation stack where to put a animated property |
uint | entity | The entity object to animate |
string | propertyName | The name of the property to animate |
Returns
Type | Description |
---|---|
uint |
ListActiveShapeMaterials(uint)
list all the materials used in the part shape
Declaration
[HandleProcessCorruptedStateExceptions]
public MaterialList ListActiveShapeMaterials(uint part)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The part which contains sub materials |
Returns
Type | Description |
---|---|
MaterialList |
ListAlternativeTrees()
Returns all the available alternative trees
Declaration
[HandleProcessCorruptedStateExceptions]
public AlternativeTreeList ListAlternativeTrees()
Returns
Type | Description |
---|---|
AlternativeTreeList |
ListAnimations()
List all Animations from the scene
Declaration
[HandleProcessCorruptedStateExceptions]
public AnimationList ListAnimations()
Returns
Type | Description |
---|---|
AnimationList |
ListComponent(ComponentType)
List all components on a type on the whole tree
Declaration
[HandleProcessCorruptedStateExceptions]
public ComponentList ListComponent(ComponentType componentType)
Parameters
Type | Name | Description |
---|---|---|
ComponentType | componentType | The component type |
Returns
Type | Description |
---|---|
ComponentList |
ListComponents(uint, bool)
List all components on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public ComponentList ListComponents(uint occurrence, bool followPrototypes = true)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence to list the components |
bool | followPrototypes | If true list also components owned by the prototype |
Returns
Type | Description |
---|---|
ComponentList |
ListFilterLibrary()
Returns all the filter stored in the filter library
Declaration
[HandleProcessCorruptedStateExceptions]
public FilterList ListFilterLibrary()
Returns
Type | Description |
---|---|
FilterList |
ListMainChannels(uint)
List all main AnimChannel from a given Animation
Declaration
[HandleProcessCorruptedStateExceptions]
public AnimChannelList ListMainChannels(uint animation)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The Animation one wants to list the channels from |
Returns
Type | Description |
---|---|
AnimChannelList |
ListSubpartMaterials(uint)
list all the materials used in the part shape or overrided with a SubpartMaterial component
Declaration
[HandleProcessCorruptedStateExceptions]
public MaterialList ListSubpartMaterials(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence which contains sub materials |
Returns
Type | Description |
---|---|
MaterialList |
ListSubpartVariantMaterials(uint)
list all the materials variants in subpart
Declaration
[HandleProcessCorruptedStateExceptions]
public VariantMaterialList ListSubpartVariantMaterials(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence which contains variants |
Returns
Type | Description |
---|---|
VariantMaterialList |
ListVariants()
Returns all the available variants
Declaration
[HandleProcessCorruptedStateExceptions]
public VariantList ListVariants()
Returns
Type | Description |
---|---|
VariantList |
MakeDefaultKeyframe(uint)
Creates keyframes with the default values of the channel at time 0
Declaration
[HandleProcessCorruptedStateExceptions]
public void MakeDefaultKeyframe(uint channel)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel |
MakeInstanceUnique(OccurrenceList, bool)
Singularize all instances on the sub-tree of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void MakeInstanceUnique(OccurrenceList occurrences = null, bool keepOnlyPartInstances = false)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Root occurrence for the process |
bool | keepOnlyPartInstances | If true, instances of part will not be singularized |
MergeImages(ImageList)
Merge all equivalent images (i.e. with same pixels)
Declaration
[HandleProcessCorruptedStateExceptions]
public int MergeImages(ImageList images = null)
Parameters
Type | Name | Description |
---|---|---|
ImageList | images | Images to merge (merge all images if empty) |
Returns
Type | Description |
---|---|
int |
MergeMaterials(MaterialList, bool)
Merge all equivalent materials (i.e. with same appearance)
Declaration
[HandleProcessCorruptedStateExceptions]
public int MergeMaterials(MaterialList materials = null, bool evaluateNames = false)
Parameters
Type | Name | Description |
---|---|---|
MaterialList | materials | Materials to merge (merge all materials if empty) |
bool | evaluateNames | If true, materials names will be taken into consideration (on top of other properties). It means that materials having same properties but different names won't be merged together. |
Returns
Type | Description |
---|---|
int |
MergeOccurrencesByTreeLevel(OccurrenceList, int, MergeHiddenPartsMode)
Merge all parts over maxLevel level
Declaration
[HandleProcessCorruptedStateExceptions]
public void MergeOccurrencesByTreeLevel(OccurrenceList roots, int maxLevel, MergeHiddenPartsMode mergeHiddenPartsMode = MergeHiddenPartsMode.MergeSeparately)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | Roots occurrences for the process |
int | maxLevel | Maximum tree level |
MergeHiddenPartsMode | mergeHiddenPartsMode | Hidden parts handling mode, Destroy them, make visible or merge separately |
MergePartOccurrences(OccurrenceList, MergeHiddenPartsMode)
Merge a set of parts
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList MergePartOccurrences(OccurrenceList partOccurrences, MergeHiddenPartsMode mergeHiddenPartsMode = MergeHiddenPartsMode.MergeSeparately)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | partOccurrences | Occurrence of the parts to merge |
MergeHiddenPartsMode | mergeHiddenPartsMode | Hidden parts handling mode, Destroy them, make visible or merge separately |
Returns
Type | Description |
---|---|
OccurrenceList |
MergePartOccurrencesByAssemblies(OccurrenceList, MergeHiddenPartsMode)
Merge all parts under each assembly together
Declaration
[HandleProcessCorruptedStateExceptions]
public void MergePartOccurrencesByAssemblies(OccurrenceList roots = null, MergeHiddenPartsMode mergeHiddenPartsMode = MergeHiddenPartsMode.MergeSeparately)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | Roots occurrences for the process (will not be removed) |
MergeHiddenPartsMode | mergeHiddenPartsMode | Hidden parts handling mode, Destroy them, make visible or merge separately |
MergePartOccurrencesByFinalAssemblies(OccurrenceList, MergeHiddenPartsMode, bool)
Merge final level (occurrences with only occurrence with part component as children)
Declaration
[HandleProcessCorruptedStateExceptions]
public void MergePartOccurrencesByFinalAssemblies(OccurrenceList roots = null, MergeHiddenPartsMode mergeHiddenPartsMode = MergeHiddenPartsMode.Destroy, bool CollapseToParent = true)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | Roots occurrences for the process (will not be removed) |
MergeHiddenPartsMode | mergeHiddenPartsMode | Hidden parts handling mode, Destroy them, make visible or merge separately |
bool | CollapseToParent | If true, final level unique merged part will replace it's parent |
MergePartOccurrencesByMaterials(OccurrenceList, bool, MergeHiddenPartsMode, bool)
Merge a set of parts by materials
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList MergePartOccurrencesByMaterials(OccurrenceList partOccurrences, bool mergeNoMaterials = true, MergeHiddenPartsMode mergeHiddenPartsMode = MergeHiddenPartsMode.MergeSeparately, bool combineMeshes = true)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | partOccurrences | Occurrence of the parts to merge |
bool | mergeNoMaterials | If true, merge all parts with no active material together, else do not merge them |
MergeHiddenPartsMode | mergeHiddenPartsMode | Hidden parts handling mode, Destroy them, make visible or merge separately |
bool | combineMeshes | If true, explode and remerge the input parts by visible materials |
Returns
Type | Description |
---|---|
OccurrenceList |
MergePartOccurrencesByName(uint, MergeHiddenPartsMode)
Merge all parts by occurrences names
Declaration
[HandleProcessCorruptedStateExceptions]
public void MergePartOccurrencesByName(uint root = 0, MergeHiddenPartsMode mergeHiddenPartsMode = MergeHiddenPartsMode.MergeSeparately)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root occurrence of the subtree to process |
MergeHiddenPartsMode | mergeHiddenPartsMode | Hidden parts handling mode, Destroy them, make visible or merge separately |
MergePartOccurrencesByRegions(OccurrenceList, MergeByRegionsStrategy, MergeStrategy)
Merge all parts within the same area.
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList MergePartOccurrencesByRegions(OccurrenceList roots, MergeByRegionsStrategy mergeBy, MergeStrategy strategy)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | Roots occurrences for the process (will not be removed) |
MergeByRegionsStrategy | mergeBy | Number: number of output parts (or regions of parts)\nSize: diagonal size of output regions |
MergeStrategy | strategy | Choose the regions merging strategy |
Returns
Type | Description |
---|---|
OccurrenceList |
MergePartOccurrencesWithSingleOpenShellByAssemblies(uint)
Merge Part occurrences containing a single openShell entity, by assemblies
Declaration
[HandleProcessCorruptedStateExceptions]
public OccurrenceList MergePartOccurrencesWithSingleOpenShellByAssemblies(uint root)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root of the main assembly to merge |
Returns
Type | Description |
---|---|
OccurrenceList |
MoveAnimation(uint, uint, uint, ulong)
Moving animation
Declaration
[HandleProcessCorruptedStateExceptions]
public void MoveAnimation(uint animation, uint target, uint newParent, ulong interval)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The Animation |
uint | target | The target occurrence |
uint | newParent | The new parent occurrence |
ulong | interval | The interval |
MoveOccurrences(OccurrenceList, uint, uint)
Move an occurrence, adjusting the transformation to keep objects at the same place in the world space
Declaration
[HandleProcessCorruptedStateExceptions]
public void MoveOccurrences(OccurrenceList occurrences, uint destination, uint insertBefore = 0)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrences to move |
uint | destination | Destination occurrence (the new parent) |
uint | insertBefore | Occurrence before witch to move, if null append to destination children |
MovePivotPointToOccurrenceCenter(OccurrenceList, bool)
Move the pivot point of each occurrence listed in the function input, to the center of its bounding box (and of its children if the parameter is True)
Declaration
[HandleProcessCorruptedStateExceptions]
public void MovePivotPointToOccurrenceCenter(OccurrenceList occurrences, bool applyToChildren)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Occurrences (or the roots occurrences if recursively=True) |
bool | applyToChildren | If True, all the pivot of the descending occurrences from occurrence will be affected |
MovePivotPointToOrigin(uint, bool)
Move the pivot point of an occurrence (and its descendants if recursively) to the origin (0,0,0)
Declaration
[HandleProcessCorruptedStateExceptions]
public void MovePivotPointToOrigin(uint occurrence, bool applyToChildren)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence (or the root occurrence if recursively=True) |
bool | applyToChildren | If True, all the pivot of the descending occurrences from occurrence will be affected |
MovePivotPointToSelectionCenter(OccurrenceList)
Move the pivot point of all given occurrences to the center of all occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void MovePivotPointToSelectionCenter(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrences to modify |
MovePivotPointToTargetedOccurrenceCenter(OccurrenceList, uint, bool)
Move the pivot point of each occurrence listed in the function input, to the center of the targeted occurrence Center (and of its children if the parameter is True)
Declaration
[HandleProcessCorruptedStateExceptions]
public void MovePivotPointToTargetedOccurrenceCenter(OccurrenceList occurrences, uint target, bool applyToChildren)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrence (or the root occurrence if recursively=True) |
uint | target | The target occurrence |
bool | applyToChildren | If True, all the pivot of the descending occurrences from occurrence will be affected |
Print(uint)
Print an occurrence tree on log
Declaration
[HandleProcessCorruptedStateExceptions]
public void Print(uint root = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Occurrence tree root |
PrototypeSubTree(uint)
Create occurrences that prototype the given occurrence and all its subtree
Declaration
[HandleProcessCorruptedStateExceptions]
public uint PrototypeSubTree(uint prototype)
Parameters
Type | Name | Description |
---|---|---|
uint | prototype | The root occurrence of the sub-tree to prototype |
Returns
Type | Description |
---|---|
uint |
Rake(uint, bool)
Set the same parent to all descending parts (all parts will be singularized)
Declaration
[HandleProcessCorruptedStateExceptions]
public void Rake(uint occurrence = 0, bool keepInstances = false)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Root occurrence for the process |
bool | keepInstances | If false, the part will be singularized |
RayCast(Ray, uint)
Declaration
[HandleProcessCorruptedStateExceptions]
public RayHit RayCast(Ray ray, uint root)
Parameters
Type | Name | Description |
---|---|---|
Ray | ray | The ray to cast |
uint | root | The root occurrence to cast from |
Returns
Type | Description |
---|---|
RayHit |
RayCastAll(Ray, uint)
Declaration
[HandleProcessCorruptedStateExceptions]
public RayHitList RayCastAll(Ray ray, uint root)
Parameters
Type | Name | Description |
---|---|---|
Ray | ray | The ray to cast |
uint | root | The root occurrence to cast from |
Returns
Type | Description |
---|---|
RayHitList |
RemoveAnimationAddedCallback(uint)
Declaration
public void RemoveAnimationAddedCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveAnimationChangedCallback(uint)
Declaration
public void RemoveAnimationChangedCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveAnimationClearedCallback(uint)
Declaration
public void RemoveAnimationClearedCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveAnimationRemovedCallback(uint)
Declaration
public void RemoveAnimationRemovedCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveComponentChangedCallback(uint)
Declaration
public void RemoveComponentChangedCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveFilterFromLibrary(uint)
Remove a filter from the filters library
Declaration
[HandleProcessCorruptedStateExceptions]
public void RemoveFilterFromLibrary(uint filterId)
Parameters
Type | Name | Description |
---|---|---|
uint | filterId | Identifier of the filter to remove |
RemoveKeyframe(uint, ulong)
Removes a keyframe in the curve
Declaration
[HandleProcessCorruptedStateExceptions]
public void RemoveKeyframe(uint channel, ulong time)
Parameters
Type | Name | Description |
---|---|---|
uint | channel | The channel one wants to remove a keyframe from |
ulong | time | The time |
RemoveMaterials(OccurrenceList)
Recursively remove all materials
Declaration
[HandleProcessCorruptedStateExceptions]
public void RemoveMaterials(OccurrenceList roots = null)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | roots | If specified, remove materials only from the given occurrences and their descendants |
RemoveMetadata(uint, string)
Remove a property from a metadata
Declaration
[HandleProcessCorruptedStateExceptions]
public void RemoveMetadata(uint metadata, string name)
Parameters
Type | Name | Description |
---|---|---|
uint | metadata | The occurrence |
string | name | The name of the property |
RemoveSceneChangedCallback(uint)
Declaration
public void RemoveSceneChangedCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveSelectionChangedCallback(uint)
Declaration
public void RemoveSelectionChangedCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveSymmetryMatrices(uint)
Remove symmetry matrices (apply matrices on geometries on nodes under an occurrence with a symmetry matrix
Declaration
[HandleProcessCorruptedStateExceptions]
public void RemoveSymmetryMatrices(uint occurrence = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Root occurrence for the process |
RemoveVariant(uint)
Remove a variant
Declaration
[HandleProcessCorruptedStateExceptions]
public void RemoveVariant(uint variant)
Parameters
Type | Name | Description |
---|---|---|
uint | variant | The variant to remove |
RemoveVariantChangedCallback(uint)
Declaration
public void RemoveVariantChangedCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveonRayProbeCallback(uint)
Declaration
public void RemoveonRayProbeCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RemoveonSphereProbeCallback(uint)
Declaration
public void RemoveonSphereProbeCallback(uint id)
Parameters
Type | Name | Description |
---|---|---|
uint | id |
RenameLongOccurrenceName(int)
truncate names of occurrence with too long names
Declaration
[HandleProcessCorruptedStateExceptions]
public void RenameLongOccurrenceName(int maxLength)
Parameters
Type | Name | Description |
---|---|---|
int | maxLength | Maximum name length |
ReplaceMaterial(uint, uint, OccurrenceList)
Replace a material by another everywhere it is used
Declaration
[HandleProcessCorruptedStateExceptions]
public void ReplaceMaterial(uint originalMaterial, uint newMaterial, OccurrenceList occurrences = null)
Parameters
Type | Name | Description |
---|---|---|
uint | originalMaterial | The material to replace everywhere |
uint | newMaterial | The new material to set in place of originalMaterial |
OccurrenceList | occurrences | The occurrences on which replacing the materials |
ResetPartTransform(uint)
Set all part transformation matrices to identity in a sub-tree, transformation will be applied to the shapes
Declaration
[HandleProcessCorruptedStateExceptions]
public void ResetPartTransform(uint root = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root occurrence for the process |
ResetTransform(uint, bool, bool, bool)
Set all transformation matrices to identity in a sub-tree.
Declaration
[HandleProcessCorruptedStateExceptions]
public void ResetTransform(uint root, bool recursive = true, bool keepInstantiation = true, bool keepPartTransform = false)
Parameters
Type | Name | Description |
---|---|---|
uint | root | Root occurrence for the process |
bool | recursive | If False, transformation will be applied only on the root and its components |
bool | keepInstantiation | If False, all occurrences will be singularized |
bool | keepPartTransform | If False, transformation will be applied to the shapes (BRepShape points or TessellatedShape vertices) |
ResizeTextures(ResizeTexturesInputMode, ResizeTexturesResizeMode, bool)
Resizes the textures from a selection of occurrences (resizes all textures used by these occurrences), or from a selection of textures
Declaration
[HandleProcessCorruptedStateExceptions]
public void ResizeTextures(ResizeTexturesInputMode inputMode, ResizeTexturesResizeMode resizeMode, bool replaceTextures)
Parameters
Type | Name | Description |
---|---|---|
ResizeTexturesInputMode | inputMode | Defines if the textures to resize are textures used by a selection of Occurrences, or a selection among the textures available in the scene |
ResizeTexturesResizeMode | resizeMode | Defines if the textures are resized following a ratio or following a maximum size/resolution (only textures above the defined maximum are downsized) |
bool | replaceTextures | If True, overwrites textures from the selection |
Rotate(uint, Point3, double)
Modify the local matrix of the scene node to apply a rotation
Declaration
[HandleProcessCorruptedStateExceptions]
public void Rotate(uint occurrence, Point3 axis, double angle)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Occurrence to rotate |
Point3 | axis | Axis of rotation |
double | angle | Angle of rotation |
SceneReadLock()
Lock the scene to prevent modification while allowing reading from other threads
Declaration
[HandleProcessCorruptedStateExceptions]
public void SceneReadLock()
SceneReadUnlock()
Unlock the scene for modification
Declaration
[HandleProcessCorruptedStateExceptions]
public void SceneReadUnlock()
SceneTryReadLock()
Try lock the scene to prevent modification while allowing reading from other threads
Declaration
[HandleProcessCorruptedStateExceptions]
public bool SceneTryReadLock()
Returns
Type | Description |
---|---|
bool |
SceneWriteLock()
Lock the scene from being read/write by other threads
Declaration
[HandleProcessCorruptedStateExceptions]
public void SceneWriteLock()
SceneWriteUnlock()
Unlock the scene for modification and reading
Declaration
[HandleProcessCorruptedStateExceptions]
public void SceneWriteUnlock()
Select(OccurrenceList)
Add occurrences to selection
Declaration
[HandleProcessCorruptedStateExceptions]
public void Select(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | Occurrences to add to the selection |
SeparateSelection()
Separate all polygons form their original parts into a new one
Declaration
[HandleProcessCorruptedStateExceptions]
public uint SeparateSelection()
Returns
Type | Description |
---|---|
uint |
SetAnnotationToGroup(uint, uint)
set Annotation to a Annotation Group
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetAnnotationToGroup(uint annotation, uint group)
Parameters
Type | Name | Description |
---|---|---|
uint | annotation | |
uint | group |
SetComponentOccurrence(uint, uint)
Move a component to an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetComponentOccurrence(uint component, uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | component | The component |
uint | occurrence | The occurrence |
SetCurrentVariant(uint)
Change the current variant used
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetCurrentVariant(uint variant = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | variant | The variant to enable (can be null) |
SetDefaultVariant()
Set the default variant
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetDefaultVariant()
SetLocalMatrices(OccurrenceList, Matrix4List, uint)
change the local matrices on a list of occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetLocalMatrices(OccurrenceList occurrencesIds, Matrix4List matrices, uint batchSize)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrencesIds | List of occurrences on which to set the local matrices |
Matrix4List | matrices | The occurrences' new local matrices |
uint | batchSize | Number of matrices to be set per thread. |
SetLocalMatrix(uint, Matrix4)
change the local matrix on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetLocalMatrix(uint occurrence, Matrix4 matrix)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Occurrence to set the local matrix |
Matrix4 | matrix | The new occurrence local matrix |
SetMultipleOccurrenceUserData(uint, OccurrenceList, PtrList)
Batch version of setOccurrenceUserData
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetMultipleOccurrenceUserData(uint userDataId, OccurrenceList occurrences, PtrList userDataList)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier provided by subscribeToOccurrenceUserData |
OccurrenceList | occurrences | Occurrences that will store the user data |
PtrList | userDataList | User data to store on each occurrence |
SetOccurrenceMaterial(uint, uint)
Set the material on a occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetOccurrenceMaterial(uint occurrence, uint material)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | Occurrence to set the material |
uint | material | The new occurrence material |
SetOccurrenceName(uint, string)
Returns the name of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetOccurrenceName(uint occurrence, string name)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence to get the name |
string | name | The occurrence name |
SetOccurrenceUserData(uint, uint, IntPtr)
Set or replace a userdata stored on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetOccurrenceUserData(uint userDataId, uint occurrence, IntPtr userData)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier provided by subscribeToOccurrenceUserData |
uint | occurrence | Occurrence that will store the user data |
IntPtr | userData | User data to store in the given occurrence |
SetParent(uint, uint, bool, uint, bool)
Set the parent of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetParent(uint occurrence, uint parent, bool addInParentInstances = false, uint insertBefore = 0, bool worldPositionStays = false)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
uint | parent | The parent occurrence |
bool | addInParentInstances | If True, each occurrence whose prototype is the target parent will generate a child whose prototype is the occurrence itself |
uint | insertBefore | Add before this child occurrence in the children list of the parent occurrence |
bool | worldPositionStays | If true, the parent-relative position, scale and rotation are modified such that the object keeps the same world space position, rotation and scale as before. |
SetPartMesh(uint, uint)
Add a mesh to a part (create a TessellatedShape on the part)
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetPartMesh(uint part, uint mesh)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The part component |
uint | mesh | The mesh to add to the part |
SetPartModel(uint, uint)
Add a model to a part (create a BRepShape on the part)
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetPartModel(uint part, uint model)
Parameters
Type | Name | Description |
---|---|---|
uint | part | The part component |
uint | model | The model to add to the part |
SetPartsTransforms(PartList, Matrix4List)
Set the transform matrix of each given parts
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetPartsTransforms(PartList parts, Matrix4List transforms)
Parameters
Type | Name | Description |
---|---|---|
PartList | parts | The parts to retrieve transform |
Matrix4List | transforms | The transform matrix of each part |
SetPartsTransformsIndexed(PartList, IntList, Matrix4List)
Set the transform matrix of each given parts (indexed mode)
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetPartsTransformsIndexed(PartList parts, IntList indices, Matrix4List transforms)
Parameters
Type | Name | Description |
---|---|---|
PartList | parts | The parts to retrieve transform |
IntList | indices | The transform matrix index for each parts |
Matrix4List | transforms | The list of transform matrices |
SetPivotOnly(uint, Matrix4)
Set the pivot of an occurrence to the given transformation matrix, the geometry will not be moved (warning: do not confuse with property Transform which actually move the occurrence)
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetPivotOnly(uint occurrence, Matrix4 pivot)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence to move the pivot |
Matrix4 | pivot | The new transformation matrix for the occurrence (pivot) |
SetPrototype(uint, uint)
Sets the prototype of an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetPrototype(uint occurrence, uint prototype)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
uint | prototype | The prototype |
SetPrototypes(OccurrenceList, OccurrenceList)
Sets the prototype for each given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetPrototypes(OccurrenceList occurrences, OccurrenceList prototypes)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The occurrences |
OccurrenceList | prototypes | The prototypes |
SetReferencedDataComponentParent(uint, uint)
Defines which referenced data is parent to the given component
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetReferencedDataComponentParent(uint component, uint parent)
Parameters
Type | Name | Description |
---|---|---|
uint | component | The referenced data component to alter |
uint | parent | The parent |
SetReferencedDataComponentPath(uint, string)
Defines which path the referenced data is at
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetReferencedDataComponentPath(uint component, string filePath)
Parameters
Type | Name | Description |
---|---|---|
uint | component | The referenced data component to alter |
string | filePath | The filepath |
SetSubpartMaterial(uint, uint, uint)
Set a subpart material assignment using a SubpartMaterial component
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetSubpartMaterial(uint occurrence, uint subpartIndex, uint material)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The Occurrence |
uint | subpartIndex | The subpart index |
uint | material | The material |
SetSubpartMaterials(uint, MaterialList, uint)
Set multiple subpart materials at once using a SubpartMaterial component
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetSubpartMaterials(uint occurrence, MaterialList materials, uint startIndex = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The Occurrence on which to apply the materials |
MaterialList | materials | Materials to set |
uint | startIndex | The subpart start index |
SetSubpartVariantMaterials(uint, VariantMaterialList)
set materials in variant
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetSubpartVariantMaterials(uint occurrence, VariantMaterialList variantMaterials)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence which contains variants |
VariantMaterialList | variantMaterials | List of variant and materials |
SetSubpartVariantMaterialsList(VariantList, MaterialListList)
set all the materials list in variants
Declaration
[HandleProcessCorruptedStateExceptions]
public VariantMaterialList SetSubpartVariantMaterialsList(VariantList variants, MaterialListList materialListList)
Parameters
Type | Name | Description |
---|---|---|
VariantList | variants | The part which contains variants |
MaterialListList | materialListList | The part which contains the list of material variant list |
Returns
Type | Description |
---|---|
VariantMaterialList |
SetVariantTree(uint, uint)
Set the alternative tree to use for this variant
Declaration
[HandleProcessCorruptedStateExceptions]
public void SetVariantTree(uint variant, uint tree)
Parameters
Type | Name | Description |
---|---|---|
uint | variant | The variant to modify |
uint | tree | The alternative tree to use for this variant |
Show(OccurrenceList)
Show the given occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void Show(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The list occurrences to show |
ShowOnly(OccurrenceList)
Show only the given occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void ShowOnly(OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrences | The list occurrences to show |
StartModifyAllVariants()
Call this function to to enable the modifications of all variants at the same time.
Declaration
[HandleProcessCorruptedStateExceptions]
public void StartModifyAllVariants()
SubscribeToOccurrenceUserData()
subscribe to occurrence user data. multiple different userdata can be stored on the same occurrences if subscribeToOccurrenceUserData is called multiple times
Declaration
[HandleProcessCorruptedStateExceptions]
public uint SubscribeToOccurrenceUserData()
Returns
Type | Description |
---|---|
uint |
TransferCADMaterialsOnPartOccurrences(uint)
Set all materials on part occurrences
Declaration
[HandleProcessCorruptedStateExceptions]
public void TransferCADMaterialsOnPartOccurrences(uint rootOccurrence = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | rootOccurrence | Root occurrence |
TransferMaterialsOnPatches(uint)
Take the first instance material and set it one the mesh patches
Declaration
[HandleProcessCorruptedStateExceptions]
public void TransferMaterialsOnPatches(uint rootOccurrence = 0)
Parameters
Type | Name | Description |
---|---|---|
uint | rootOccurrence | Root occurrence |
TransferSubpartMaterialsOnPatches(uint)
Assign SubpartMaterialComponent materials on the occurrence's part shapes. This might affect other Part in the scene if not singularized before.
Declaration
[HandleProcessCorruptedStateExceptions]
public void TransferSubpartMaterialsOnPatches(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence which has sub materials assigned |
Unisolate()
Exit the isolate mode
Declaration
[HandleProcessCorruptedStateExceptions]
public void Unisolate()
UnlinkPropertyToAnimation(uint, uint, string)
Unlinks a binder
Declaration
[HandleProcessCorruptedStateExceptions]
public void UnlinkPropertyToAnimation(uint animation, uint entity, string propertyName)
Parameters
Type | Name | Description |
---|---|---|
uint | animation | The Animation stack where to put a animated property |
uint | entity | The entity object to animate |
string | propertyName | The name of the property to animate |
Unselect(OccurrenceList)
Remove occurrences to selection
Declaration
[HandleProcessCorruptedStateExceptions]
public void Unselect(OccurrenceList occurrence)
Parameters
Type | Name | Description |
---|---|---|
OccurrenceList | occurrence | Occurrences to remove from the selection |
UnsetMultipleOccurrenceUserData(uint, OccurrenceList)
Batch version of unsetOccurrenceUserData
Declaration
[HandleProcessCorruptedStateExceptions]
public void UnsetMultipleOccurrenceUserData(uint userDataId, OccurrenceList occurrences)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier provided by subscribeToOccurrenceUserData |
OccurrenceList | occurrences | Occurrences that will store the user data |
UnsetOccurrenceUserData(uint, uint)
Unset the userdata stored on an occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void UnsetOccurrenceUserData(uint userDataId, uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier provided by subscribeToOccurrenceUserData |
uint | occurrence | Occurrence that will store the user data |
UnsubscribeFromOccurrenceUserData(uint)
Declaration
[HandleProcessCorruptedStateExceptions]
public void UnsubscribeFromOccurrenceUserData(uint userDataId)
Parameters
Type | Name | Description |
---|---|---|
uint | userDataId | UserData identifier to unsubscribe |
UpdateChildrenPrototypes(uint)
Update children prototypes of the given occurrence
Declaration
[HandleProcessCorruptedStateExceptions]
public void UpdateChildrenPrototypes(uint occurrence)
Parameters
Type | Name | Description |
---|---|---|
uint | occurrence | The occurrence |
UpdateRayProber(uint, Ray)
Updates the designed ray prober
Declaration
[HandleProcessCorruptedStateExceptions]
public void UpdateRayProber(uint proberID, Ray ray)
Parameters
Type | Name | Description |
---|---|---|
uint | proberID | The ray prober Id |
Ray | ray | Update the prober's ray values |
UpdateSphereProber(uint, Point3, double)
Updates the designed sphere prober
Declaration
[HandleProcessCorruptedStateExceptions]
public void UpdateSphereProber(uint proberID, Point3 sphereCenter, double sphereRadius)
Parameters
Type | Name | Description |
---|---|---|
uint | proberID | The sphere prober Id |
Point3 | sphereCenter | The new prober center |
double | sphereRadius | The new prober radius |