SO3Engine
|
#include <SO3StereoManager.h>
Public Types | |
enum | StereoMode { SO3_NONE_STEREO = 0 , SO3_ANAGLYPH_RC_STEREO = 1 , SO3_ANAGLYPH_YB_STEREO = 2 , SO3_INTERLACED_V_STEREO = 3 , SO3_INTERLACED_H_STEREO = 4 , SO3_INTERLACED_CB_STEREO = 5 , SO3_SIDE_BY_SIDE_STEREO = 6 , SO3_UP_DOWN_STEREO = 7 , SO3_QUAD_BUFFER_STEREO = 8 , SO3_OCULUS_STEREO = 9 , SO3_OCULUS2_STEREO = 10 , SO3_CARDBOARD_STEREO = 11 , SO3_OPENVR_STEREO = 12 , SO3_OCULUSM_STEREO = 13 , SO3_OPENXR_STEREO = 14 , SO3_MONO_STEREO = 15 } |
Public Member Functions | |
StereoManager (SWindow *buffer) | |
~StereoManager () | |
void | ReloadStereo () |
void | RestoreStereoCamera (Ogre::Viewport *ogreViewportInstance) |
void | UpdateStereoCamera (Ogre::Viewport *ogreViewportInstance, Ogre::Camera *camera) |
void | UpdateStereoCameraMatrix (Ogre::Viewport *ogreViewportInstance, Ogre::Camera *camera) |
bool | UpdateStereoCompositorState (Ogre::Viewport *ogreViewportInstance, const Ogre::String compname, bool state) |
void | RegisterViewport (SViewPort *viewportInstance) |
void | UnregisterViewport (SViewPort *viewportInstance) |
void | SynchViewportSetup (SViewPort *viewportInstance, bool overlay=false, bool shadow=false) |
bool | IsViewportRegistered (Ogre::Viewport *ogreViewportInstance) |
StereoMode | GetStereoMode () const |
void | SetStereoMode (const StereoMode &newStereoMode) |
Ogre::Real | GetEyesSpacing () const |
void | SetEyesSpacing (Ogre::Real l) |
void | SetStereoProjectionOffset (Ogre::Real offset) |
void | SetStereoAspectRatio (Ogre::Real ratio) |
Ogre::Real | GetStereoAspectRatio () |
void | SetStereoFOVy (Ogre::Real fov) |
void | SetRotateView (bool state) |
bool | GetRotateView () |
void | SetStereoChromaticAbCorrection (bool enable, Ogre::Vector4 chromAbC) |
void | SetStereoDistortion (bool enable, Ogre::Vector4 dist) |
void | SetCustomProjectonMatrices (bool enable, const Ogre::Matrix4 &leftMatrix, const Ogre::Matrix4 &rightMatrix) |
void | GetCustomProjectonMatrices (bool &enabled, Ogre::Matrix4 &leftMatrix, Ogre::Matrix4 &rightMatrix) const |
void | SetTimeWarpMatrix (const Ogre::Matrix4 &leftStartMatrix, const Ogre::Matrix4 &leftEndMatrix, const Ogre::Matrix4 &rightStartMatrix, const Ogre::Matrix4 &rightEndMatrix) |
void | SetStereoMeshUVConfig (Ogre::Vector2 leftuvscale, Ogre::Vector2 leftuvoffset, Ogre::Vector2 rightuvscale, Ogre::Vector2 rightuvoffset) |
void | SetStereoMeshRttSize (SO3::SPoint< int > leftsize, SO3::SPoint< int > rightsize) |
void | SetStereoMeshLeft (std::vector< Ogre::Vector3 > vertices, std::vector< std::vector< Ogre::Vector2 > > uvs, std::vector< Ogre::Real > vignetteColor, std::vector< Ogre::Real > warp, std::vector< int > indexs) |
void | SetStereoMeshRight (std::vector< Ogre::Vector3 > vertices, std::vector< std::vector< Ogre::Vector2 > > uvs, std::vector< Ogre::Real > vignetteColor, std::vector< Ogre::Real > warp, std::vector< int > indexs) |
void | SetStereoWindow (SO3::SPoint< int > pos, SO3::SPoint< int > size, int index, bool state) |
std::array< SCOL_PTR_TYPE, 2 > | GetStereoTextures () |
std::array< SO3::SPoint< int >, 2 > | GetStereoViewportSize () |
Protected Member Functions | |
void | ReleaseRttTarget (StereoViewportData *viewportData) |
void | ConstructRttTarget (StereoViewportData *viewportData) |
Friends | |
class | DeviceLostListener |
class | StereoCameraListener |
class | StereoViewportListener |
class | StereoFrameListener |
Definition at line 50 of file SO3StereoManager.h.
Definition at line 53 of file SO3StereoManager.h.
SO3::StereoManager::StereoManager | ( | SWindow * | buffer | ) |
Constructor
Definition at line 66 of file SO3StereoManager.cpp.
SO3::StereoManager::~StereoManager | ( | ) |
Destructor
Definition at line 117 of file SO3StereoManager.cpp.
|
protected |
Definition at line 764 of file SO3StereoManager.cpp.
void SO3::StereoManager::GetCustomProjectonMatrices | ( | bool & | enabled, |
Ogre::Matrix4 & | leftMatrix, | ||
Ogre::Matrix4 & | rightMatrix | ||
) | const |
Definition at line 1226 of file SO3StereoManager.cpp.
Ogre::Real SO3::StereoManager::GetEyesSpacing | ( | ) | const |
Definition at line 1201 of file SO3StereoManager.cpp.
bool SO3::StereoManager::GetRotateView | ( | ) |
Definition at line 1768 of file SO3StereoManager.cpp.
Ogre::Real SO3::StereoManager::GetStereoAspectRatio | ( | ) |
Definition at line 1738 of file SO3StereoManager.cpp.
StereoManager::StereoMode SO3::StereoManager::GetStereoMode | ( | ) | const |
Retrieve the actual stereo mode.
Definition at line 122 of file SO3StereoManager.cpp.
std::array< SCOL_PTR_TYPE, 2 > SO3::StereoManager::GetStereoTextures | ( | ) |
Definition at line 1273 of file SO3StereoManager.cpp.
std::array< SO3::SPoint< int >, 2 > SO3::StereoManager::GetStereoViewportSize | ( | ) |
Definition at line 1308 of file SO3StereoManager.cpp.
bool SO3::StereoManager::IsViewportRegistered | ( | Ogre::Viewport * | ogreViewportInstance | ) |
Definition at line 445 of file SO3StereoManager.cpp.
void SO3::StereoManager::RegisterViewport | ( | SViewPort * | viewportInstance | ) |
Add stereo support for the given viewport.
Definition at line 422 of file SO3StereoManager.cpp.
|
protected |
Definition at line 673 of file SO3StereoManager.cpp.
void SO3::StereoManager::ReloadStereo | ( | ) |
Definition at line 127 of file SO3StereoManager.cpp.
void SO3::StereoManager::RestoreStereoCamera | ( | Ogre::Viewport * | ogreViewportInstance | ) |
Restore the camera properties
Definition at line 270 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetCustomProjectonMatrices | ( | bool | enable, |
const Ogre::Matrix4 & | leftMatrix, | ||
const Ogre::Matrix4 & | rightMatrix | ||
) |
Use a custom projections matrix for each eye
Definition at line 1211 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetEyesSpacing | ( | Ogre::Real | l | ) |
Definition at line 1206 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetRotateView | ( | bool | state | ) |
Definition at line 1756 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoAspectRatio | ( | Ogre::Real | ratio | ) |
Definition at line 1725 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoChromaticAbCorrection | ( | bool | enable, |
Ogre::Vector4 | chromAbC | ||
) |
Definition at line 1773 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoDistortion | ( | bool | enable, |
Ogre::Vector4 | dist | ||
) |
Definition at line 1787 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoFOVy | ( | Ogre::Real | fov | ) |
Definition at line 1743 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoMeshLeft | ( | std::vector< Ogre::Vector3 > | vertices, |
std::vector< std::vector< Ogre::Vector2 > > | uvs, | ||
std::vector< Ogre::Real > | vignetteColor, | ||
std::vector< Ogre::Real > | warp, | ||
std::vector< int > | indexs | ||
) |
Definition at line 1376 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoMeshRight | ( | std::vector< Ogre::Vector3 > | vertices, |
std::vector< std::vector< Ogre::Vector2 > > | uvs, | ||
std::vector< Ogre::Real > | vignetteColor, | ||
std::vector< Ogre::Real > | warp, | ||
std::vector< int > | indexs | ||
) |
Definition at line 1544 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoMeshRttSize | ( | SO3::SPoint< int > | leftsize, |
SO3::SPoint< int > | rightsize | ||
) |
Definition at line 1242 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoMeshUVConfig | ( | Ogre::Vector2 | leftuvscale, |
Ogre::Vector2 | leftuvoffset, | ||
Ogre::Vector2 | rightuvscale, | ||
Ogre::Vector2 | rightuvoffset | ||
) |
Definition at line 1233 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoMode | ( | const StereoMode & | newStereoMode | ) |
Sets the stereo mode to use.
Definition at line 174 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoProjectionOffset | ( | Ogre::Real | offset | ) |
Definition at line 1712 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetStereoWindow | ( | SO3::SPoint< int > | pos, |
SO3::SPoint< int > | size, | ||
int | index, | ||
bool | state | ||
) |
Definition at line 1331 of file SO3StereoManager.cpp.
void SO3::StereoManager::SetTimeWarpMatrix | ( | const Ogre::Matrix4 & | leftStartMatrix, |
const Ogre::Matrix4 & | leftEndMatrix, | ||
const Ogre::Matrix4 & | rightStartMatrix, | ||
const Ogre::Matrix4 & | rightEndMatrix | ||
) |
Definition at line 1218 of file SO3StereoManager.cpp.
void SO3::StereoManager::SynchViewportSetup | ( | SViewPort * | viewportInstance, |
bool | overlay = false , |
||
bool | shadow = false |
||
) |
Definition at line 454 of file SO3StereoManager.cpp.
void SO3::StereoManager::UnregisterViewport | ( | SViewPort * | viewportInstance | ) |
Remove stereo support for the given viewport.
Definition at line 434 of file SO3StereoManager.cpp.
void SO3::StereoManager::UpdateStereoCamera | ( | Ogre::Viewport * | ogreViewportInstance, |
Ogre::Camera * | camera | ||
) |
Update the camera properties
Definition at line 311 of file SO3StereoManager.cpp.
void SO3::StereoManager::UpdateStereoCameraMatrix | ( | Ogre::Viewport * | ogreViewportInstance, |
Ogre::Camera * | camera | ||
) |
Update the camera properties
Definition at line 392 of file SO3StereoManager.cpp.
bool SO3::StereoManager::UpdateStereoCompositorState | ( | Ogre::Viewport * | ogreViewportInstance, |
const Ogre::String | compname, | ||
bool | state | ||
) |
Definition at line 229 of file SO3StereoManager.cpp.
|
friend |
Definition at line 287 of file SO3StereoManager.h.
|
friend |
Definition at line 288 of file SO3StereoManager.h.
|
friend |
Definition at line 290 of file SO3StereoManager.h.
|
friend |
Definition at line 289 of file SO3StereoManager.h.