embree+OSL+alembic
embree+OSL+alembic
Not much of rendering algorithms to see in here, more as an engineering exercise I connected embree, OSL (+OpenImageIO) and Alembic. The Octopus is a sample file from Alembic, its surface is an OSL shader and the velvet cloth is from embree's crown demo scene. My plan is to turn this into a more full featured renderer, adding differentials, MIS, motion blur, etc. Don't pay too much attention to the fps, this is a laptop from 2007.
Re: embree+OSL+alembic
Wow, that's a lot faster than my path tracer.
Re: embree+OSL+alembic
Nice OSL shader, is it one of the OSL distribution ? Can you share ?
Thanks
Thanks
Re: embree+OSL+alembic
The shader is really very simple, it's just using turbulence to blend between diffuse and phong:
Code: Select all
#include "nodes.h"
surface
defaultShader
[[ string description = "default material" ]]
(
float Kd = 1
[[ string description = "Diffuse scaling",
float UImin = 0, float UIsoftmax = 1 ]],
color Cs = 1
[[ string description = "Base color",
float UImin = 0, float UImax = 1 ]]
)
{
color mixture = turbulence(P * 0.04, 8);
Ci = Kd * Cs * diffuse(N) * mixture + (1-mixture) * phong(N, 13);
}
Re: embree+OSL+alembic
Nice image and great performance! How easy is it to integrate OSL into a project? I currently have my own extremely basic shader/closure system, but I would be interested in checking out OSL if it is simple to set up.
And more random question: it seems that the main target of OSL is x86, has anyone had a go at porting the shading and/or closure runtime to a GPU, and willing to share any thoughts?
And more random question: it seems that the main target of OSL is x86, has anyone had a go at porting the shading and/or closure runtime to a GPU, and willing to share any thoughts?
Re: embree+OSL+alembic
OSL is pretty easy to integrate. Depending on your OS, getting all the dependencies in order is a challenge, it's fairly simple with a Unix package manager, but trickier if you're on Windows or want to do a dependency free build on OS X (which mine is).apaffy wrote:Nice image and great performance! How easy is it to integrate OSL into a project? I currently have my own extremely basic shader/closure system, but I would be interested in checking out OSL if it is simple to set up.
OSL's use of shaders and BSDFs actually fits nicely on embree's material/BSDF structures. I guess we're all just copying PBRT these days

Re: embree+OSL+alembic
Thanks for the shader, you're right it is quite simple but beautiful,
Will you open-source it ? It will be great to have a ".exe" renderer based on OSL... as reference
Will you open-source it ? It will be great to have a ".exe" renderer based on OSL... as reference

Re: embree+OSL+alembic
I have no plans for publishing it at this point - it's still full of half-broken or incomplete features and hacks. But I'll be happy to answer any questions about integrating OSL (can't say much about Alembic, I only have poly mesh import working so far, am still figuring out the rest).
Doesn't Blender's Cycles support OSL? That should be a nice reference.
Doesn't Blender's Cycles support OSL? That should be a nice reference.
Re: embree+OSL+alembic
Thanks,
Not sure that Cycles support OSL yet, it sounds that (correct me please if I'm wrong) that the only one to (partially) support OSL is Spectral Studio (and available for download). The reason I ask this is that I will be interested to find a "downloadable" renderer, even if simple that support the OSL implementation of Sony (Spectral Studio has its own back-end for CPU and GPU support).
Thx
Not sure that Cycles support OSL yet, it sounds that (correct me please if I'm wrong) that the only one to (partially) support OSL is Spectral Studio (and available for download). The reason I ask this is that I will be interested to find a "downloadable" renderer, even if simple that support the OSL implementation of Sony (Spectral Studio has its own back-end for CPU and GPU support).
Thx
Re: embree+OSL+alembic
If you're on Mac OS X, I can provide you with a binary, as long as you don't hold me accountable for any bugs in it 
I wouldn't call it a reference implementation, since I'm not supporting displacement/bump shaders and there's something wrong with transmitted rays too.

I wouldn't call it a reference implementation, since I'm not supporting displacement/bump shaders and there's something wrong with transmitted rays too.