Skip to main content
Participant
Jul 6, 2023 12:10 PM UTC
Question

Export USD asset using Python

In the "Export textures" window there is a checkbox "Export USD asset".

Is it possible to enable this functionality in an export config when exporting textures using Python?

3 replies

Participant
May 8, 2025 2:59 PM UTC
export_config = {
                "defaultExportPreset": "export-preset-generator://doc-channel-normal-no-alpha",
                "exportList": [{ "rootPath": "cymourai" } ],
                "exportMeshTessellation": False,
                "exportParameters": [{
                    "filter": {},
                    "parameters": { "dilationDistance": 16, "paddingAlgorithm": "infinite" }
                }],
                "exportPath": "",
                "exportPresets": [],
                "exportShaderParams": False,
                "exportUSD": False
            }

There is a flag in the export configuration dictionary , "exportUSD". Make that True :).

You can find more python test examples in C:\Program Files\Adobe\Adobe Substance 3D Painter\resources\python\modules\automated_tests (for substance painter version 10 at least).

Hope this helps

Translate
Participant
Jan 17, 2025 7:00 AM UTC

I'd like this option as well. The local docs for 10.1.2 do not mention this possibility, but you can substance_painter.export.export_mesh() as USD. Looks like it saves as USDC. No textures, but I'll bet you could convert it to USDA and use the OpenUSD spec to build in your project textures. Non-trivial, no doubt.

Translate
Participant
May 15, 2024 10:12 PM UTC

I am also interested in a solution  for this  it seems like it hasn't been exposed in  the  json_config dict . or the documentation not updated 

Translate