Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
1

Export USD asset using Python

New Here ,
Jul 06, 2023 Jul 06, 2023

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?

TOPICS
Import & Export , Scripting
234
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
May 15, 2024 May 15, 2024

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
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 16, 2025 Jan 16, 2025

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
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
May 08, 2025 May 08, 2025
LATEST
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
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines