Skip to main content
Participant
April 16, 2023
Answered

Run Scripts from Command Line

  • April 16, 2023
  • 1 reply
  • 1068 views

Hello everyone,

I have been using Adobe Substance 3D Sampler for a while now and I have been wondering if there is a way to write scripts for it from the command line and execute them. I have been searching for information on this topic but I have not found any clear answers yet.

I think that being able to write scripts from the command line would be very useful, especially for automating repetitive tasks or for batch processing multiple images. It would save a lot of time and effort in the long run.

Does anyone know if it is possible? If so, could you please post some ressources or tips? 🙂

Thank you in advance for your help!

This topic has been closed for replies.
Correct answer Baptiste_Substance_3D

Mac is always special.

You need open Adobe Substance 3D Sampler.app with "Show package content" to use the real .app

Here is the command:

/Applications/Adobe\ Substance\ 3D\ Sampler/Adobe\ Substance\ 3D\ Sampler.app/Contents/MacOS/Adobe\ Substance\ 3D\ Sampler --run-script

1 reply

Baptiste_Substance_3D
Community Manager
Community Manager
April 17, 2023

Hello,

 

You can develop scripts for Sampler to automate tasks or batch operations:

https://substance3d.adobe.com/documentation/sadoc/create-a-script-with-python-234455544.html

The Python API documentation is available directly from Sampler > Help > Python API documentation

 

From the command line, you can launch your script like this:

"C:\Program Files\Adobe\Adobe Substance 3D Sampler\Adobe Substance 3D Sampler.exe" --run-script <script.py>

 

Thanks

Participant
April 17, 2023

Hey,

 

thank you so much! Is there any way to do that on Mac too? I adjusted the path (currently in Applications) 

 

"Adobe\ Substance\ 3D\ Sampler/Adobe\ Substance\ 3D\ Sampler.app" --run-script random_seed_variations.py

 

but I still get an error message "command not found"...

 

Thanks in advance!

Baptiste_Substance_3D
Community Manager
Baptiste_Substance_3DCommunity ManagerCorrect answer
Community Manager
April 17, 2023

Mac is always special.

You need open Adobe Substance 3D Sampler.app with "Show package content" to use the real .app

Here is the command:

/Applications/Adobe\ Substance\ 3D\ Sampler/Adobe\ Substance\ 3D\ Sampler.app/Contents/MacOS/Adobe\ Substance\ 3D\ Sampler --run-script