Author Topic: How to export mdl substance graph with python API  (Read 5364 times)


I have a python script to create mdl graph only, OK it works fine,
At the end of this script I want to create my mdl file, but :
If I use batchtools like this <batchtools.__sbscall(sbsenum.BatchToolsEnum.MDLTOOLS, 'sbs-pkg-export', .... > it don't work because of the integration of "mdltools.exe"
I can launch a'mdltools.exe  sbs-pkg-export ...... ') but the sub process parse again all the mdl directory, it's take a long time, it's a pity, because we already loaded mdl libraries to launch the script.
I just want the command behind the Substance Designer button "Export mdl module" in summary  ;)

Thank you in advance for your help.


Hi Guy,

The way to get an mdl file out of an sbs file is using the mdl tools.
It's unfortunate the performance isn't great. Let me know if this is a deal breaker for you, it might be possible to bundle up a bunch of mdl graphs in one sbs file and export them in one go instead of doing one off exports.

Hi David,

This poor performance is embarrassing for us.
Indeed, grouping all the mdl graphs and exporting them at one time would be a good compromise.
I am interested in this solution, if you can tell me how to do it and keep me informed.

Thanks in advance.

Guy Mougel.