Latest commit 11341a6
Mar 10, 2016
…ters. This adds a new ShadingSystem attribute, "userdata_isconnected". The default of 0 is the old/usual behavior that most applications want. However, setting this attribute to 1 will cause the OSL built-in function isconnected(paramname) to return 1 not only for connected parameters, but also for parameters that may be bound to userdata (i.e., those that have lockgeom=0). The use case for this involves a renderer implementation that can mix C++ and OSL nodes within a shading group. The outputs exported by the C++ nodes propagate their values to the downstream node via get_userdata(), hijacking the mechanism that is generally used geometric primitive variable interpolation. But from the point of view of the downstream node, they should semantically appear to be a connection.