assets_xml¶
-
class
assets_xml.
XmlSceneBuilder
(parent_xml, nr_brain=None, load_method='reference')¶ -
build_tree
(elem, par=None)¶
-
create_asset
(elem_dict)¶
-
get_or_create
(ast_name, ref_file, x_form)¶
-
parse_create
()¶
-
-
assets_xml.
duplicate_asset
(asset)¶ Duplicate referenced asset as a maya instance
Parameters: asset – Returns: the resulted asset instance
-
assets_xml.
export_sgXml
(root, xml_file, time_range=(1, 1), assemblies=None, components=None, references=None)¶
-
assets_xml.
maya_to_xml
(ast_root, xml_file, time_range=(1, 1))¶ Write a katana ScenegraphXml file for the given asset root
Parameters: - ast_root –
- xml_file –
- time_range –
Returns:
-
assets_xml.
update_assets_locators
(ast_locators)¶
-
assets_xml.
write_sgXml
(asset_root, xml_file)¶
Write ‘mat’ tags as katana xml attributesFile
Parameters: - asset_root –
- xml_file –
- usd_locations – when True, the locations in the generated xml refers to the transform node rather than the shape node to respect that USD merges the transform and shape as one object called like the transform name
Returns:
-
assets_xml.
xml_to_maya
(xml_file, nr_brain=None, load_method='reference')¶ Loads and places all the assets found in the given scenegraphXml
Parameters: - xml_file –
- load_method – reference|import defines how the assets will be loaded in the scene
- nr_brain – in instance of initialized nreal_brain module, if not provided, the current session ticket will be used instead
Returns: a list of the loaded assets