Load materials from LocalDB or file system

Forums: Load materials from LocalDB or file system
Forum for OctaneRender Lua scripting examples, discussion and support.

Load materials from LocalDB or file system

Postby Xantiah » Mon Mar 12, 2018 11:09 am

Xantiah Mon Mar 12, 2018 11:09 am
Hi,
I'm working on a solution to render images in batch mode. To do that I'm importing all geometry (multiple meshes in obj format), settings up scene, creating nodes etc. Unfortunately during that process I hit an issue :

I don't know how to load materials. I got materials stored on my disk in orbx format, but have no idea how to load them. Btw. Is it possible to load them from LocalDB?

I know it's possible to download materials from LiveDB, but that's just not something I would be keen to do (my materials are huge).

Thanks
Xantiah
 
Posts: 6
Joined: Tue Jul 11, 2017 9:42 pm
Location: Wales

Re: Load materials from LocalDB or file system

Postby roeland » Mon Apr 09, 2018 3:12 am

roeland Mon Apr 09, 2018 3:12 am
Import from ORBX or OCS/OCM file:

Code: Select all
local rootgraph = octane.nodegraph.createRootGraph(name)
octane.nodegraph.importFromFile(rootgraph, path)


Then you can copy out of the root node graph, similar to what you do with liveDB.
User avatar
roeland
OctaneRender Team
OctaneRender Team
 
Posts: 1810
Joined: Wed Mar 09, 2011 10:09 pm

Return to Lua Scripting


Who is online

Users browsing this forum: No registered users and 6 guests

Tue Apr 16, 2024 2:15 pm [ UTC ]