# class BoneSettings

Settings for the Simplygon Reduction/Remeshing classes With the BoneSettings object, the user can setup all the parameters for how the BoneLOD processor should simplify the links between geometries and bones. Bones can be un-linked from the geometry either with a set ratio or depending on a selected pixel size on screen.

# Properties

Property Description
BoneReductionTargetBoneCount The desired bone count. The range is 0->inf.
BoneReductionTargetBoneCountEnabled Enable bone count as a reduction target. The reducer will stop when the set bone count has been reached.
BoneReductionTargetBoneRatio The desired bone reduction ratio. The range is 0->1.
BoneReductionTargetBoneRatioEnabled Enable bone ratio as a reduction target. The reducer will stop when the set bone-ratio has been reached.
BoneReductionTargetMaxDeviation The MaxDeviation value, the maximum surface-deviation between the reduced geometry and the original.
BoneReductionTargetMaxDeviationEnabled Enable max deviation as a reduction target. The reducer will stop when the set max deviation has been reached.
BoneReductionTargetOnScreenSize The OnScreenSize value, the maximum surface-deviation between the reduced geometry and the original.
BoneReductionTargetOnScreenSizeEnabled Enable on screen size as a reduction target. The reducer will stop when the set on screen size has been reached.
BoneReductionTargetStopCondition The stop condition for the bone reducer. Any: the reducer will stop when any single one of the set reduction targets have been reached. All: the reducer will stop when all enabled reduction targets have been set.
LimitBonesPerVertex Decides whether unused bones should be removed.
LockBoneSelectionSetID The ID of the selection set that contains all of the bones that will be locked, and cannot be removed in the BoneLOD process. If a bone is locked, all its ancestors will be locked also. If the ID is -1, then no bones are selected.
LockBoneSelectionSetName The name of the selection set that contains all of the bones that will be locked, and cannot be removed in the BoneLOD process. If a bone is locked, all its ancestors will be locked also. If both name and id are set for the locked selection set, the name will be used.
MaxBonePerVertex Decides the maximum limit of how many bones can be connected to each vertex. If for example set to 1, then each vertex will only be linked to 1 bone.
RemoveBoneSelectionSetID The ID of the selection set that contains all of the bones that will be forced to be removed in the BoneLOD process, UNLESS they are locked. If a bone is set to be removed, all its descendants will be removed also. If both name and id are set for the remove selection set, the name will be used.
RemoveBoneSelectionSetName The name of the selection set that contains all of the bones that will be forced to be removed in the BoneLOD process, UNLESS they are locked. If a bone is set to be removed, all its descendants will be removed also. If both name and id are set for the remove selection set, the name will be used.
RemoveUnusedBones Decides whether unused bones should be removed.
UseBoneReducer Enables or disables the bone reduction processing that actually removes bones. Even with this flag off, the bones per vertex can still be limited.

# Methods

Method Description
GetBoolParameter Get a named parameter boolean value.
GetClass Get the name of the BoneSettings class.
GetDoubleParameter Get a named parameter floating point value.
GetErrorString Returns a string describing the error that was found the last time ValidateSettings was performed.
GetIntParameter Get a named parameter integer value.
GetStringParameter Get a named parameter string value.
GetUIntParameter Get a named parameter unsigned integer value.
IsA Returns true if BoneSettings is a or is a descendant of the class named as the type parameter.
IsNull Returns true if the BoneSettings object is invalid.
SetBoneReductionTargets Set bone reduction targets and stop condition used in the bone reduction.
SetBoolParameter Set a named parameter boolean value.
SetDoubleParameter Set a named parameter floating point value.
SetIntParameter Set a named parameter integer value.
SetStringParameter Set a named parameter string value.
SetUIntParameter Set a named parameter unsigned integer value.
SetValidateParameterNames Set if parameter names should be validated or not. Parameters that previously do not exist will generate and error if validation is enabled and be allowed if validation is disabled.
ToJSON Get settings as JSON for debugging purposes.
ValidateSettings Validates the current settings values.

# Static methods

Method Description
IsClassA Returns true if the class is a or is a descendant of the class named as the type parameter.
SafeCast SafeCast makes sure the input object is of a class that can be cast into spBoneSettings, and if this is the case, returns the object cast into spBoneSettings.

# Properties details

# BoneReductionTargetBoneCount

