You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: Packages/com.unity.shadergraph/Documentation~/Normal-Strength-Node.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
## Description
4
4
5
-
Adjusts the strength of the normal map defined by input **In** by the amount of input **Strength**. A **Strength** value of 1 will return the input unaltered. A **Strength** value of 0 will return a blank normal map.
5
+
Adjusts the strength of the normal map defined by input **In** by the amount of input **Strength**. A **Strength** value of 1 will return the input unaltered. A **Strength** value of 0 will return a blank (flat) tangent-space normal: vector (0, 0, 1). When encoded as a texture color in the 0–1 range, this corresponds to (0.5, 0.5, 1.0) or 128, 128, 255 in 8-bit.
Copy file name to clipboardExpand all lines: Packages/com.unity.shadergraph/Documentation~/Sample-Texture-2D-Node.md
+9-13Lines changed: 9 additions & 13 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,23 +27,19 @@ The Sample Texture 2D [!include[nodes-inputs](./snippets/nodes-inputs.md)]
27
27
|**Texture**| Texture 2D | None | The Texture 2D asset to sample.|
28
28
|**UV**| Vector 2 | UV | The UV coordinates to use to sample the texture. |
29
29
|**Sampler**| Sampler State | Default Sampler State | The Sampler State and settings to use to sample the texture.|
30
-
|**LOD**| Float | LOD | The specific mip to use when sampling the Texture.**NOTE** The **LOD** Input port only displays if **Mip Sampling Mode** is **LOD**. For more information, refer to [Additional node settings](#additional-node-settings). |
31
-
|**Bias**| Float | Bias |**NOTE**: The **Bias** Input port only displays if **Mip Sampling Mode** is **Bias**. For more information, refer to [Additional node settings](#additional-node-settings). If **Use Global Mip Bias** is enabled, Unity adds this Bias amount to the Global Mip Bias for a texture's mip calculation. If **Global Mip Bias** is disabled, Unity uses this Bias amount instead of the Global Mip Bias. |
32
-
|**DDX**| Float | DDY |**NOTE**: The DDX Input port only displays if **Mip Sampling Mode** is **Gradient**. For more information, refer to [Additional node settings](#additional-node-settings). The specific DDX value to use to calculate the texture's mip when sampling. For more information on DDX values for mipmaps, refer to [Mipmaps introduction](https://docs.unity3d.com/Documentation/Manual/texture-mipmaps-introduction.html) in the Unity User Manual. |
33
-
|**DDY**| Float | DDY |**NOTE**The **DDY** Input port only displays if **Mip Sampling Mode** is **Gradient**. For more information, refer to [Additional node settings](#additional-node-settings). The specific DDY value to use to calculate the texture's mip when sampling. For more information on DDY values for mipmaps, refer to [Mipmaps introduction](https://docs.unity3d.com/Documentation/Manual/texture-mipmaps-introduction.html)> in the Unity User Manual. |
30
+
|**LOD**| Float | LOD | The specific mip to use when sampling the Texture.<br/>**Note**: The **LOD** Input port only displays if **Mip Sampling Mode** is **LOD**. For more information, refer to [Additional node settings](#additional-node-settings). |
31
+
|**Bias**| Float | Bias |When you enable **Use Global Mip Bias**, Unity adds this Bias amount to the Global Mip Bias for a texture's mip calculation. When you disable **Global Mip Bias**, Unity uses this Bias amount instead of the Global Mip Bias. <br/>**Note**: The **Bias** Input port only displays if **Mip Sampling Mode** is **Bias**. For more information, refer to [Additional node settings](#additional-node-settings). |
32
+
|**DDX**| Float | DDY | The specific DDX value to use to calculate the texture's mip when sampling. For more information on DDX values for mipmaps, refer to [Mipmaps introduction](https://docs.unity3d.com/Documentation/Manual/texture-mipmaps-introduction.html) in the Unity User Manual.<br/>**Note**: The DDX Input port only displays if **Mip Sampling Mode** is **Gradient**. For more information, refer to [Additional node settings](#additional-node-settings). |
33
+
|**DDY**| Float | DDY | The specific DDY value to use to calculate the texture's mip when sampling. For more information on DDY values for mipmaps, refer to [Mipmaps introduction](https://docs.unity3d.com/Documentation/Manual/texture-mipmaps-introduction.html)> in the Unity User Manual.<br/>**Note**: The **DDY** Input port only displays if **Mip Sampling Mode** is **Gradient**. For more information, refer to [Additional node settings](#additional-node-settings). |
34
34
35
35
## Controls
36
36
37
37
The Sample Texture 2D [!include[nodes-controls](./snippets/nodes-controls.md)]
|**Type**|**Dropdown**| N/A | Select whether the texture is a Texture asset or a normal map. |
42
-
| N/A | N/A |**Default**| The texture is a Texture asset. |
43
-
| N/A | N/A |**Normal**| The texture is a normal map. |
44
-
| Space | Dropdown | N/A | Select whether the texture is a Texture asset or a normal map. |
45
-
| N/A | N/A |**Tangent**| Use a Tangent normal map whenever the mesh for a geometry needs to deform or change, such as when animating a character. With Tangent Space, the normal map's normals are relative to the existing vertex normals of any geometry rendered with your Shader Graph. Your Shader Graph only adjusts the vertex normals and not override them. |
46
-
| N/A | N/A |**Object**| Use an Object normal map whenever the mesh for a geometry is static and doesn't deform. With Object Space, the normal map's normals are explicit and override the normals of any geometry rendered with your Shader Graph. Because a static mesh's normals never change, an Object normal map also maintains consistent lighting across different levels of detail (LODs). <br> For more information about normal maps, refer to Normal map (Bump mapping) in the User manual. |
|**Type**| Select whether the texture is a Texture asset or a normal map. The options are:<ul><li>**Default**: Outputs the raw texture data according to the imported texture format or the format specified when the texture/render texture was created. For more information, refer to [GraphicsFormat](https://docs.unity3d.com/Documentation/ScriptReference/Experimental.Rendering.GraphicsFormat.html).</li><li>**Normal**: Interprets the texture as a normal map and outputs RGB in the range [−1, 1]. |
42
+
| Space | Select the space used when Type is Normal. Behavior varies based on whether the blue channel is used. The options are:<ul><li>**Tangent**: Assumes an imported Normal Map format where only X and Y are stored. The blue channel is ignored. Use Tangent space for deforming meshes (for example, animated characters). Normals are relative to the mesh’s vertex normals. Shader Graph adjusts but does not override them.</li><li>**Object**: Uses the blue channel and expects the texture to be UNorm in Linear color space. Use Object space for static meshes. Normals override mesh normals and maintain consistent lighting across LODs. |
47
43
48
44
## Additional node settings
49
45
@@ -65,7 +61,7 @@ If the Sample Texture 2D node uses the **Standard** Mip Sampling Mode, the Textu
65
61
66
62

67
63
68
-
When the Mip Sampling Mode is set to **Gradient**, the Sample Texture 2D node can use the standard set of UVs for the model in the mip level calculation, instead of the latitude and longitude UVs needed for sampling the texture. The new UV coordinates passed into the **DDX** and **DDY** input ports result in a continuous mip level, and remove the seam.
64
+
When you set the Mip Sampling Mode to **Gradient**, the Sample Texture 2D node can use the standard set of UVs for the model in the mip level calculation, instead of the latitude and longitude UVs needed for sampling the texture. The new UV coordinates passed into the **DDX** and **DDY** input ports result in a continuous mip level, and remove the seam.
69
65
70
66

Copy file name to clipboardExpand all lines: Packages/com.unity.shadergraph/Documentation~/Swizzle-Node.md
+4-2Lines changed: 4 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -7,9 +7,11 @@ Creates a new [vector](https://docs.unity3d.com/Manual/VectorCookbook.html) from
7
7
To specify how input elements should be swizzled, enter a formatting string in the input mask.
8
8
To invert the order of the input elements, for example, use the string "wzyx" or "abgr".
9
9
10
-
The length of the input mask determines the dimensions of the output vector. The error "Invalid Mask" indicates an input mask value which includes one or more channels that do not exist in the input vector.
10
+
The length of the input mask determines the dimensions of the output vector, while the channels used by the input mask determine the dimensions of the input vector.
11
11
12
-
To output a vector3 with the x, y and z elements of the input vector, for example, use the input mask “xyz” or “rgb”.
12
+
For example;
13
+
* To output a vector4 that contains two copies of a vector2 input, set **Mask** to `xyxy`.
14
+
* To output the alpha value from a vector4 input, set **Mask** to `a`.
0 commit comments