hey, quick update regarding the sample.
It will be available in the latest Unity versions and above 6.3 (6000.3.0b5+) and 6.4 (6000.4.0a2+)
How to get them?
- Create a new project in your favorite render pipeline (URP or HDRP).
- Navigate to Window > Package Management > Package Manager
- In here, in the “In Project” category find and click on your current render pipeline (Universal or High Definition)
- Select Samples tab and scroll to the bottom to find Renderer Shader User Value Sample and click “Import”
What’s inside?
Two simples scene and some Helpers to streamline the process of packing/unpacking data. * HelpersRSUV.cs contains C# functions to help you pack data into a uint. (CPU side) * HelpersRSUV.hlsl contains functions to decode data directly in a shader graph [custom functions](https://docs.unity3d.com/Packages/com.unity.shadergraph@17.4/manual/Custom-Function-Node.html)Each scene contains a Sample Description GameObject explaining a little bit more in depth how it works and how to setup properly.
LookDev scene
This scene features a animated soldier with one simple idle animation and two components dedicated to pass data to the SkinnedMeshRenderer. Those components use the RSUV feature and allows you to customize the rendering of the soldier using different techniques:
Health component uses a simple quad outside the soldier geometry. The health and opacity of the bar is passed using RSUV. The health of the character is renderer in the shader by manipulating UVs and sampling a gradient.
Body component allows to customize the material using different methods such as, color palette sampling based on UVoffset, showing / hiding vertices based on vertex colors (set in DCC software like blender) or inflating vertices from a central point to make its belly grow.
Agora scene
This scene has 100 instances of the soldier from the lookdev scene. Those soldiers have randomized material feature on start so they will always look more or less different (same as the lookdev scene).
There’s some slight difference in this scene for the soldier : It’s using a simple MeshRenderer and a Vertex Animation 2D Texture Array instead of the animator and SkinnedMeshRenderer combo. The reason for that is that GPU Resident Drawer is not compatible with those two things (Animator and SkinnedMesh) and having multiple instances of this even with RSUV would break batching. This version with Mesh Renderer and Vertex Animation Texture (VAT) is using only one draw call per material (so only 4 draw calls for the whole scene) and is suitable to render crowds for exemple. (For that to work, make sure GPU Resident drawer is properly setup)
The VAT is a texture array and not a single texture, the reason for that is to be able to click on a soldier and change the animation index to target another texture in the texture array. This allows users to make the soldier jump when clicking on it, showing yet another example on how RSUV can be used.
Hope that helps getting your started and if you have any feedback about it, don’t hesitate to talk about it here, feedback is always valuable ![]()