The desired bone count. The range is 0->inf.

    # BoneReductionTargetBoneCountEnabled

    Enable bone count as a reduction target. The reducer will stop when the set bone count has been reached.

      # BoneReductionTargetBoneRatio

      The desired bone reduction ratio. The range is 0->1.

        # BoneReductionTargetBoneRatioEnabled

        Enable bone ratio as a reduction target. The reducer will stop when the set bone-ratio has been reached.

          # BoneReductionTargetMaxDeviation

          The MaxDeviation value, the maximum surface-deviation between the reduced geometry and the original.

            # BoneReductionTargetMaxDeviationEnabled

            Enable max deviation as a reduction target. The reducer will stop when the set max deviation has been reached.

              # BoneReductionTargetOnScreenSize

              The OnScreenSize value, the maximum surface-deviation between the reduced geometry and the original.

                # BoneReductionTargetOnScreenSizeEnabled

                Enable on screen size as a reduction target. The reducer will stop when the set on screen size has been reached.

                  # BoneReductionTargetStopCondition

                  The stop condition for the bone reducer. Any: the reducer will stop when any single one of the set reduction targets have been reached. All: the reducer will stop when all enabled reduction targets have been set.

                    # LimitBonesPerVertex

                    Decides whether unused bones should be removed.

                      # LockBoneSelectionSetID

                      The ID of the selection set that contains all of the bones that will be locked, and cannot be removed in the BoneLOD process. If a bone is locked, all its ancestors will be locked also. If the ID is -1, then no bones are selected.

                        # LockBoneSelectionSetName

                        The name of the selection set that contains all of the bones that will be locked, and cannot be removed in the BoneLOD process. If a bone is locked, all its ancestors will be locked also. If both name and id are set for the locked selection set, the name will be used.

                          # MaxBonePerVertex

                          Decides the maximum limit of how many bones can be connected to each vertex. If for example set to 1, then each vertex will only be linked to 1 bone.

                            # RemoveBoneSelectionSetID

                            The ID of the selection set that contains all of the bones that will be forced to be removed in the BoneLOD process, UNLESS they are locked. If a bone is set to be removed, all its descendants will be removed also. If both name and id are set for the remove selection set, the name will be used.

                              # RemoveBoneSelectionSetName

                              The name of the selection set that contains all of the bones that will be forced to be removed in the BoneLOD process, UNLESS they are locked. If a bone is set to be removed, all its descendants will be removed also. If both name and id are set for the remove selection set, the name will be used.

                                # RemoveUnusedBones

                                Decides whether unused bones should be removed.

                                  # UseBoneReducer

                                  Enables or disables the bone reduction processing that actually removes bones. Even with this flag off, the bones per vertex can still be limited.

                                    # Methods details

                                    # GetBoolParameter

                                    Get a named parameter boolean value.

                                      # GetClass

                                      Get the name of the BoneSettings class.

                                        # GetDoubleParameter

                                        Get a named parameter floating point value.

                                          # GetErrorString

                                          Returns a string describing the error that was found the last time ValidateSettings was performed.

                                            # GetIntParameter

                                            Get a named parameter integer value.

                                              # GetStringParameter

                                              Get a named parameter string value.

                                                # GetUIntParameter

                                                Get a named parameter unsigned integer value.

                                                  # IsA

                                                  Returns true if BoneSettings is a or is a descendant of the class named as the type parameter.

                                                    # IsNull

                                                    Returns true if the BoneSettings object is invalid.

                                                      # SetBoneReductionTargets

                                                      Set bone reduction targets and stop condition used in the bone reduction.

                                                        # SetBoolParameter

                                                        Set a named parameter boolean value.

                                                          # SetDoubleParameter

                                                          Set a named parameter floating point value.

                                                            # SetIntParameter

                                                            Set a named parameter integer value.

                                                              # SetStringParameter

                                                              Set a named parameter string value.

                                                                # SetUIntParameter

                                                                Set a named parameter unsigned integer value.

                                                                  # SetValidateParameterNames

                                                                  Set if parameter names should be validated or not. Parameters that previously do not exist will generate and error if validation is enabled and be allowed if validation is disabled.

                                                                    # ToJSON

                                                                    Get settings as JSON for debugging purposes.

                                                                      # ValidateSettings

                                                                      Validates the current settings values.

                                                                        # Static methods details

                                                                        # IsClassA

                                                                        Returns true if the class is a or is a descendant of the class named as the type parameter.

                                                                          # SafeCast

                                                                          SafeCast makes sure the input object is of a class that can be cast into spBoneSettings, and if this is the case, returns the object cast into spBoneSettings.