Camera Map Shader

General綜述

This shader is used to project an image in camera space. It is generally used in conjunction with the Matte Shadow Catcher shader to generate input for the 『background』, which will match the back-plate of the environment shader.

該節點用於將一張圖片投射在相機空間。通常與Matte Shadow Catcher節點一起使用,在渲染時充當Background(背景)的輸入,從而與Environment節點的Back-plate(背板)相匹配。

Shader Options節點選項

Image圖像

Map貼圖

This is the texture map that is to be projected.

指定用於投射的紋理貼圖。

SRGB/Gamma/Exposure/Hue/Saturation SRGB/伽馬/曝光/色相/飽和度

Common image adjustments.

通過圖像調節參數

Most non HDR textures require gamma correction during sampling. If your texture is SRGB compliant then you need to check the SRGB option.

大部分的非HDR貼圖需要在採樣時使用伽馬矯正。如果貼圖使用了SRGB標準方式,需要勾選SRGB選項。

NOTE: these come from the Clip『Adjust』 properties in Softimage

注意:這些參數在Softimage中是在Adjust下拉菜單中設置的。

Scaling: Match Render Size尺寸:匹配渲染大小

This forces the texture projection to match one pixel to one texel.

強制貼圖的像素解析度與投射像素解析度一致。

For this to work correctly, the render frame must have the same dimensions (in pixels) as the texture you are projecting.

要讓這個功能正確工作,請確保渲染解析度與用於投射的貼圖一致。

Scaling: Aspect Ratio尺寸:縱橫比

This specifies what aspect ratio to use for the back-plate:

指定Back-Plate採用何種縱橫比:

  • Texture – Uses the texture dimensions to determine aspect ratio. Texture will not be warped.
  • Texture-利用紋理尺寸確定縱橫比。紋理不會拉伸。
  • Render – Uses the render frame dimensions to determine the aspect ratio. Texture may be warped.
  • Render-使用渲染幀尺寸確定縱橫比。紋理可能會拉伸。

Alpha Channel Replace: Enable阿爾法通過替換:啟用

This allows you to over-ride the texture alpha values, which may be necessary if they are either non-existent or not correct. Typically, for environment textures, the alpha value should always be 0.0, if you plan on compositing environment layers.

如果紋理的Alpha不存在或錯誤,你可以通過該屬性覆蓋紋理的Alpha。如果想在後期合成Environment層,通常Environment紋理的Alpha應該是0。

Alpha Channel Replace: Alpha阿爾法通道替換:阿爾法

This is the alpha value that will be used instead of the texture alpha values.

該選項用於代替紋理的阿爾法值。

Reflection/Offscreen 反射/視野外的顏色

Reflection is Environment環境為反射

Bypasses the projected texture when seen through reflection rays and returns the

environment map instead.

指定反射採樣射線不採樣投射紋理,轉而採樣環境貼圖。

This is useful if the environment map does not match the projected back-plate texture very well.

Off-screen is Environment視野外使用環境貼圖

When enabled, if a non-eye ray lands outside the camera frustum this bypasses the projected texture and returns the environment map instead. This over-rides the『Off-screen Color』.

啟用時,如果採樣射線超過了視野範圍,讓其不再採樣投射紋理,轉而採樣環境貼圖。這個選項會覆蓋Off-Screen Color的設置。

Off-screen Color屏外顏色

If a non-eye ray lands outside the camera frustum this bypasses the projected texture and returns this color instead.

如果採樣射線超出了視野範圍,讓其不再採樣投射紋理,轉而採樣這個顏色。

Camera相機

Camera相機

This allows you to pick a camera to project from, bypassing the default 『render』 camera. This option can be useful if you want to freeze a projection in a scene, while

still being able to move the render camera.

用於選定一相攝像機作為投射紋理攝像機,而不用默認的渲染攝像機投射。如果想固定背景投射,就開啟這個選項。這樣就可以移動渲染攝像機了

When an alternative camera is used for the projection, the Scaling Aspect Ratio option is ignored and the texture aspect ratio is dictated by the camera projection aspect ratio.

當投射選擇了另外的攝像機時,Scaling中的Aspect Ratio參數將被忽略,貼圖的寬長比使用相機投射Aspect Ratio.

Here is a simple scene that demonstrates the Camera Map shader in conjunction with

an environment back-plate using the same image.

這裡有一個簡單的例子,可以說明Camera Map節點與Environment Back-Plate共用一張圖片時的情況。

In the following example you can see the environment back-plate image (courtesy of Jeff Patton), with a modeled magenta plane in the scene where the road should be.

在下面圖片中,可以看到Environment節點時Back-plate調用的圖片(Jeff Patton提供),以及用來代替公路位置的洋紅色模型平面。

The following example now has the Camera Map applied to the plane, with its image being the same one as the back-plate.

下面圖例中,將Back-Plate中使用的圖片通過Camera Map節點投射到平面上。

Now we create a fully reflective sphere, hovering just above the plane that has the Camera Map applied to it. The Environment map uses a back-plate for eye rays and a spherical『longitude-latitude』 map for reflections/refractions/GI. Note how the sphere reflects part of the road perfectly – this is where the rays have landed inside

the camera frustum. Since 『Off-screen is Environment』 is enabled by default,

the rest of the reflection in the sphere shows the environment map.

我們創建一個鏡面反射球,放在使用Camera Map節點投射貼圖的平面之上。視野內的背景使用Redshift Environment節點,開啟Back-Plate貼圖,而Reflections/Refractions/GI的採樣,使用Spherical Logitude-latitude投射模式的貼圖。可以看到,球上有一部分公路的反射非常完美。因為這部分處於攝像機的視野中。由於默認Off-Screen is Environment是開啟的,因而球中另一部分的反射中的是Environment中的貼圖(譯註:即那張Spherical Longitude-Latitude貼圖)。

The discontinuity between the two reflected images looks strange, so enabling 『Reflection is Environment』produces a less accurate, but more consistent result.

由於兩個反射之間不連續,因此看起來有些奇怪.所以啟用Reflection is Environment,儘管這瞧去導致結果不太精確(譯註:球體中的反射此時不起真正採樣那塊地面,而直接採樣環境球中的貼圖),但這時結果反倒顯得更真實了。

推薦閱讀:

TAG:redshift | gpu渲染 | 渲染 |