Overview
TheVRStageLighting_AudioLink_Static class provides AudioLink integration for stage lighting fixtures in VRSL. It allows fixtures to react to audio in real-time by responding to different frequency bands, with support for color chords, theme colors, and texture sampling.
This script is designed for fixtures that react to music rather than DMX control, making it ideal for dynamic, music-driven lighting setups.
Namespace: VRSLInherits from:
UdonSharpBehaviour (in VRChat) or MonoBehaviour (in Unity)
Audio Link Settings
bool
default:"false"
Enable or disable Audio Link Reaction for this fixture.
AudioLinkBandState
default:"Bass"
The frequency band of the spectrum to react to. Options:
Bass, Low_Mids, High_Mids, Trebleint
default:"0"
The level of delay to add to the reaction. Higher values create a more delayed response to audio.
float
default:"1.0"
Multiplier for the sensitivity of the reaction. Higher values make the fixture more responsive to audio.
bool
default:"false"
Enable Color Chord tinting of the light emission. This makes the light react to the dominant frequency color.
General Settings
float
default:"1.0"
Sets the overall intensity of the shader. Good for animating or scripting effects related to intensity. Its max value is controlled by Final Intensity.
float
default:"1.0"
Sets the maximum brightness value of Global Intensity. Good for personalized settings of the max brightness of the shader by other users via UI.
bool
default:"false"
Choose between setting the Final Intensity for all meshes, or individual meshes.
float
default:"1.0"
Sets the maximum brightness value of Global Intensity for volumetric meshes only.
float
default:"1.0"
Sets the maximum brightness value of Global Intensity for projection meshes only.
float
default:"1.0"
Sets the maximum brightness value of Global Intensity for fixture meshes only.
Color
default:"White * 2.0"
The main color of the light. Supports HDR colors.
Color Sampling
bool
default:"false"
Check this box if you wish to sample a separate texture for the color. The color will be influenced by the intensity of the original emission color. The texture is set in the shader itself.
bool
default:"false"
Check this box if you wish to use traditional color sampling instead of white to black conversion.
Vector2
default:"(0.5, 0.5)"
The UV coordinates to sample the color from on the texture.
bool
default:"false"
Check this box if you wish to enable AudioLink Theme colors.
int
default:"1"
Theme Color to Sample from. AudioLink supports 4 theme colors.
Movement Settings
Transform
default:"null"
The target for this mover to follow. When set, the fixture will automatically aim at this transform.
Fixture Settings
float
default:"4.0"
Projection Spin Speed (Udon Override Only). Negative values spin in the opposite direction.
bool
default:"false"
Enable projection spinning (Udon Override Only).
int
default:"1"
Use this to change what projection is selected.
Mesh Settings
MeshRenderer[]
required
The meshes used to make up the light. You need at least 1 mesh in this group for the script to work properly. Supports up to 5 mesh renderers.
float
default:"2.5"
Controls the radius of a mover/spot light.
float
default:"1.0"
Controls the length of the cone of a mover/spot light.
float
default:"8.5"
Controls the mesh length of the cone of a mover/spot light.
Public Methods
_UpdateInstancedProperties()
Updates all material property blocks with current fixture settings including AudioLink parameters._UpdateInstancedPropertiesSansAudioLink()
Updates material property blocks without AudioLink functionality enabled._SetProps()
Initializes the MaterialPropertyBlock for this fixture.Properties (for Udon Scripting)
All public fields have corresponding properties for safe access from Udon scripts:LightColorTint- Get/Set the light colorConeWidth- Get/Set the cone widthConeLength- Get/Set the cone lengthMaxConeLength- Get/Set the maximum cone lengthGlobalIntensity- Get/Set the global intensityFinalIntensity- Get/Set the final intensityFinalIntensityComponentMode- Get/Set component modeFinalIntensityVolumetric- Get/Set volumetric intensityFinalIntensityProjection- Get/Set projection intensityFinalIntensityFixture- Get/Set fixture intensitySelectGOBO- Get/Set the selected goboEnableAudioLink- Get/Set AudioLink enabled stateBand- Get/Set the frequency bandDelay- Get/Set the reaction delayBandMultiplier- Get/Set the band multiplierTextureSamplingCoordinates- Get/Set texture sampling coordinatesSpinSpeed- Get/Set projection spin speedProjectionSpin- Get/Set projection spin enabledColorChord- Get/Set color chord enabledColorTextureSampling- Get/Set texture sampling enabledTraditionalColorTextureSampling- Get/Set traditional sampling modeThemeColorSampling- Get/Set theme color sampling enabledThemeColorTarget- Get/Set theme color target
Usage Example
AudioLink Band States
Related Components
- VRStageLighting_DMX_Static - DMX-controlled fixtures
- VRStageLighting_AudioLink_Laser - AudioLink laser effects
- VRSL_LocalUIControlPanel - Local UI control panel for VRSL