Version: 2022.3
언어: 한국어

CameraProjectionCache

struct in UnityEditor

매뉴얼로 전환

설명

Project points from world to screen space.

Projection from world to screen space depends on internal camera matrices that Unity must recalculate whenever they are accessed. When accessed in a loop where the camera state does not change, these calculations are not necessary, which results in significant performance improvements.

생성자

CameraProjectionCacheCreates a CameraProjectionCache with the camera's current state.

Public 함수

GUIToScreenPointConverts a point from GUI position to screen space relative to the cached camera viewport.
ScreenToGUIPointConverts a point from screen space to GUI position relative to the viewport at the time the CameraProjectionCache was created.
WorldToGUIPointConverts a world space point to a 2D GUI position.
WorldToScreenPointTransforms position from world space into screen space using the cached camera projection and viewport.
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961