80.LV
Shader-Based Toggle Switch For XR In Unity
In this example, Oleg Frolov used vertex colors to define regions for visual effects and spatial transformations in the shader, such as color shifts and knob animations. Time-based interpolation is handled through a C# script, while the mesh transformation logic is implemented in HLSL via Shader Graph in URP.As Oleg shared, he enjoys using shaders for mesh transformations due to their performance benefits and ability to encapsulate visual design decisions at a lower implementation level, all while exposing a lightweight yet expressive API.Oleg plans to build a small 3D UI library for VisionOS (using RealityKit and SwiftUI) and Unity (with the XR Interaction Toolkit), leveraging this shader-based approach.See more of Oleg's projects below and follow him on X/Twitter:Join our 80 Level Talent platform and our new Discord server, follow us on Instagram, Twitter, LinkedIn, Telegram, TikTok, and Threads, where we share breakdowns, the latest news, awesome artworks, and more.