Class IO
- Namespace
Methods
configureFunctionLogger
io.configureFunctionLogger(functionName, enableFunction, enableParameters, enableExecutionTime)
Parameters
exportSceneToDTPlatform
Export current scene to a local directory
io.exportSceneToDTPlatform(root=1, directory)
Parameters
rootOccurrenceIdentifier of the destination occurrence
directoryStringDirectory to export in
exportSceneToReflect
Export current scene to a reflect project
io.exportSceneToReflect(root=1, sourceName="", uid="", keepHierarchy=False, configFile="", disableDecimation=True)
Parameters
rootOccurrenceIdentifier of the destination occurrence
sourceNameStringPush source name
uidStringUID of the push, overwrite old push if it's same UID
keepHierarchyBooleanKeep hierarchy or rake tree
configFileFilePathUse existing JSON config file, discard reflect UI prompt
disableDecimationBooleanForces to disable the decimation applied on SyncObjectInstances on Reflect Server side
importSceneFromDTPlatform
Import scene from a local directory
io.importSceneFromDTPlatform(directory, root=0)
Parameters
directoryDirectoryPathDirectory to import from
rootOccurrenceIdentifier of the destination occurrence
exportScene
Export a file
io.exportScene(fileName, root=0)
Parameters
fileNameOutputFilePathPath of the file to export
rootOccurrenceIdentifier of the root occurrence to export
exportSelection
Export the selection to a file
io.exportSelection(fileName, keepIntermediaryNodes=False)
Parameters
fileNameOutputFilePathPath of the file to export
keepIntermediaryNodesBooleanIf true, intermerdiary hierarchy is kept
getExportFormats
Give all the format name and their extensions that can be exported in Pixyz
io.getExportFormats() -> core.FormatList
Returns
- FormatList
Formats that can be exported in Pixyz
getImportFormats
Give all the format name and their extensions that can be imported in Pixyz
io.getImportFormats() -> core.FormatList
Returns
- FormatList
Formats that can be imported in Pixyz
importFiles
Import files
io.importFiles(fileNames, root) -> scene.OccurrenceList
Parameters
fileNamesFilesListList of files's paths to import
rootOccurrenceIdentifier of the destination occurrence
Returns
- OccurrenceList
The root occurrences of each imported file
importPicture
Imports a picture and applies is at as a texture on a 3D plane created in the scene.
io.importPicture(filename, root) -> scene.Occurrence
Parameters
filenameFilePathPath of the file to import
rootOccurrenceIdentifier of the destination occurrence
Returns
- Occurrence
The root occurrence if defined, otherwise a new occurrence created by the importer
importScene
Import a file
io.importScene(fileName, root) -> scene.Occurrence
Parameters
fileNameFilePathPath of the file to import
rootOccurrenceIdentifier of the destination occurrence
Returns
- Occurrence
The root occurrence if defined, otherwise a new occurrence created by the importer
loadReferencedData
io.loadReferencedData(component, recursively)
Parameters
componentReferencedDataComponentThe component to load
recursivelyBoolLoad it recursively or not
splitPointCloud
io.splitPointCloud(files, outputDirectory, minVoxSize, useKDTree, aabb, density=-1)
Parameters
filesFilePathListPath of the point cloud files to process
outputDirectoryOutputDirectoryPathOutput directory
minVoxSizeDoubleSize of minimum leaves (mm)
useKDTreeBooleanIf true, uses a kd_tree, otherwise, uses an octree
aabbAABBGlobal scene aabb
densityDoublePoint cloud density (-1 to compute)