From ac86773b04ee8a322a1bce0bc8e9e9e733b31d18 Mon Sep 17 00:00:00 2001 From: AcChosen <49845629+AcChosen@users.noreply.github.com> Date: Fri, 17 Feb 2023 06:43:16 -0500 Subject: [PATCH] Updated VRSL DMX: Creating Custom DMX Shaders (markdown) --- VRSL-DMX:-Creating-Custom-DMX-Shaders.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/VRSL-DMX:-Creating-Custom-DMX-Shaders.md b/VRSL-DMX:-Creating-Custom-DMX-Shaders.md index 51bc32b..fb20088 100644 --- a/VRSL-DMX:-Creating-Custom-DMX-Shaders.md +++ b/VRSL-DMX:-Creating-Custom-DMX-Shaders.md @@ -96,9 +96,9 @@ Shader "Unlit/VRSL-TutorialV2" //Use this for World Shaders int dmx = GetDMXChannel(); - float intensity = ReadDMX(dmx, _Udon_DMXGridRenderTexture); // 0-1 - float4 color = GetDMXColor(dmx+1); - float strobe = GetStrobeOutput(dmx + 4); + float intensity = ReadDMX(dmx, _Udon_DMXGridRenderTexture); // 0-1 output + float4 color = GetDMXColor(dmx+1); //this is the same as 3 ReadDMX() calls mapped to a float3 with 1 in the alpha channel + float strobe = GetStrobeOutput(dmx + 4); // a special function for getting strobe output, which is a square wave from 0-1 o.finalColor = (intensity * color) * strobe; o.finalColor = isDMX() ? o.finalColor : getBaseEmission();