FLUENT中用camera parameter将视图精确旋转90度



不知道你有没有和我一样被CameraParameters窗口下的那个调整视图的小箭头(图一)给弄得抓狂过。不管怎么拖动,都很难把视图精确旋转90度。

0.png

                               图一 Camera Parameters窗口

用小箭头调出来的视图往往不是整90度,总会有点儿偏斜(图二)。

1.jpg


                    图二   原图                                    用小箭头调整的视图 



其实有更容易的方法来将视图精确旋转90度。如图三所示,在左侧的camera下拉菜单选择up vector,将x,y,z设置为(1,0,0),然后点击下面的Apply按钮。视图就会变成图四那样的完美90度旋转。

2.png


                                    图三 精确逆时针旋转90度的设置方法

3.png


                             图四  精确逆时针旋转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:画面视野范围(宽和高)

4.png

                    图五  position, target, up vector,field

所以,当upvector设置成(1,0,0)时,就是把原图的x轴正向设成了camera的朝上方向,就是将原图逆时针旋转90度的效果。同理,如果想把原图顺时针旋转90度,就可以将upvector设成(-1,0,0)。

 

(完)

登录后免费查看全文
立即登录
App下载
技术邻APP
工程师必备
  • 项目客服
  • 培训客服
  • 平台客服

TOP