Ocean
Loading...
Searching...
No Matches
OpenGLFrameMediumViewController Class Reference

The OpenGLViewController implements a view controller that is mainly able to display medium objects. More...

#include <OpenGLFrameMediumViewController.h>

Inheritance diagram for OpenGLFrameMediumViewController:

Instance Methods

(void) - setFrameMedium:
 Sets or changes the frame medium to be displayed.
 
(void) - setFrameMedium:andAdjustFov:
 Sets or changes the frame medium to be displayed.
 
(void) - setFrameMedium:withRotation:
 Sets or changes the frame medium to be displayed.
 
(void) - setFrameMedium:withRotation:andAdjustFov:
 Sets or changes the frame medium to be displayed.
 
(Ocean::Media::FrameMediumRef- frameMedium
 Returns the current frame medium.
 
(CGPoint) - view2medium:
 Converts a 2D location defined in the view's coordinate system to a location defined in the coordinate system of the medium (an image frame).
 
(void) - update
 Updates the rendering engine.
 
- Instance Methods inherited from OpenGLViewController
(void) - makeOpenGLContextCurrent
 Makes the OpenGL context of this controller the current context.
 

Protected Attributes

Ocean::Rendering::EngineRef renderingEngine_
 The rendering engine to be used.
 
Ocean::Rendering::FramebufferRef renderingFramebuffer_
 The framebuffer in which the result will be rendered.
 
Ocean::Rendering::PerspectiveViewRef renderingView_
 The rendering view.
 
Ocean::Rendering::UndistortedBackgroundRef renderingUndistortedBackground_
 The undistorted background.
 
bool adjustFovXToBackground_
 State determining that the view's field of view has to be adjusted to the background's field of view.
 

Detailed Description

The OpenGLViewController implements a view controller that is mainly able to display medium objects.

The view controller is derived from an OpenGLES view controller so that we can ensure the best performance possible.
This class can be seen as a FrameMediumView equivalent using OpenGLES.

See also
Apple::MacOS::FrameMediumView.

Method Documentation

◆ frameMedium

- Media:

Returns the current frame medium.

Returns
The frame medium which is currently displayed

◆ setFrameMedium:

- (void) setFrameMedium: (const Ocean::Media::FrameMediumRef &)  frameMedium

Sets or changes the frame medium to be displayed.

Parameters
frameMediumThe frame medium to be displayed, must be valid

◆ setFrameMedium:andAdjustFov:

- (void) setFrameMedium: (const Ocean::Media::FrameMediumRef &)  frameMedium
andAdjustFov: (bool)  adjustFov 

Sets or changes the frame medium to be displayed.

Parameters
frameMediumThe frame medium to be displayed, must be valid
adjustFovTrue, to adjust the view's field of view to the medium's field of view; False, to keep the view's field of view as is

◆ setFrameMedium:withRotation:

- (void) setFrameMedium: (const Ocean::Media::FrameMediumRef &)  frameMedium
withRotation: (const Ocean::Quaternion &)  display_R_medium 

Sets or changes the frame medium to be displayed.

Parameters
frameMediumThe frame medium to be displayed, must be valid
display_R_mediumExplicit rotation between medium and display, and invalid rotation to use the medium's and framebuffer's transformations to determine the rotation

◆ setFrameMedium:withRotation:andAdjustFov:

- (void) setFrameMedium: (const Ocean::Media::FrameMediumRef &)  frameMedium
withRotation: (const Ocean::Quaternion &)  display_R_medium
andAdjustFov: (bool)  adjustFov 

Sets or changes the frame medium to be displayed.

Parameters
frameMediumThe frame medium to be displayed, must be valid
display_R_mediumExplicit rotation between medium and display, and invalid rotation to use the medium's and framebuffer's transformations to determine the rotation
adjustFovTrue, to adjust the view's field of view to the medium's field of view; False, to keep the view's field of view as is

◆ update

- (void) update

Updates the rendering engine.

◆ view2medium:

- (CGPoint) view2medium: (CGPoint)  viewPoint

Converts a 2D location defined in the view's coordinate system to a location defined in the coordinate system of the medium (an image frame).

Parameters
viewPointThe 2D location within this view
Returns
The corresponding 2D location within the image frame of the medium, a negative coordinate (-1, -1), in case no valid mapping exists

Field Documentation

◆ adjustFovXToBackground_

- (bool) adjustFovXToBackground_
protected

State determining that the view's field of view has to be adjusted to the background's field of view.

Provided by category OpenGLFrameMediumViewController().

◆ renderingEngine_

- Rendering:
protected

The rendering engine to be used.

Provided by category OpenGLFrameMediumViewController().

◆ renderingFramebuffer_

- Rendering:
protected

The framebuffer in which the result will be rendered.

Provided by category OpenGLFrameMediumViewController().

◆ renderingUndistortedBackground_

- Rendering:
protected

The undistorted background.

Provided by category OpenGLFrameMediumViewController().

◆ renderingView_

- Rendering:
protected

The rendering view.

Provided by category OpenGLFrameMediumViewController().


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