- position
- -
- atan
- -
- modulo
- -
- start
- -
- arc
- -
- coverage
- -
The current package lacks the newer inAngle helper, so the equivalent interval test stays visible as supported TSL.
A local-space angular predicate drives maskNode and maskShadowNode on a physical node material. This lab keeps the official inAngle() idea executable on the pinned package by composing atan(), mod(), and TSL comparisons directly.
Creating the sliced physical material and shadow receiver.
The current package lacks the newer inAngle helper, so the equivalent interval test stays visible as supported TSL.
NodeMaterial discards fragments outside the interval; the shadow hook keeps the cast shadow policy aligned.
WebGPU executes the node mask and shadow hook; WebGL2 uses a direct GLSL discard reference because the node graph is not executed there.
Every fragment is tested in the specimen's own XY coordinate space.
Signed angles become a positive interval around the local origin.
The material discards fragments outside the selected arc.
The same predicate can participate in the caster shadow pass.
The direct path keeps backend limits visible instead of pretending parity.
Adjust the interval and measure the active material submission path over thirty frames.
This is a deterministic adaptation of the official angular-slicing example: generated specimens replace the external asset, while the local-space angle, node-mask, shadow-mask, and direct-discard contracts remain executable. The pinned package's missing inAngle() export is recorded as an adapter boundary rather than hidden.
Sources: official angular-slicing example · TSL · NodeMaterial · MeshPhysicalNodeMaterial