Scripting 3dsmax Mult-Threading toggle to run from the command line.
It seems that 3dsmax doesn't have a command line option in either 3dsmax.exe or 3dsmaxcmd.exe that allows you to choose the number of CPUs/Threads. Does anyone know a way?
I see there is a multi-thread option in the preferences/render tab, but using all CPUs or 1 is very limiting. Still, I'm trying to script a way to toggle multi-thread from command line.
I've tried using -preRenderScript in 3dsmaxcmd.exe command line. Inside the script file is the line "rendMultiThread = false". This doesn't seem to turn off the multi-threading option even though that same script works from the listener window.
I've tried calling a maxscript from 3dsmax.exe command line -U MAXScript. Also tried putting all the render commands in the maxscript file with "rendMultiThread = false" in the file above the render scripts. Always the file renders fine, but the "rendMultiThread = false" script doesn't work. Works from the listener.
So now I want to create max file that uses "rendMultiThread = false" as a callback script that runs when the maxfile is opened.
callbacks.addScript #filePostOpenProcess ("rendMultThread = false") persistant:true
When I save the file and re-open it, that callback process isn't there?
The goal is to be able to toggle multi-thread on and off with command line. Ideas?
Comments
What version of 3ds Max are
What version of 3ds Max are you using? I'd suggest using a function thats part of the AVG extension (comes with 2008, otherwise you'll need the appropriate version http://www.scriptspot.com/3ds-max-plugin-tags/avg
sysinfo.processAffinity = 1
The previous line tells windows to only let 3ds max use the first processor. So you'd just make this a .ms file and drop it into your scripts startup folder.