FLUENT中用camera parameter將視圖精確旋轉90度
不知道你有沒有和我一樣被CameraParameters窗口下的那個調整視圖的小箭頭(圖一)給弄得抓狂過。不管怎么拖動,都很難把視圖精確旋轉90度。

圖一 Camera Parameters窗口
用小箭頭調出來的視圖往往不是整90度,總會有點兒偏斜(圖二)。

圖二 原圖 用小箭頭調整的視圖
其實有更容易的方法來將視圖精確旋轉90度。如圖三所示,在左側的camera下拉菜單選擇up vector,將x,y,z設置為(1,0,0),然后點擊下面的Apply按鈕。視圖就會變成圖四那樣的完美90度旋轉。

圖三 精確逆時針旋轉90度的設置方法

圖四 精確逆時針旋轉90度后的視圖
其實FLUENT幫助文件里對camera下拉菜單里的四個選項(position, target, up vector,field)做了形象的說明,如圖五所示,四個選項分別表示:
【help文件原文】“Position” is the camera’s location. “Target” is thelocation of the point the camera is looking at, and “up vector”indicates to the camera which way is up. “Field” indicates thefield of view (width and height) of the display.
翻譯過來就是:
postion:camera放置位置
target: 鏡頭看向的位置
up vector: 從鏡頭看過去的朝上的方向
Field:畫面視野范圍(寬和高)

圖五 position, target, up vector,field
所以,當upvector設置成(1,0,0)時,就是把原圖的x軸正向設成了camera的朝上方向,就是將原圖逆時針旋轉90度的效果。同理,如果想把原圖順時針旋轉90度,就可以將upvector設成(-1,0,0)。
(完)
工程師必備
- 項目客服
- 培訓客服
- 平臺客服
TOP




















