AWS Thinkbox Discussion Forums

Please support to defined OutputFilename1 in SMTDSettings

I don’t see a way to add OutputFilename1 with SMTDSettings in 3dsMax.
Could u guys add this?

OutputFilename# is not supported directly by SMTDSettings. Not even OutputFilename0 is directly accessible, the OutputFilename# keys are populated during job submission based on the output filenames of the current renderer.

Can you explain how you plan to use them if there were a way to set any of them?

Btw, you can always add more values to the job file from a custom script - just open the already created file, figure out what the highest value of the counter is for the OutputFilename, increment by one, and output whatever path you need. Close the file, and call the submit function. No need for SMTDSettings to explicitly support something for it to be part of the submission.

Well… problem is that we are piggy backing Thinkbox SubmitTo DEadline script.
So… Actual submission happens through Thinkbox script.
I can hack the shipping script. But, then when you guys update your script I need to hack again and again.

Ok, please explain what you would like to see added. I cannot add OutputFilename1 because that can be used already by a Render Element or some other output. What exactly do you want it for? Do you just want the ability to show additional custom output folders in the Monitor’s right click menu > Job Output menu for navigation/viewing purposes? Or does that path have to do something else within the context of the rendering?

I can add the ability to append any number of additional paths to the Monitor Job Output menu via SMTDSettings, but they will have indices based on whatever SMTD’s highest index was when it processed the actual render output paths. So if SMTD already had 7 paths numbered from 0 to 6, and you had an array of 3 additional paths in a new SMTDSettings.AdditionalOutputPaths property, they would be output as OutputFilename7, OutputFilename8 and OutputFilename9. Does that sound like what you are after?

YES! this is what I want."

Sounds perpect.

If I ask a little bit more, it would be great to have a generic customJobInfoOptions peoperty with array of array input #(#(Optionname, Value))
So I can set something like SMTDSetting.customJobInfoOptions = #(#(“OutputFilename1”, “c:…” ))

Then I would not need to bug you everytime :wink:

Sounds like a good idea, will add it today.

Any update?

I have added it to my local build.
Will have to push it into the next version, and possibly back-port to v9 so you can use it immediately.
I can provide you with the changes here so you can modify your files, and later when it becomes part of an official release your scripts will still work…

perfect.
I love to get asap.
I just need to throw in repo. I guess.

Correct. Here are the necessary changes:

  • Go to Repository\submission\3dsmax\Main\
  • Make a backup copy of the file SubmitMaxToDeadline_Functions.ms just in case.
  • Open the file SubmitMaxToDeadline_Functions.ms for editing
  • Add the following two properties to the struct SMTDSettingsStructure () definition, and don’t forget to add a comma behind the previous last entry…

ExtraOutputFilenames = #(), -- for 3rd party developers, populate with filenames to add to the job's right click menu in the Monitor. Will be indexed automatically as OutputFilename# ExtraPluginInfoKeys = #() -- for 3rd party developers, populate with #(Key, Value) sub-arrays to write custom values to the Plugin Info file. )

  • Locate the following code block:

local limitGroups = "" --initialize Limits to empty string local limitGroupsToUseArray = for i in SMTDSettings.LimitGroupsToUse collect i

  • Add the following loop before it:

[code] for aFile in SMTDSettings.ExtraOutputFilenames do
(
format “OutputFilename%=%\n” outputFilenameIndex aFile to:submitInfoFile
outputFilenameIndex += 1
)

			local limitGroups = ""	--initialize Limits to empty string
			local limitGroupsToUseArray = for i in SMTDSettings.LimitGroupsToUse collect i[/code]
  • Now locate the following codeblock:
				--EXPORT ADVANCED RENDERING SETTINGS ENDS HERE
				
				Close JobInfoFile
				true
			)
			else
				false
		),
  • Insert the following for loop in it:
				--EXPORT ADVANCED RENDERING SETTINGS ENDS HERE
				
				for aKeyPair in SMTDSettings.ExtraPluginInfoKeys where isKindOf aKeyPair Array and aKeyPair.count == 2 do
				(
					format "%=%\n" aKeyPair[1] aKeyPair[2] to:JobInfoFile
				)				

				Close JobInfoFile
				true
			)
			else
				false
		),
  • Save the modified file.
  • Launch SMTD in 3ds Max - now you have the two new properties, defaulting to #().
  • You can set them via your own MAXScript to anything, for example

SMTDSettings.ExtraOutputFilenames = #("c:/temp/test/something.exr") SMTDSettings.ExtraJobInfoKeys = #(#("Bobo","Awesome"), #("Answer",42), #("Bad Value"), #("Too Many Values", 1,2,3), 5)

  • If you submit a job via SMTD or your own script using SMTDFunctions, your submission will contain an additional output filename in the Monitor’s Job Output right click menu, and two additional keys in the Plugin configuration, because the 3rd entry has no value, the 4th entry has too many, and the 5th entry is not an array of two values!

  • Note that the values will persist until SMTD is relaunched, so you would have to ensure both properties are reset to #() when you don’t want them included (e.g. after your submission script finishes, you can reset them back to #()).

Worked beautifully!
THANKS!

Privacy | Site terms | Cookie preferences