API Reference
Complete reference documentation for all SimLab Python API classes and methods.
class simlabpy.Arguments
The Arguments class provides functionality for arguments objects.
Methods
isFound(key: str) → bool
getAsNumber(key: str) → float
getAsString(key: str) → str
getAsColor(key: str) → Color
getAsVector3(key: str) → Vector3
getAsNumberArray(key: str) → float
getAsStringArray(key: str) → str
getAsColorArray(key: str) → Color
getAsVector3Array(key: str) → Vector3
class simlabpy.BoundingBox
The BoundingBox class provides axis-aligned bounding box information.
Methods
getCenter() → Vector3
getMax() → Vector3
getMin() → Vector3
class simlabpy.Camera
The Camera class provides control over camera properties.
Methods
getFov() → float
getRoll() → float
getPosition() → Vector3
getTargetPosition() → Vector3
getUp() → Vector3
setFov(fieldOfView: float)
setRoll(roll: float)
setPosition(newPosition: Vector3)
setTargetPosition(newTargetPosition: Vector3)
setUp(newUpVector: Vector3)
class simlabpy.Color
The Color class represents RGB color values.
Methods
red() → float
green() → float
blue() → float
setRed(newR: float)
setGreen(newG: float)
setBlue(newB: float)
class simlabpy.Dictionary
The Dictionary class provides functionality for dictionary objects.
Methods
isFound(key: str) → bool
getAsNumber(key: str) → float
getAsString(key: str) → str
getAsColor(key: str) → Color
getAsVector3(key: str) → Vector3
getAsNumberArray(key: str) → List
getAsStringArray(key: str) → List
getAsColorArray(key: str) → List
getAsVector3Array(key: str) → List
set(key: str, floatValue: float)
set(key: str, stringValue: str)
set(key: str, colorValue: Color)
set(key: str, vectorValue: Vector3)
set(key: str, floatValues: List)
set(key: str, stringValues: List)
set(key: str, colorValues: List)
set(key: str, vectorValues: List)
class simlabpy.Image
The Image class provides functionality for image objects.
Methods
getPath() → str
setPath(imageFilePath: str)
class simlabpy.Light
The Light class represents light sources in the scene.
Methods
getBrightness() → float
getInnerConeAngle() → float
getOuterConeAngle() → float
getColor() → Color
getType() → str
getIESFileName() → str
getCastShadow() → bool
getBlend() → float
setBrightness(newBrightness: float)
setInnerConeAngle(newInnerConeAngle: float)
setOuterConeAngle(newOuterConeAngle: float)
setColor(newColor: Color)
setType(lightType: str)
setIESFileName(iesFilePath: str)
setCastShadow(bNewCastShadowStatus: bool)
setBlend(newLightBlend: float)
class simlabpy.Material
The Material class manages surface properties of 3D objects.
Methods
getName() → str
getDiffuseColor() → Color
getAmbientColor() → Color
getEmissiveColor() → Color
getSpecularColor() → Color
getEta() → float
getDiffuseTexture() → Texture
getBumpTexture() → Texture
getOpacityTexture() → Texture
getReflectionTexture() → Texture
getNormalTexture() → Texture
getRoughnessTexture() → Texture
getMaterialType() → str
setName(newMaterialName: str)
setDiffuseColor(newdiffuseColor: Color)
setAmbientColor(newAmbientColor: Color)
setEmissiveColor(newEmissiveColor: Color)
setSpecularColor(newSpecularColor: Color)
setEta(newEtaValue: float)
setDiffuseTexture(newDiffuseTexture: Texutre)
setBumpTexture(newBumpTexture: Texutre)
setOpacityTexture(newOpacityTexture: Texutre)
setReflectionTexture(newOpacityTexture: Texutre)
setNormalTexture(newOpacityTexture: Texutre)
setRoughnessTexture(newRoughnessTexture: Texutre)
setMaterialType(newMaterial: str)
set(newMaterial: Material)
class simlabpy.Matrix4x4
The Matrix4x4 class represents 4x4 transformation matrices.
Methods
set() → Matrix4x4
getInverse() → Matrix4x4
scale(scaleX: float, scaleY: float, scaleZ: float) → Matrix4x4
scaleInPlace(scaleX: float, scaleY: float, scaleZ: float)
multiply(multiplyMatrix: Matrix4x4) → Matrix4x4
multiplyInPlace(multiplyMatrix: Matrix4x4)
transformPosition(inputVector: Vector3) → Vector3
translate(inputVector: Vector3) → Matrix4x4
translateInPlace(inputVector: Vector3)
rotate(inputFromVector: Vector3, inputToVector: Vector3) → Matrix4x4
rotateInPlace(inputVector1: Vector3, inputVector2: Vector3)
rotateAboutVectorInPlace(angle: float, aroundVector: Vector3)
class simlabpy.Node
The Node class represents 3D objects in the scene.
Methods
getName() → str
setName(newName: str)
getVisibility() → bool
setVisibility(newVisibility: bool)
getTransform() → Matrix4x4
getWorldTransform(bIncludeLocalTransform: bool) → Matrix4x4
setTransform(transform: Matrix4x4)
getParent() → node
setParent(newParent: node)
computeBoundingBox() → BoundingBox
addAttribute(attributeName: str, attributeValue: str, attributeCategory: str, attributeSortingKey: str) → bool
addAttribute(attributeName: str, attributeValue: Node, attributeCategory: str, attributeSortingKey: str) → bool
addAttribute(attributeName: str, attributeValue: SceneState, attributeCategory: str, attributeSortingKey: str) → bool
addAttribute(attributeName: str, attributeValue: Sequence, attributeCategory: str, attributeSortingKey: str) → bool
readAttribute(attributeName: str, attributeCategory: str) → str
removeAttribute(attributeName: str)
updateAttributeValue(attributeName: str, attributeValue: str)
getAllCategoryNames() → List
findAttriubtesByCategoryName(categoryName: str) → List
getChildren() → List
rotateByDegree(angleX: float, angleY: float, angleZ: float)
setGlobalLocation(newLocation: Vector3)
class simlabpy.Path
The Path class provides functionality for path objects.
Methods
getPointOnPath(ratio: float) → Vector3
isPathClosed() → bool
isPathCircular() → bool
class simlabpy.Preferences
The Preferences class provides functionality for preferences objects.
Methods
getBool(preferenceName: str) → bool
getString(preferenceName: str) → str
getFloat(preferenceName: str) → float
set(preferenceName: str, newBooleanValue: bool)
set(preferenceName: str, newStringValue: str)
set(preferenceName: str, newFloatValue: float)
class simlabpy.RenderSettings
The RenderSettings class controls rendering parameters.
Methods
updateGUI()
stopUpdate()
resumeUpdate()
set(strSecondArgument: str)
class simlabpy.RunTime
The RunTime class provides access to runtime functionality.
Methods
setView(newCamera: Camera)
setView(topView: str)
fitAll(drawingAreaWidth: int, drawingAreaHeight: int, zoomOutFactor: float)
getPreferences(topView: str)
addReferenceFile(fileName: str, packWithVRPackage: bool)
removeReferenceFile(fileName: str, basedShortName: bool)
class simlabpy.Scene
The Scene class is the central hub for all scene operations in SimLab Composer.
Methods
reset()
remove(sceneNode: Node)
importFile(filePath: str)
importFileWithEnvironment(filePath: str)
setSavingModeToSaveAs(saveAsBool: bool)
openFile(filePath: str)
exportFile(filePath: str)
exportFile(filePath: str, sceneStates: List)
saveFile(filePath: str)
render(imagePath: str, width: int, height: int, skipOpenFolder: bool)
renderAnimation(outputDir: str, beginFrame: int, endFrame: int)
getRenderSettings() → RenderSettings
getVrSettings() → VRSettings
packTheScene(outputFilePath: str, baseFileFormat: str)
movieMaker(outputFolderPath: str, inputImagesFolderPath: str, videoQuality: str, frameRate: float, outputFormat: str, audioFilePath: str)
getNodeByGUID(guid: str) → Node
getSceneStateByGUID(guid: str) → SceneState
getSequenceByGUID(guid: str) → Sequence
bakeTexture(nodes: List, smart: bool)
bakeTextureForAnimation(nodes: List, smart: bool)
setTextureBakingSettings(minSize: int, maxSize: int, spp: int, qualityLevelTop: bool, optimizeBakingTime: bool, maxPolygonsPerObject: int)
bakeLight(smart: bool)
bakeLight(nodes: List, smart: bool)
createDoorAndCabinetsAnimation(inputFilePath: str)
getNodeByName(nodeName: str) → Node
getNodeBySubString(subString: str) → Node
getNodesBySubString(subString: str) → List
getSceneStateByName(sceneStateName: str) → SceneState
getSequenceByName(sequenceName: str) → Sequence
getMaterialByName(materialName: str) → Material
getMaterialsFromScene() → List
getMaterialFromLibrary(libraryName: str, materialName: str) → Material
captureSceneState() → SceneState
captureSceneStateFromSelection() → SceneState
setPDFTemplateFileName(pdfTemplateFilePath: str)
captureSceneImage(outputImagePath: str, outputImageWidth: int, outputImageHeight: int)
createMaterial() → Material
createCamera() → Camera
createLight() → Light
createInstanceOf(sceneNode: Node) → Node
createCopyOf(sceneNode: Node) → Node
createRoundTableCameraAnimation(rotateClockWise: bool)
exportSceneData(txtfilePath: str)
isolate(sceneNode: Node)
unisolate()
snapToGround(nodeName: str)
retainMaterialPalette(materialPaletteFilePath: str, retainType: str)
exportVrPackage(outputFile: str, packageTitle: str, packagePublisher: str, packageDescription: str, packageType: str, packageImage: str, optimize: bool) → bool
addAttribute(sceneNodeName: str, attributeName: str, attributeValue: str, attributeCategory: str) → bool
replaceObject(includes: str, doesNotInclude: str, inputFilePath: str)
replaceObject(objectNameToReplace: str, objectNameToReplaceObjectsWith: str, deleteReplaceWithObjects: bool, useOldName: bool)
replaceObject(nodeToReplace: Node, nodeToBeReplacedWith: Node, deleteReplaceWithObjects: bool, useOldName: bool)
isGUIMode() → bool
getSelectedNode() → Node
getSelectedNodes() → List
findNodesByAttribute() → List
applyReplaceRules()
mergeIdenticalMaterials()
mergeNodesOnMaterial(sceneNodes: List)
decimateMeshes(sceneNodes: List, decimationPercentage: float)
smoothNormals(sceneNodes: List)
optimizeTextures(compressMaps: bool, removeDuplicatedMaps: bool, maxMapWidth: int, maxMapHeight: int, maxEnvironmentWidth: int, maxEnvironmentHeight: int, outputDirectory: str) → bool
optimizeForVR()
replaceMaterial(sceneNode: Node, newMaterial: Material)
findGeometricalInfo(sceneNode: Node) → List
selectNodes(sceneNodes: List)
selectAllNodes()
removeAllNodes()
createBoundingBox(sceneNode: Node) → Node
ControlInteractiveChannelFunction(identifier: str, newValue: float) → bool
ControlInteractiveChannelState(identifier: str, bNewState: bool) → bool
class simlabpy.SceneState
The SceneState class captures and restores scene configurations.
Methods
apply()
isMaterialIncluded() → bool
isCameraIncluded() → bool
isVisibilityIncluded() → bool
isLightIncluded() → bool
isEnvironmentIncluded() → bool
isTransformIncluded() → bool
setMaterialIncluded(includeMaterialState: bool)
setCameraIncluded(includeCameraState: bool)
setVisibilityIncluded(includeVisibilityState: bool)
setLightIncluded(includeLightState: bool)
setEnvironmentIncluded(includeEnvironmentState: bool)
setTransformIncluded(includeTransformState: bool)
class simlabpy.Sequence
The Sequence class provides functionality for sequence objects.
This class has no public methods.
class simlabpy.Texture
The Texture class provides functionality for texture objects.
Methods
getScaleU() → float
getScaleV() → float
getOffsetU() → float
getOffsetV() → float
getPath() → str
setScaleU(newScaleU: float)
setScaleV(newScaleV: float)
setOffsetU(newOffsetU: float)
setOffsetV(newOffsetV: float)
setPath(textureMapPath: str)
class simlabpy.UI
The UI class provides functionality for ui objects.
Methods
getBool(message: str, label: str, init: bool) → bool
getString(message: str, label: str, init: str) → str
getValue(fromInt: bool, message: str, label: str, init: float) → Union[int, float]
getColor(title: str, init: Color) → str
getNode(message: str, label: str) → Node
getNodeArray(message: str, label: str) → List
getOpenFileName(title: str, init: str, filter: str) → str
getSaveFileName(title: str, init: str, filter: str) → str
class simlabpy.VRSettings
The VRSettings class provides functionality for vrsettings objects.
This class has no public methods.
class simlabpy.Vector3
The Vector3 class represents 3D vectors and points.