unreal.DatasmithCADSceneElement

class unreal.DatasmithCADSceneElement(outer=None, name='None')

Bases: unreal.DatasmithSceneElementBase

Memory representation of a Datasmith scene built from a CAD format. To import the Datasmith scene, you need to Process the scene first then Import.

C++ Source:

  • Plugin: DatasmithCADImporter
  • Module: DatasmithCADImporter
  • File: DatasmithCADBlueprintLibrary.h
classmethod construct_datasmith_scene_from_file(file_path, destination_folder) → DatasmithCADSceneElement

Open a CAD format file from disk and populate the Datasmith scene. No geometry is created yet. Geometry is created on import when ImportScene is called.

Parameters:
  • file_path (str) – UDatasmith file path to open. ie: c:/MyFolder/MyFiles.udatasmith
  • destination_folder (str) – Destination of where you want the asset to be imported. ie: /Game/MyFolder1
Returns:

An empty DatasmithScene, that can be modified and can be imported.

Return type:

DatasmithCADSceneElement

destroy_scene() → None

Destroy reference to the CAD file. The Scene will no longer be available. DestroyScene is called automatically after ImportScene.

get_cad_options() → DatasmithCADImportOptions

Get the CAD specific import options that will be used during the CAD format file processing.

Returns:
Return type:DatasmithCADImportOptions
get_import_options() → DatasmithImportOptions

Get the Datasmith import options that will be used during import and the CAD format file processing.

Returns:
Return type:DatasmithImportOptions
import_scene() → DatasmithImportFactoryCreateFileResult

Import a Datasmith Scene created with ConstructDatasmithSceneFromFile.

Returns:A structure that contains the created actor or the blueprint actor depending on the options specified at the import.
Return type:DatasmithImportFactoryCreateFileResult
process_scene() → bool

NoOp method. Kept for backward compatibility. Must be documented for removal.

Returns:
Return type:bool
classmethod set_max_number_threads(max_number_threads) → None

Set the maximum number of threads to use when constructing a DatasmithCADSceneElement. All subsequent calls to ConstructDatasmithSceneFromFile will use this value for multi-threading

Parameters:max_number_threads (int32) –