Skip to content

Commit f67c752

Browse files
markg-unityEvergreen
authored andcommitted
[Port] [2022.3] DOCG-7473 Move channel packing to its own task page, clarify steps
1 parent a375905 commit f67c752

File tree

4 files changed

+32
-0
lines changed

4 files changed

+32
-0
lines changed

Packages/com.unity.render-pipelines.universal/Documentation~/TableOfContents.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@
109109
* [Fullscreen Master Stack in Shader Graph reference for URP](urp-shaders/fullscreen-master-stack-reference.md)
110110
* [Shaders and Materials](shaders-in-universalrp.md)
111111
* [Shading Models](shading-model.md)
112+
* [Assign a channel-packed texture to a material](shaders-in-universalrp-channel-packed-texture.md)
112113
* [Material Variants](materialvariant-URP.md)
113114
* [Complex Lit](shader-complex-lit.md)
114115
* [Lit](lit-shader.md)

Packages/com.unity.render-pipelines.universal/Documentation~/lit-shader.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,8 @@ The __Surface Options__ control how URP renders the Material on a screen.
4747

4848
The __Surface Inputs__ describe the surface itself. For example, you can use these properties to make your surface look wet, dry, rough, or smooth.
4949

50+
You can use a single RGBA texture for the metallic, smoothness, and occlusion properties. For more information, refer to [Assign a channel-packed texture to a material in URP](shaders-in-universalrp-channel-packed-texture.md).
51+
5052
**Note:** If you are used to the [Standard Shader](https://docs.unity3d.com/Manual/Shader-StandardShader.html) in the built-in Unity render pipeline, these options are similar to the Main Maps settings in the [Material Editor](https://docs.unity3d.com/Manual/StandardShaderContextAndContent.html).
5153

5254

Packages/com.unity.render-pipelines.universal/Documentation~/shader-complex-lit.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,8 @@ The __Surface Options__ control how URP renders the Material on a screen.
4949

5050
The __Surface Inputs__ describe the surface itself. For example, you can use these properties to make your surface look wet, dry, rough, or smooth.
5151

52+
You can use a single RGBA texture for the metallic, smoothness, and occlusion properties. For more information, refer to [Assign a channel-packed texture to a material in URP](shaders-in-universalrp-channel-packed-texture.md).
53+
5254
**Note:** If you are used to the [Standard Shader](https://docs.unity3d.com/Manual/Shader-StandardShader.html) in the built-in Unity render pipeline, these options are similar to the Main Maps settings in the [Material Editor](https://docs.unity3d.com/Manual/StandardShaderContextAndContent.html).
5355

5456

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# Assign a channel-packed texture to a URP material
2+
3+
In the [Lit](lit-shader) and [Complex Lit](shader-complex-lit) shaders in the Universal Render Pipeline (URP), you can use a single RGBA texture for the metallic, smoothness, and occlusion properties. This technique is called channel packing or texture packing.
4+
5+
Follow these steps:
6+
7+
1. Create a texture with the following channels:
8+
9+
| **Channel** | **Property** |
10+
| - | - |
11+
| Red | Metallic |
12+
| Green | Occlusion |
13+
| Blue | Not used |
14+
| Alpha | Smoothness |
15+
16+
2. [Import the texture](https://docs.unity3d.com/Manual/ImportingTextures).
17+
18+
3. In the Inspector window for the texture, disable **sRGB (Color Texture)**.
19+
20+
4. Assign the texture to the **Metallic** and **Occlusion** properties of the material. Unity automatically uses the correct channels from the texture.
21+
22+
You can use [Shader Graph](https://docs.unity3d.com/Manual/shader-graph) instead if you pack channels in textures differently.
23+
24+
## Additional resources
25+
26+
- [Materials](https://docs.unity3d.com/Manual/Materials)
27+
- [Custom textures](https://docs.unity3d.com/Manual/Textures-landing)

0 commit comments

Comments
 (0)