How to do Stencils?
Forum rules
Please add your OS and Hardware Configuration in your signature, it makes it easier for us to help you analyze problems. Example: Win 7 64 | Geforce GTX680 | i7 3770 | 16GB
Please add your OS and Hardware Configuration in your signature, it makes it easier for us to help you analyze problems. Example: Win 7 64 | Geforce GTX680 | i7 3770 | 16GB
- SamCameron
- Posts: 162
- Joined: Sun Jan 02, 2011 12:58 pm
Hi people, I'm new with Octane Render, and I would like to know how to do an stencil in Octane, I tried with nodes but I don't get the result I want, what I want is to have a material with two layers on it, one textured image with it's own colors and desings and in the surrounding of the material the base material, I'm not sure if you get my idea, anyway any suggestion or comment is more than welcome, thanks in advance.
You can do as follow:
- create a node 'clamp texture' (textures->mappings->clamptexture)
- load a black & white version of your texture as a floatimage
- create a node 'material mix', link the clamp texture to the 'amount' input
- link your 2 materials (base and textured) to the 2 inputs of the mix
- if result is inverted, either set 'invert' to true in mix or switch inputs
If you plan to have multiple stencils on same object, you must probably assign them different materials so you have different inputs in your obj. In the example below, you can see Mat_Steel is used twice, once alone and once as a base material with a stencil.
Yoyoz
- create a node 'clamp texture' (textures->mappings->clamptexture)
- load a black & white version of your texture as a floatimage
- create a node 'material mix', link the clamp texture to the 'amount' input
- link your 2 materials (base and textured) to the 2 inputs of the mix
- if result is inverted, either set 'invert' to true in mix or switch inputs
If you plan to have multiple stencils on same object, you must probably assign them different materials so you have different inputs in your obj. In the example below, you can see Mat_Steel is used twice, once alone and once as a base material with a stencil.
Yoyoz
Desktop: Ubuntu 13.04 x64 - i7-3770K @ 3.5GHz - 32GB DDR3 - GTX670 2048MB
Laptop: Linux Mint 11 x64 - i7-2860QM @ 2.5GHz - 16GB DDR3 - Quadro 3000M 2GB
Software: NVidia 319.12 - Cuda 4.2.9 - Blender 2.66a
Laptop: Linux Mint 11 x64 - i7-2860QM @ 2.5GHz - 16GB DDR3 - Quadro 3000M 2GB
Software: NVidia 319.12 - Cuda 4.2.9 - Blender 2.66a
- SamCameron
- Posts: 162
- Joined: Sun Jan 02, 2011 12:58 pm
Thank you very much, I really apreciated , this workflow seems a little bit complex for such a standard feature, in other engines you don't need to tweak so much to have the same result, speacially if Octane Render doesn't import materials from the main 3d program, all that imports is just the meshes without the corresponding materials or textures so once I import the model from my main app with textures and everything right into Octane Render I need then to re-assing materials, create materials, assing textures all over again, it's kind of time wasting.
Thanks, I'm not sure this is the only approach, but this is what I figured out by playing around. May be someone else has a better solution 
I only have two problems with this workflow at the moment:
- if I add a material in Blender and re-export/import, the nodes may be wrongly reconnected. I thinks this will be fxed with next beta.
- the textures are only linked if I export to Wavefront, but not if using the addon. But this script is not even supposed to work on 2.56 so nobody has to be blamed.
I also have to admit I like to play with the materials in Octane, even if I'm an absolute beginner

I only have two problems with this workflow at the moment:
- if I add a material in Blender and re-export/import, the nodes may be wrongly reconnected. I thinks this will be fxed with next beta.
- the textures are only linked if I export to Wavefront, but not if using the addon. But this script is not even supposed to work on 2.56 so nobody has to be blamed.
I also have to admit I like to play with the materials in Octane, even if I'm an absolute beginner

Desktop: Ubuntu 13.04 x64 - i7-3770K @ 3.5GHz - 32GB DDR3 - GTX670 2048MB
Laptop: Linux Mint 11 x64 - i7-2860QM @ 2.5GHz - 16GB DDR3 - Quadro 3000M 2GB
Software: NVidia 319.12 - Cuda 4.2.9 - Blender 2.66a
Laptop: Linux Mint 11 x64 - i7-2860QM @ 2.5GHz - 16GB DDR3 - Quadro 3000M 2GB
Software: NVidia 319.12 - Cuda 4.2.9 - Blender 2.66a
- msciwiarski
- Posts: 44
- Joined: Wed Nov 17, 2010 1:56 pm
- Location: Poland
Yes it's very frustrating.. I've spent a lot of time making all node connection for my car model.. and I wanted to add one more object and material in blender.. After reexporting to octane .. all may work has goneyoyoz wrote:
I only have two problems with this workflow at the moment:
- if I add a material in Blender and re-export/import, the nodes may be wrongly reconnected. I thinks this will be fxed with next beta.
What is the algorithm of imports for materials in Octane ?? random ??

arghhh....

Hardware: Core2Quad Q9650, Asus P5Q Deluxe, GeForce GTX580
Software: Windows 7 Ultimate x64, Sketchup 8, Blender 2.56, Octane 2.4
Software: Windows 7 Ultimate x64, Sketchup 8, Blender 2.56, Octane 2.4
I have found that the following workaround has worked for me, but I have no idea if it is a universal fix or not.
After I have added a new material in Blender and exported, I will then open up the MTL file and search for the new material and put it at the end of the file. It seems that Octane is looking for materials in a certain order upon relinking.
This process worked for my last project. I was rendering a luxury car but I wasn't totally happy with using an HDRI, so I later added four new mesh lights within Blender. I gave each new mesh light a different material (so that I could control them individually within Octane). Once I exported the mesh, I then opened up the MTL file and moved the four new mesh light materials to the end of the file. Once I relinked in Octane, the new mesh lights showed up properly (along with everything else).
After I have added a new material in Blender and exported, I will then open up the MTL file and search for the new material and put it at the end of the file. It seems that Octane is looking for materials in a certain order upon relinking.
This process worked for my last project. I was rendering a luxury car but I wasn't totally happy with using an HDRI, so I later added four new mesh lights within Blender. I gave each new mesh light a different material (so that I could control them individually within Octane). Once I exported the mesh, I then opened up the MTL file and moved the four new mesh light materials to the end of the file. Once I relinked in Octane, the new mesh lights showed up properly (along with everything else).
- msciwiarski
- Posts: 44
- Joined: Wed Nov 17, 2010 1:56 pm
- Location: Poland
Hi GeoPappas,
Thanks for the tip,, I will try it today..
But, IMO sorting the materials by alphabetic order in Octane would be very helpfull. Finding the materials in Graph editor by the material name would be easier... At this moment I have about 60 materials and 1st material is "Window_glass", 2nd is "Tyre", 3rd is "Lamp" etc... they are not sorted...
Cheers
Michal
Thanks for the tip,, I will try it today..
But, IMO sorting the materials by alphabetic order in Octane would be very helpfull. Finding the materials in Graph editor by the material name would be easier... At this moment I have about 60 materials and 1st material is "Window_glass", 2nd is "Tyre", 3rd is "Lamp" etc... they are not sorted...
Cheers
Michal
Hardware: Core2Quad Q9650, Asus P5Q Deluxe, GeForce GTX580
Software: Windows 7 Ultimate x64, Sketchup 8, Blender 2.56, Octane 2.4
Software: Windows 7 Ultimate x64, Sketchup 8, Blender 2.56, Octane 2.4