Vectron OSL problem

Generic forum to discuss Octane Render, post ideas and suggest improvements.
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
Post Reply
rohandalvi
Licensed Customer
Posts: 170
Joined: Tue Apr 20, 2010 7:39 am

<node 'Vectron Sphere'>:1: error: Signature mismatch, expecting a shader with 1 output (_sdf)


I'm getting this error in every single vectron example.

I'm not a coder so I don't know what exactly is the issue.

regards
Rohan
Attachments
vectron.JPG
User avatar
jobigoud
OctaneRender Team
Posts: 250
Joined: Sat Aug 15, 2015 1:28 pm

Hi,
The shader should have an _sdf (signed distance function) output instead of a color.
Add this line at the top:

Code: Select all

#include <octane-oslintrin.h>
The output argument can be declared and initialized with this:

Code: Select all

output _sdf out = _SDFDEF


and in the code you need to assign the result to the .dist member:

Code: Select all

out.dist = - sdSphere(P - position);
Check the code of the default Vectron sphere for a simpler version.
Post Reply

Return to “General Discussion”