Function gvr_sys::gvr_get_recommended_buffer_viewports [] [src]

pub unsafe extern "C" fn gvr_get_recommended_buffer_viewports(
    gvr: *const gvr_context,
    viewport_list: *mut gvr_buffer_viewport_list
)

Gets the recommended buffer viewport configuration, populating a previously allocated gvr_buffer_viewport_list object. The updated values include the per-eye recommended viewport and field of view for the target.

When the recommended viewports are used for distortion rendering, this method should always be called after calling refresh_viewer_profile(). That will ensure that the populated viewports reflect the currently paired viewer.

This function assumes that the client is not using multiview to render to multiple layers simultaneously.

@param gvr Pointer to the gvr instance from which to get the viewports. @param viewport_list Pointer to a previously allocated viewport list. This will be populated with the recommended buffer viewports and resized if necessary.