CalculateDisplayMatrix
Declaration
public static Matrix4x4 CalculateDisplayMatrix(int imageWidth, int imageHeight, int viewportWidth, int viewportHeight, ScreenOrientation viewportOrientation, bool invertVertically = true, MatrixLayout layout = MatrixLayout.ColumnMajor, bool reverseRotation = false)
Parameters
| Name | Type | Summary |
|---|---|---|
| imageWidth | int | The width of the raw AR background image in pixels. |
| imageHeight | int | The height of the raw AR background image in pixels. |
| viewportWidth | int | The width of the viewport in pixels. |
| viewportHeight | int | The height of the viewport in pixels. |
| viewportOrientation | ScreenOrientation | The orientation of the viewport. |
| invertVertically | bool | Whether to mirror the image across the X axis. This reverses the order of the horizontal rows, flipping the image upside down. |
| layout | MatrixLayout | The layout of the resulting matrix. |
| reverseRotation | bool | On some platforms, the direction of UI rotation is counter-clockwise. |