Glossary of view transformations
Glossary of view transformations
The following terms are used to define view orientation, i.e. transformation from World Coordinates (WC) to the View Reference Coordinates system (VRC):
- View Reference Point (VRP) - defines the origin of View Reference Coordinates.
- View Reference Plane Normal (VPN) - defines the normal of projection plane of the view.
- View Reference Up Vector (VUP) - defines the vertical of observer of the view.
The following terms are used to define view mapping, i.e. transformation from View Reference Coordinates (VRC) to the Normalized Projection Coordinates (NPC):
- Projection type - Orthographic or perspective.
- Projection Reference Point (PRP) - Defines the observer position.
- Front Plane Distance (FPD) - Defines the position of the front clipping plane in View Reference Coordinates system.
- Back Plane Distance (BPD) Defines the position of the back clipping plane in View Reference Coordinates system.
- View Plane Distance (VPD) Defines the position of the view projection plane in View Reference Coordinates system. View plane must be located between front and back clipping planes.
- Window Limits Defines the visible part of the view projection plane (left, right, top and bottom boundaries: Umin, Umax, Vmax and Vmin respectively) in View Reference Coordinates.
The V3d_View API uses the following terms to define view orientation and mapping:
- At - Position of View Reference Point (VRP) in World Coordinates
- Eye - Position of the observer (projection reference point) in World Coordinates. Influences to the view projection vector and depth value.
- Proj - View projection vector (VPN)
- Up - Position of the high point / view up vector (VUP)
- Depth - Distance between Eye and At point
- ZSize - Distance between front and back clipping planes
- Size - Window size in View Reference Coordinates
- Focal Reference point - Position of Projection Reference Point (PRP) in World Coordinates
- Focale - Distance between Projection Reference Point (PRP) and View projection plane
Management of perspective projection
The perspective projection allows definition of viewing volume as a truncated pyramid (frustum) with apex at the Projection Reference Point. In the View Reference Coordinate system it can be presented by the following picture:
During panning, window limits are changed, as if a sort of "frame" through which the user sees a portion of the view plane was moved over the view. The perspective frustum itself remains unchanged.
The perspective projection is defined by two parameters:
- Depth value defines distance between Projection Reference Point and the nearest (front) clipping plane.
- ZSize defines distance between Front and Back clipping planes. The influence of this parameter is caused by the OCCT specific to center viewing volume around View Reference Point so the front and back plane distances were the same: FPD = BPD = ZSize / 2.
Note that the closer the displayed object to the Projection Reference Point the more visible its perspective distortion. Thus, in order to get a good perspective it is recommended to set ZSize value comparable with the expected model size and small Depth value.
However, very small Depth values might lead to inaccuracy of "fit all" operation and to non-realistic perspective distortion.
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 基于Microsoft.Extensions.AI核心库实现RAG应用
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· 震惊!C++程序真的从main开始吗?99%的程序员都答错了
· 【硬核科普】Trae如何「偷看」你的代码?零基础破解AI编程运行原理
· 单元测试从入门到精通
· 上周热点回顾(3.3-3.9)
· winform 绘制太阳,地球,月球 运作规律