[Bf-cycles] Cycles Submission guidelines / Extending the math node

Ray Molenkamp ray at lazydodo.com
Tue May 2 22:55:41 CEST 2017


As Sergey brought up in [1] there is a need some formal
rules on what will be considered for inclusion into cycles
and what will not.

I took a few stabs [2] [3] at improving cycles, and ran
into a wall of "urgh not procedural textures again, we don't
want this" which sometimes is understandable (I admit the
osl patch was kinda 'out there'), sometimes not as much,
either way rejections are never fun and a waste of
everybody’s time.

I'm currently looking to extend the math node. I'd really
like atan2,some more comparisons, and logic operations
to be available, but I can easily think of 20+ more
functions that can be useful to people.

I have found some previous work [4] which doesn’t bode well
for my planned changes, so before I start any work:

Do I have *ANY* chance of this ever getting accepted?

Also just to answer the most likely first response 'why not
just use OSL?'

Simple reason: it's too slow. SVM runs circles around it.
I have a hexagon OSL shader (and an osl->nodegroup compiler)
and a full screen scene with this shader renders withthe
following render times:

OSL with osl script : 05:05.98
nodegroups SVM/CPU* : 01:33.71 (3.2x faster than osl)
nodegroups SVM/GPU* : 00:37.62 (8.1x faster than osl)

[*] Missing functions in SVM like floor/ceil emulated with several
math nodes

I'm willing to pay a small price for the flexibility OSL
offers but a 3x-8x increase in render time seems a little


[1] https://developer.blender.org/D2441#56790
[2] https://developer.blender.org/D1745
[3] https://developer.blender.org/D2441
[4] https://developer.blender.org/T32566

More information about the Bf-cycles mailing list