[Solved] Set startup script - Programmatically

nategovannategovan Posts: 35

I know that you can go to Edit>Preferences (or Daz Studio>Preferences for the Mac), in the Startup tab check Load File, click the button nexdt to it, Browse, and select your script, but can we do this prorammatically?

I can't see anything in the API that would allow me to do this, I just wanted to check.

Thanks

 

Post edited by nategovan on

Comments

  • OmnifluxOmniflux Posts: 359
    App.getContentMgr().startupScene = 'E:/MyStartupScene.duf';DzAppSettings().setBoolValue ('LoadStartupScene', true);

     

  • nategovannategovan Posts: 35

    Perfect, thanks

  • What are you doing with this? Since DS has only one start up script it would be important to make sure that users were aware of any chnages to be made, if it is for something to be shared or sold.

  • nategovannategovan Posts: 35

    Hi, all good comments. I'm creating my own rendering queue for multi render, multi camera scenes with animations etc (eg, indepedent config), once / if it proves useful, then I would consider releasing it as a product. I've seen the render queue from ManFriday, but there are a few significant features that I would like and its simple enough for me to code.

    In this specific context, I have created a customer initiated script that adds itself as the startup process so that between restarts of Daz (and therefore clearing of gpu VRAM), the script is able to resume the correct loading of scenes, rendering settings, rendering etc. After the rendering queue has finished, it also reverts the startupScene config back to what it was initially set as. I have a separate golang app that takes care of restarting / turning off the computer etc.

  • You could perhaps use an instance to launch DS with the desired config, rather than editing the startup script (which might not get reverted in the event of a crash). Daz Studio Pro 4.12 - instances

  • nategovannategovan Posts: 35

    That could work even better, but in the case of a switch off of the computer and a manual (standard) launch of DAZ, I would still like to be greeted with the render results, so a vanilla launch config would be useful. But I'll take it into consideration, thanks for the input.

  • Is this startup script location stored in a file in the directory somewhere that I can change externally with a python script for instance?

Sign In or Register to comment.