//Octane Camera/Animation Exporter
var root = ActiveSceneRoot;
var MeshName = "OBJ01frames";
var MeshNodeName = "Loader";
var OCSName = "AnimationTest.ocs";
var sDirPath = "C:\\3d\\Octane\\Scenes\\AnimationTest\\";
var sFilePath = sDirPath+MeshName+".obj";
var batFilePath = sDirPath+"OBJLoad.bat";
var Camera = "Camera" ;
var StartFrame = 1790;
var EndFrame = 1825;
var StepFrame = 1;
var PolymshOn = true;
var SurfMshOn = false;
var CurveOn = false;
var CloudOn = false;
var TessilateOn = false;
var MaterialOn = true;
var UVOn = true;
var UserNormOn = false;
//ObjExport(sFilePath, 0, 1, StartFrame, EndFrame, StepFrame, PolymshOn, SurfMshOn, CurveOn, CloudOn, 0, TessilateOn, MaterialOn, UVOn, UserNormOn);
for (counter = StartFrame; counter <= EndFrame; counter++)
SetValue("PlayControl.Current", counter, null);
sFilePath = sDirPath+MeshName + counter.toString(10)+ ".obj";
ObjExport(sFilePath, null, null, null, null, null, null, null, null, null, 0, false, null, null, false);
//Set variables for bat file
var Samples = 256;
var ExitOnEnd = true;
var Filename = "file00";
//Write BAT file
var fso = new ActiveXObject("Scripting.FileSystemObject");
var a = fso.CreateTextFile(batFilePath, true);
var counter = 0;
logmessage("Write BATfile start.");
for (counter = StartFrame; counter < EndFrame; counter++)
a.WriteLine("octane -e -m " + MeshNodeName + " -r " + sDirPath + MeshName + counter.toString(10) + ".obj -s " + Samples.toString(10) + " --output-png " + sDirPath + MeshName + counter.toString(10) + ".png " + sDirPath+OCSName);
logmessage("Write BATfile end.");
redmotion wrote:Love the UI - really nice layout! Thanks for all the hard work, face. It's nice to see Softimage getting an exporter for a renderer so early on for a change.
PS: While I was trying to write my own exporter (see below), I was considering creating an Octane material in XSI somehow (maybe a rendertree compound?). In the XSI viewports they would appear like lambert/phong materials but when you export the scene to Octane (ie: press render), it would scan the scene and use the settings on the materials to write the OCS file - meaning that everything is set in XSI and Octane ends up working as just your render view (like most other 3rd party renderers).
Would you consider something like this for a future update?
[size=85]BTW This how far I got with my own exporter (animation was what I tried to get working first), I'm glad you posted yours when you did or I would I wasted quite a few days pulling my hair out over it!:-
I know, with that technique(i mean the modified ocs), there is no limit to change anything in the scene you want.
The drawback is, is the ocs changed with future releases, it would cost more work as simply insert a new variable in the UI...
adrencg wrote:Hey Face, any thoughts on why I get this error, when just using the simple export you described early in the thread?
doca wrote:Great work face! I have few questions, all about animation.
First, when you export animation from Softimage, does Octane starts with render immediately or you have some time to adjust materials.
Second and third(those questions are no targeted directly to you, but maybe you have some info or someone from development team can answer), are we going to have any timeline in Octane and related to that, is there going to be any animatable parameters in Octane (focal depth, materials...)?
Users browsing this forum: No registered users and 3 guests