下載本文檔
版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報(bào)或認(rèn)領(lǐng)
文檔簡介
1、MentalRay環(huán)境模擬這篇教程翻譯的不是很好,有些術(shù)語不懂,請高人查缺補(bǔ)漏,修改一下,以免誤人子弟。I read a thread which was started by Filip Orrby, in which he asked “How to make object not block FG rays?”. He went on to answer his own question and since it is similar to a technique I use, I decided to elaborate.我讀到一個(gè)人詢問“如何讓物體不阻塞FG射線?”他的答案和以前我用
2、到的一種技術(shù)很相似。我在這里詳細(xì)闡述一下。Im going to write about a shader and lighting setup I use a fair bit for product shots, where the background is very simple, often white and the product is to be brightly lit. For my final renders I usually break things into render layers, but I like to be able to quickly render
3、 everything in one pass to evaluate my animation and to show my progress to the client.我正要寫一篇我經(jīng)常使用的shader以及一個(gè)照明設(shè)置的文章,這種技巧經(jīng)常被用于我的產(chǎn)品展示渲染,這個(gè)設(shè)置背景很簡單,經(jīng)常是白色背景,能使產(chǎn)品看上去更加光亮一些。在最后的渲染中經(jīng)常將物體渲染出不同的層通道,但我也喜歡在給客戶展示時(shí),會將所有物體放到一個(gè)Pass中渲染,以節(jié)省時(shí)間。Here is a typical example of the end result.這是典型的最終結(jié)果To see a step-by-step
4、 breakdown of the setup, click hereMy lighting is physical sun/sky using final gather. My background is a simple fileTexture of a cloudy sky above a white ground which I have mapped onto a flattened sphere. You can download my scene file here.我使用了物理天光系統(tǒng),背景是一個(gè)簡單的天空文件貼圖,地面是白色的壓扁的球體。你可以點(diǎn)擊這里下載源文件。Here i
5、s a snapshot of the wireframe.線框的截圖and this is a small version of the sky map天空貼圖The problem is that the flattened sphere blocks the final-gather rays from the physical sky. I could just live with it and use the sphere surface with its file texture as a final-gather radiator. And I would get somthin
6、g like this問題是扁平的球體阻擋了來自天光的FG射線。我只能將帶著貼圖的球體作為FG的散射器了,如下圖所示。As you can see the result is still good and is not drastically different to the first image. But my background image is mostly white with a bit of blue and this drives the look of the FG giving it a neutral feel. Compare this with the first
7、image where, due to the low angle of the sun, there is a noticeable warm look to the FG.So, how do we stop the sphere blocking the FG? The answer is, by using mib_continue and mip_rayswitch.你可以看到渲染結(jié)果還是可以的,和第一張圖比起來顯著的差異,我的背景圖片大部分是白色的,帶著一點(diǎn)藍(lán)色,這樣可以使FG射線呈現(xiàn)一個(gè)自然的效果。對比第一張圖片,將物理天光燈光的陽光的角度調(diào)低,可以獲得一個(gè)顯而易見的暖色調(diào)效果。
8、那么,我們怎樣才能不讓球體阻擋FG射線呢?答案就是使用mib_continue 和 mip_rayswitch節(jié)點(diǎn)。mip_rayswitch enables different shaders to be used depending on the type of ray that is being calculated. Have a look at the attributes here to see the different type of rays that can be singled out.mip_rayswitch節(jié)點(diǎn)可以將不同的Shaders作為不同類型的射線來計(jì)算使用。
9、看看它的屬性面板,有許多不同類型的射線可以單獨(dú)的分離出來。Ill just mention two of them in this example. The eye rays are the ones you actually see in the rendered image, so that is where I connect the shader that I want for my background color. The finalgather rays are used in the FG calculations and it is here I connect the mi
10、b_continue shader.在我們這個(gè)例子中我將僅僅涉及到它們中的兩種,Eye 射線是你實(shí)際上看到的渲染出來的圖像,所以我將希望我的背景呈現(xiàn)的顏色連接給這個(gè)Shader。FG射線會在FG計(jì)算中用到,這里我將它連接給一個(gè)mib_continue節(jié)點(diǎn)。mib_continue is a shader that takes any incomming ray and simply lets it continue on through the surface as if the surface was not even there. So in my example it lets the
11、FG rays from the physical sky continue through the flattened sphere. In this case Im just using the mib_continue with its default attributes.mib_continue節(jié)點(diǎn)是一個(gè)接受任何入射光線,讓其穿過模型表面就像表面不存在一樣。在這個(gè)例子中,我讓FG射線從物理天光發(fā)射出來穿過球體。我使用mib_continue節(jié)點(diǎn)的默認(rèn)設(shè)置。So that is the basis of my setup, but to make it work there are a
12、 few more things to consider.這就是我的設(shè)想,但是做要比想難很多倍。Firstly, I am using mia_exposure_photographic tone mapper as a lens shader with gamma=2.2 for a linear workflow. This means I need to increase the brightness of my background texture map to boost it into the same dynamic range as the physical sky. If I
13、 dont, then the background will be black! And I need to de-gamma the fileTexture since the gamma will be added by the tone mapper.首先,我是用一個(gè)mia_exposure_photographic tone mapper作為一個(gè)鏡頭shader將Gamma值調(diào)節(jié)為2.2。這意味著我需要增加背景圖片的亮度來迎合物理天光的高動態(tài)范圍。如果我不這樣做,背景圖片在高動態(tài)的物理天光的照射下依舊是黑色的。同時(shí)由于Gamma數(shù)值會被tone Map貼圖加大,我需要減少文件貼圖的G
14、amma值。Secondly, I am using the mip_matteshadow shader with my own spin on it for coloring the flattened sphere. Ill do my best to explain: mip_matteshadow is a more powerful version of mayas native useBackground shader. It is normally used to catch shadows, occlusion, reflections and indirect lighti
15、ng for compositing later and supports multiple outputs. But I am using it as a way of doing that compositing within the render.Reason 1: it makes it easy to get shadows on a surface that is not otherwise illuminated by any lights.Reason 2: it makes it easy to get reflections on very light colored (o
16、r white) surfaces, because it can do subtractive reflections. (I didnt use reflections in my example though.)Reason 3: When I get to my final renders phase, I can easily break out the components I need into different renderlayers without having to change too many things.第二,我需要mip_matteshadow節(jié)點(diǎn),來生成扁平
17、球體的色調(diào),我來解釋一下:mip_matteshadow節(jié)點(diǎn)比Maya自帶的Usebacgground節(jié)點(diǎn)要強(qiáng)大很多,一般用于分離陰影、阻塞、反射、和間接光照用于后期合成以及支持多種輸出。我只是用它在渲染中進(jìn)行合成,1.因?yàn)楹苋菀撰@得陰影而且不受其他燈光的影響。2.他很容易從受燈光顏色影響很少(或者是白色)的物體上獲得反射效果,因?yàn)樗麩o需改變其他東西就可以進(jìn)行負(fù)反射。3.當(dāng)我進(jìn)入最后渲染階段時(shí),我不用更改大量的屬性而將我需要的屬性分離到渲染層中。Thirdly, I am using mib_amb_occlusion instead of using mip_matteshadows occ
18、lusion feature. The reason is that I often add nurbs-planes to act as final-gather casters, much like you would use diffuse lights or reflector cards in a real photo shoot. These planes will have primary visibility off, but I do not what them to occlude the ground in any way. mib_amb_occlusion has a
19、n idNonself attribute that can be used to prevent objects from being considered for ambient occlusion.第三,我使用mib_amb_occlusion節(jié)點(diǎn)來替代mip_matteshadow節(jié)點(diǎn)的 OCC功能,因?yàn)槲页3URBS平面作為FG的底板。也許大多數(shù)人使用燈光陣列和反射板來模擬真實(shí)環(huán)境,這些物體經(jīng)常是不可見的,但是我不想它們產(chǎn)生任何OCC的影響,我使用mib_amb_occlusion節(jié)點(diǎn)的idNonself屬性來防止物體被計(jì)算到AO中。Notice how I have set i
20、dNonself=5 . If I add an extra attribute called miLabel to an objects transform node and set its value to the same number, in this case 5, then it will be ignored by the ambient occlusion. Here is how it looks on the bgndSphere transform node注意我將idNonself設(shè)為5,如果我增加額外的屬性miLabel到一個(gè)物體的位移節(jié)點(diǎn)上,將其值設(shè)為與idNons
21、elf相同的數(shù)字,那么這個(gè)物體就不會被考慮在AO的計(jì)算范圍之內(nèi)了。So now, to bring all this together, I just need to show you the hypershader network (click image for a larger version that you can actually read).現(xiàn)在,我展示一下Hypershader中的節(jié)點(diǎn)網(wǎng)絡(luò)。Ill explain the connections from left to right.The fileTexture connects to the gammaCorrect nod
22、e with a value of 0.455 (1/2.2)我將從左到右來解釋節(jié)點(diǎn)網(wǎng)絡(luò)。文件節(jié)點(diǎn)連接到gammaCorrect節(jié)點(diǎn),調(diào)節(jié)的數(shù)值時(shí)1/2.2(mia_exposure_photographicd 的Gamma值)=0.4545mib_amb_occlusion is combined with the background color using a mib_color_mix node, where the occlusion layer is multiplied over the background color.mib_amb_occlusion 是用mib_color
23、_mix節(jié)點(diǎn)與背景顏色聯(lián)合使用,OCC層正片疊底在背景顏色上。The combined result is then multiplied by 20000 to bring it into roughly the same dynamic range as the physical sky and counter the effect of the exposure node lens shader. This number, 20000, was determined through trial-and-error (but after doing this for I while, Iv
24、e got fairly good at guessing).疊加的結(jié)果要使用一個(gè)乘除節(jié)點(diǎn)乘以20000來適配物理天光的高動態(tài)和對抗鏡頭材質(zhì)的曝光。參數(shù)是20000,這是需要反復(fù)測試計(jì)算得出的。The very bright background color is then connected to the eye ray of the mip_rayswitch where it is combined with finalgather ray from the mib_continue node (shown earlier).非常亮的背景顏色連接到mip_rayswitch的sye ra
25、y上,mip_rayswitch的finalgather連接了mib_continue節(jié)點(diǎn),讓FG射線穿過背景的表面。The output of mip_rayswitch is fed into the mip_matteshadow background color. And mip_matteshadow is connected to the SG node as the miMaterialShader. (The lambert shown has no effect on the render, but is useful for being able to select assigned objects from the hypershade rmb-menu)mip_rayswitch節(jié)點(diǎn)的輸出連接到mip_matteshadow的background上
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時(shí)也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2024年度紡織品ODM定制與合作合同
- 2024年建筑工程材料供需協(xié)議
- 2024三方合作經(jīng)營協(xié)議合同
- 2024年度環(huán)保型涂料生產(chǎn)與銷售合同
- 2024年城市基礎(chǔ)設(shè)施合作合同
- 2024年辦公桌租賃協(xié)議
- 2024年度體育賽事贊助與推廣合同
- 2024年度智慧校園建設(shè)與運(yùn)營合同
- 2024家居裝飾墻地磚采購協(xié)議
- 2024年建筑安裝安全協(xié)議
- 【公開課】《農(nóng)業(yè)專題復(fù)習(xí)》【課件】
- 第7課《大雁歸來》課件(共15張ppt) 部編版語文八年級下冊
- 培訓(xùn)的方式和方法課件
- 三年級下冊口算天天100題(A4打印版)
- 三基選擇題(東南大學(xué)出版社)
- 2021年大唐集團(tuán)招聘筆試試題及答案
- DBJ53/T-39-2020 云南省民用建筑節(jié)能設(shè)計(jì)標(biāo)準(zhǔn)
- 2022版義務(wù)教育數(shù)學(xué)課程標(biāo)準(zhǔn)解讀課件PPT模板
- 實(shí)驗(yàn)五 PCR擴(kuò)增課件
- 馬拉松運(yùn)動醫(yī)療支援培訓(xùn)課件
- 中醫(yī)藥宣傳手冊
評論
0/150
提交評論