[Bf-codereview] OSL Script Node (issue 6506102)

lukas.toenne at gmail.com lukas.toenne at gmail.com
Wed Sep 12 09:53:18 CEST 2012


Forgot to add a few KNOWN ISSUES/questions:

* When compiling a shader to a .oso file, the OSL ShadingSystem does not
recognize it at first. The current solution is to simply recreate the
ShadingSystem when a shader has been compiled. There may be better ways
to do this, but this seems to work fine for now. However:

* The flag for restarting the shading system is currently a global
variable! The node Compile operator does not have direct access to the
render engine, so the usual python argument method does not work. Should
be simple to fix, but not sure how to do it right.

* boost::python is not used anywhere else beside the cycles addon. It
might be desirable to avoid this extra dependency, but it has definite
advantages for API generation in terms of code size. Since we already
link to boost in cycles this seems to be an acceptable addition.

* Already noted above: Script Text needs to be saved on disk to be
usable by the OSL compiler. Would it be desirable to have on-the-fly
compiling of purely .blend texts? Storing to temporary files could work.

http://codereview.appspot.com/6506102/


More information about the Bf-codereview mailing list