I have been attempting to prevent a write to the z-buffer for a specific object in three.js.
This is what my code currently looks like:
mesh.onBeforeRender = function(renderer){renderer.context.depthMask(false)};
mesh.onAfterRender = function(renderer){renderer.context.depthMask(true)};
It sounds straightforward, but...
The renderer argument seems to be missing - it should be the first element in the arguments list.
In fact, the arguments appear to be an empty array.
Additionally, onAfterRender
doesn't seem to be called at all.
However, when I look at the source code for renderObjects
, everything appears to be in order.
What could I be overlooking???