Skip to content

Commit e9cb679

Browse files
[11.x.x forward port] - Add new sample cubemap node with world space direction - documentation (#2357)
* Updated documentation * Updated Input-Nodes.md * Updated images Co-authored-by: Sharlene Tan <[email protected]>
1 parent 7f764e0 commit e9cb679

File tree

6 files changed

+31
-25
lines changed

6 files changed

+31
-25
lines changed

com.unity.shadergraph/Documentation~/Input-Nodes.md

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -90,22 +90,25 @@
9090

9191
## Texture
9292

93-
|[Cubemap Asset](Cubemap-Asset-Node.md)|[Sample Cubemap](Sample-Cubemap-Node.md)|
93+
|[**Cubemap Asset**](Cubemap-Asset-Node.md)|[**Sample Cubemap**](Sample-Cubemap-Node.md)|
9494
|:--------:|:------:|
9595
|[![Image](images/CubemapAssetNodeThumb.png)](Combine-Node)|![](images/SampleCubemapNodeThumb.png)|
9696
| Defines a constant Cubemap Asset for use in the shader. | Samples a Cubemap and returns a Vector 4 color value for use in the shader. |
97-
|[**Sample Texture 2D**](Sample-Texture-2D-Node.md)|[**Sample Texture 2D Array**](Sample-Texture-2D-Array-Node.md)|
98-
|![Image](images/SampleTexture2DNodeThumb.png)|![Image](images/SampleTexture2DArrayNodeThumb.png)|
99-
|Samples a Texture 2D and returns a color value for use in the shader.|Samples a Texture 2D Array at an Index and returns a color value for use in the shader.|
100-
|[**Sample Texture 2D LOD**](Sample-Texture-2D-LOD-Node.md)|[**Sample Texture 3D**](Sample-Texture-3D-Node.md)|
101-
|![Image](images/SampleTexture2DLODNodeThumb.png)|![Image](images/SampleTexture3DNodeThumb.png)|
102-
|Samples a Texture 2D at a specific LOD and returns a color value for use in the shader.|Samples a Texture 3D and returns a color value for use in the shader.|
103-
| [**Sample Virtual Texture**](Sample-Virtual-Texture-Node.md) | [**Sampler State**](Sampler-State-Node.md) |
104-
| ![image](images/SampleVirtualTextureNodeThumb.png) | ![Image](images/SamplerStateNodeThumb.png) |
105-
| Samples a Virtual Texture and returns color values for use in the shader. | Defines a Sampler State for sampling textures.|
106-
|[**Texel Size**](Texel-Size-Node.md)| [**Texture 2D Array Asset**](Texture-2D-Array-Asset-Node.md)|
107-
|![Image](images/TexelSizeNodeThumb.png)| ![Image](images/Texture2DArrayAssetNodeThumb.png)|
108-
|Returns the Width and Height of the texel size of Texture 2D input.| Defines a constant Texture 2D Array Asset for use in the shader.|
109-
|[**Texture 2D Asset**](Texture-2D-Asset-Node.md)|[**Texture 3D Asset**](Texture-3D-Asset-Node.md)|
110-
|![Image](images/Texture2DAssetNodeThumb.png)| ![Image](images/Texture3DAssetNodeThumb.png)|
111-
|Defines a constant Texture 2D Asset for use in the shader.| Defines a constant Texture 3D Asset for use in the shader.|
97+
|[**Sample Reflected Cubemap Node**](Sample-Reflected-Cubemap-Node.md)|[**Sample Texture 2D**](Sample-Texture-2D-Node.md)|
98+
|![Image](images/SampleReflectedCubemapThumb.png)|![Image](images/SampleTexture2DNodeThumb.png)|
99+
|Samples a Cubemap with reflected vector and returns a Vector 4 color value for use in the shader.|Samples a Texture 2D and returns a color value for use in the shader.|
100+
|[**Sample Texture 2D Array**](Sample-Texture-2D-Array-Node.md)|[**Sample Texture 2D LOD**](Sample-Texture-2D-LOD-Node.md)|
101+
|![Image](images/SampleTexture2DArrayNodeThumb.png)|![Image](images/SampleTexture2DLODNodeThumb.png)|
102+
|Samples a Texture 2D Array at an Index and returns a color value for use in the shader.|Samples a Texture 2D at a specific LOD and returns a color value for use in the shader.|
103+
|[**Sample Texture 3D**](Sample-Texture-3D-Node.md)| [**Sample Virtual Texture**](Sample-Virtual-Texture-Node.md) |
104+
|![Image](images/SampleTexture3DNodeThumb.png)| ![image](images/SampleVirtualTextureNodeThumb.png) |
105+
|Samples a Texture 3D and returns a color value for use in the shader.| Samples a Virtual Texture and returns color values for use in the shader.|
106+
|[**Sampler State**](Sampler-State-Node.md)|[**Texel Size**](Texel-Size-Node.md)|
107+
|![Image](images/SamplerStateNodeThumb.png)|![Image](images/TexelSizeNodeThumb.png)|
108+
|Defines a Sampler State for sampling textures.|Returns the Width and Height of the texel size of Texture 2D input.|
109+
|[**Texture 2D Array Asset**](Texture-2D-Array-Asset-Node.md)|[**Texture 2D Asset**](Texture-2D-Asset-Node.md)|
110+
|![Image](images/Texture2DArrayAssetNodeThumb.png)|![Image](images/Texture2DAssetNodeThumb.png)|
111+
|Defines a constant Texture 2D Array Asset for use in the shader.|Defines a constant Texture 2D Asset for use in the shader.|
112+
|[**Texture 3D Asset**](Texture-3D-Asset-Node.md)| |
113+
|![Image](images/Texture3DAssetNodeThumb.png)| |
114+
|Defines a constant Texture 3D Asset for use in the shader.| |

com.unity.shadergraph/Documentation~/Sample-Cubemap-Node.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@
22

33
## Description
44

5-
Samples a **Cubemap** and returns a **Vector 4** color value for use in the shader. Requires a **Direction** input in world space to sample the **Cubemap**. You can achieve a blurring effect by sampling at a different Level of Detail using the **LOD** input. You can also define a custom **Sampler State** using the **Sampler** input.
5+
Samples a Cubemap and returns a Vector 4 color value for use in the shader. Requires a Direction (**Dir**) input in world space to sample the Cubemap. You can achieve a blurring effect by using the **LOD** input to sample at a different Level of Detail. You can also use the **Sampler** input to define a custom Sampler State.
66

77
## Ports
88

99
| Name | Direction | Type | Binding | Description |
1010
|:------------ |:-------------|:-----|:---|:---|
1111
| Cube | Input | Cubemap | None | Cubemap to sample |
1212
| Dir | Input | Vector 3 | Normal (world space) | Direction or Mesh's normal vector |
13-
| Sampler | Input | Sampler State | Default sampler state | Sampler for the **Cubemap** |
13+
| Sampler | Input | Sampler State | Default sampler state | Sampler for the Cubemap |
1414
| LOD | Input | Float | None | Level of detail for sampling |
1515
| Out | Output | Vector 4 | None | Output value |
1616

com.unity.shadergraph/Documentation~/Sample-Reflected-Cubemap-Node.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1-
# Sample Cubemap Node
1+
# Sample Reflected Cubemap Node
22

33
## Description
44

5-
Samples a **Cubemap** with reflected vector and returns a **Vector 4** color value for use in the shader. Requires **View Direction** and **Normal** inputs to sample the **Cubemap**. You can achieve a blurring effect by sampling at a different Level of Detail using the **LOD** input. You can also define a custom **Sampler State** using the **Sampler** input.
5+
Samples a Cubemap with reflected vector and returns a Vector 4 color value for use in the shader. Requires View Direction (**View Dir**) and **Normal** inputs to sample the Cubemap. You can achieve a blurring effect by using the **LOD** input to sample at a different Level of Detail. You can also use the **Sampler** input to define a custom Sampler State.
66

77
## Ports
88

@@ -11,7 +11,7 @@ Samples a **Cubemap** with reflected vector and returns a **Vector 4** color val
1111
| Cube | Input | Cubemap | None | Cubemap to sample |
1212
| View Dir | Input | Vector 3 | View Direction (object space) | Mesh's view direction |
1313
| Normal | Input | Vector 3 | Normal (object space) | Mesh's normal vector |
14-
| Sampler | Input | Sampler State | Default sampler state | Sampler for the **Cubemap** |
14+
| Sampler | Input | Sampler State | Default sampler state | Sampler for the Cubemap |
1515
| LOD | Input | Float | None | Level of detail for sampling |
1616
| Out | Output | Vector 4 | None | Output value |
1717

com.unity.shadergraph/Documentation~/Upgrade-Guide-10-0-x.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44

55
Shader Graph has renamed the **Vector 1** property as **Float** in both the Vector 1 node and the exposed parameter list. The **Float** precision was also renamed as **Single**. Behavior is exactly the same, and only the names have changed.
66

7-
## Renamed Sample Cubemap
7+
## Renamed Sample Cubemap Node
88

9-
Shader Graph has renamed the previous Sample Cubemap Node **to** Sample Reflected Cubemap**,** and **has** added a new Sample Cubemap**,** which **uses** world space direction.
9+
Shader Graph has renamed the previous Sample Cubemap Node to [Sample Reflected Cubemap Node](Sample-Reflected-Cubemap-Node.md), and has added a new [Sample Cubemap Node](Sample-Cubemap-Node.md), which uses world space direction.
1010

1111
## Master Stack graph output
1212

Lines changed: 2 additions & 2 deletions
Loading
Lines changed: 3 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)