朱峰社區(qū)首頁 朱峰社區(qū)

搜索資源 注冊|登陸

等待

返回 展開菜單
按功能 按軟件

unity3d視頻教程

unity3d視頻教程

包含11節(jié)視頻教程

從零基礎(chǔ)學(xué)習(xí)unity3d游戲引擎,簡單易學(xué)的視頻教程,讓你快速掌握unity3d,并喜歡上游戲開發(fā)的樂趣。

關(guān)閉

Unity組件:Render Settings 渲染設(shè)置

關(guān)注:1861 留言:0 樓主:打傘的柚子 發(fā)帖時間:15年11月16日

打傘的柚子

普通會員

打傘的柚子

社區(qū)新人:1級

關(guān)注2540人

  • 性別

  • 年齡

    23

  • 積分

    1

  • 登陸

    1

  • 發(fā)帖

    1

  • 作品

    1

間隔線

The Render Settings contain default values for a range of visual elements in your scene, like Lights and Skyboxes.

To see the Render Settings choose Edit->Render Settings from the menu bar.

渲染設(shè)置包括一系列場景中的視覺元素的默認值,例如燈光和天空盒。菜單中Edit->Render Settings可以打開渲染設(shè)置。

Properties 屬性
  • Fog
    If enabled, fog will be drawn throughout your scene.
    如果啟用,場景中將繪制霧效。
  • Fog Color 霧的顏色
    Color of the fog. 霧的顏色
  • Fog Mode 霧的類型
    Fog mode: Linear, Exponential (Exp) or Exponential Squared (Exp2). This controls the way fog fades in with distance.
    霧的類型:線性,指數(shù)(Exp),指數(shù)平方(Exp2)。霧的類型用來控制霧隨距離的變化。
  • Fog Density 霧的濃度
    Density of the fog; only used by Exp and Exp2 fog modes.
    僅用于指數(shù)(Exp),指數(shù)平方(Exp2)類型
  • Linear Fog Start/End
    線性霧開始/結(jié)束距離
    Start and End distances of the fog; only used by Linear fog mode.
    設(shè)置霧的開始和結(jié)束距離,僅用于線性霧。
  • Ambient Light 環(huán)境光
    Color of the scene's ambient light. 場景中環(huán)境光的顏色
  • Skybox Material 天空盒材質(zhì)
    Default skybox that will be rendered for cameras that have no skybox attached.
    如果沒有設(shè)置相機的天空盒,將會渲染默認的天空盒材質(zhì)。
  • Halo Strength 光暈強度
    Size of all light halos in relation to their Range.
    燈光光暈的大小與距離有關(guān)。
  • Flare Strength 耀斑強度
    Intensity of all flares in the scene. 場景中耀斑強度。
  • Halo Texture 光暈材質(zhì)
    Reference to a Texture that will appear as the glow for all Halos in lights.
    燈光光暈的紋理。
  • Spot Cookie 聚光燈投影遮罩
    Reference to a Texture2D that will appear as the cookie mask for all Spot lights.
    聚光燈的遮罩紋理。
Details 細節(jié)

The Render Settings is used to define some basic visual commonalities of any individual scene in your project. Maybe you have two levels in the same environment: one at daytime and one at nighttime. You can use the same meshes and Prefabs to populate the scene, but you can change the Ambient Light to be much brighter at daytime, and much darker at night.

渲染設(shè)置用來定義項目場景的一些基本的圖形共性。例如同一個場景中有2個關(guān)卡:一是在白天,另一個是夜間。您可以使用相同的模型和預(yù)制件來構(gòu)建場景,然后改變2者的環(huán)境光,白天明亮,而晚上黑暗。

Fog 霧

Enabling Fog will give a misty haze to your scene. You can adjust the look and color of the Fog with Fog Density and Fog Color, respectively.

開啟霧效將會在場景中繪制霧靄。你可以分別調(diào)整霧的顏色和密度。

Adding fog is often used to optimize performance by making sure that far away objects fade out and are not drawn. Please note that enabling fog is not enough to enable this performance optimization. To do that you also need to adjust your Camera's Far Clip Plane, so that geometry far away will not be drawn. It is best to tweak the fog to look correct first. Then make the Camera's far clip plane smaller until you see the geometry being clipped away before the fog fades it out.

開啟霧效通常用于優(yōu)化性能,霧可以讓遠處的物體淡出而不進行繪制。請注意,僅開啟霧效是不足以優(yōu)化性能的,你還需要調(diào)整相機的遠剪裁面,使遠處的物體不被繪制。最好先調(diào)整霧效得到正確的視覺效果,然后調(diào)小相機的遠裁剪面,使得幾何體在霧變淡前被裁減掉。


A scene with Fog turned off 關(guān)閉了霧效的場景


The same scene with Fog turned on 開啟了霧效的場景

Note that fog is rendered uniformly in orthographic camera mode. This is because in our shaders, we output post-perspective space Z coordinate as the fog coordinate. But post-perspective Z is not really suitable for fog in orthographic cameras. Why do we do this? Because it's fast and does not need any extra computations; handling orthographic cameras would make all shaders be a bit slower.

請注意,正交相機模式下霧是均勻繪制的。這是因為在著色器中,我們將視角空間變換后的Z坐標作為霧的坐標。但在正交相機中,視角空間的Z坐標并不適用于霧效。我們?yōu)槭裁匆@樣做呢?因為這種方法速度快,不需要任何額外的計算。處理正交相機會讓所有著色器速度變得有點慢。

Hints 提示
  • Don't under-estimate the visual impact your game can make by thoughtfully tweaking the Render Settings!
    不要低估仔細調(diào)整渲染設(shè)置后為游戲帶來的視覺沖擊力。
  • Render Settings are per-scene: each scene in your game can have different Render Settings.
    渲染設(shè)置是針對每個場景的,每個場景都可以有不同的渲染設(shè)置。

贊0 踩0

未知用戶

2005-2025 朱峰社區(qū) 版權(quán)所有 遼ICP備2021001865號-1
2005-2025 ZhuFeng Community All Rights Reserved

VIP

朱峰社區(qū)微信公眾號

回頂部

1.復(fù)制文本發(fā)給您的QQ好友或群、微信等;好友點擊鏈接以后,轉(zhuǎn)發(fā)就成功了。 2.如朋友點擊您的鏈接,您需要需刷新一下才行;同一個好友僅能點擊一次。
購買VIP,觀看所有收費教程!!