import_scene_elements_from_string
Imports a data buffer.
arguments
-
"data" : String
A string containing the scene data to be imported.
-
"errors_as_warnings" : Boolean (default: true)
If true then errors produced by the import as downgraded to warnings. This can be useful for importers that return errors for issues like missing textures however still import a functional scene. True errors, like syntax errors that prevent scene parsing, will usually still produce error messages since items like the root group will not be available to create a scene from.
-
"file_extension" : String (default: null)
The type of scene data. Currently, only MetaSL shaders (".msl" or ".xmsl") are supported by this command.
-
"import_options" : Map (default: null)
The import options. All importers support the prefix and list_elements options. The name of the option is used as the key of the map. E.g.: import_options["list_elements"] = true.
return value
Import_resultA user type containing the name of the imported root group, options block, camera instance and camera. Also an array of imported elements if list_elements was set to true. The messages element will contain an array with any import warnings or messages. On successful import this will contain 1 element with code 0. Any other entries will be import warnings. Import failure is indicated by returning an error response (rather than an Import_result) which will provide an array of error messages as additional error information.