Monado OpenXR Runtime
Data Fields
xrt_view Struct Reference

A per-lens view information. More...

#include <xrt/xrt_device.h>

Collaboration diagram for xrt_view:
Collaboration graph
[legend]

Data Fields

struct {
   uint32_t   x_pixels
 
   uint32_t   y_pixels
 
   uint32_t   w_pixels
 
   uint32_t   h_pixels
 
viewport
 Viewpport position on the screen, in absolute screen coordinates, this field is only used by Compositor to setup the device rendering. More...
 
struct {
   uint32_t   w_pixels
 
   uint32_t   h_pixels
 
   float   w_meters
 
   float   h_meters
 
display
 Pixel and phyisical properties of this display, not in absolute screen coordinates that the compositor sees. More...
 
struct {
   float   x_meters
 
   float   y_meters
 
lens_center
 Position in meters relative to display origin, before any rotation is applied by xrt_view::rot. More...
 
struct xrt_matrix_2x2 rot
 Rotation 2d matrix used to rotate the position of the output of the distortion shaders onto the screen. More...
 
struct xrt_fov fov
 Fov expressed in OpenXR. More...
 

Detailed Description

A per-lens view information.

Field Documentation

◆ display

struct { ... } xrt_view::display

Pixel and phyisical properties of this display, not in absolute screen coordinates that the compositor sees.

So before any rotation is applied by xrt_view::rot.

The xrt_view::display::w_pixels & xrt_view::display::h_pixels become the recommdnded image size for this view.

◆ fov

struct xrt_fov xrt_view::fov

Fov expressed in OpenXR.

◆ lens_center

struct { ... } xrt_view::lens_center

Position in meters relative to display origin, before any rotation is applied by xrt_view::rot.

◆ rot

struct xrt_matrix_2x2 xrt_view::rot

Rotation 2d matrix used to rotate the position of the output of the distortion shaders onto the screen.

Should the distortion shader be based on mesh then this matrix rotates the vertex positions.

◆ viewport

struct { ... } xrt_view::viewport

Viewpport position on the screen, in absolute screen coordinates, this field is only used by Compositor to setup the device rendering.

If the view is being rotated by xrt_view.rot 90° right in the distortion shader then display.w_pixels == viewport.h_pixels & display.h_pixels == viewport.w_pixels.


The documentation for this struct was generated from the following file: