SLProject 4.0.000
SLGLOVRWorkaround.h File Reference
#include <SLGLOculus.h>
#include <SLGLVertexArray.h>
#include <SLScene.h>
Include dependency graph for SLGLOVRWorkaround.h:
This graph shows which files directly or indirectly include this file:

Classes

struct  LensConfig
 
struct  ovrSizei
 
struct  ovrSizef
 
struct  HmdRenderInfo
 
struct  HmdRenderInfo::ShutterInfo
 
struct  HmdRenderInfo::EyeConfig
 
struct  DistortionRenderDesc
 
struct  ovrDistortionVertex_
 
struct  ovrDistortionMesh_
 
struct  DistortionMeshVertexData
 
struct  ovrFovPort_
 
struct  ScaleAndOffset2D
 

Macros

#define TPH_SPLINE_STATISTICS   0
 

Typedefs

typedef struct ovrDistortionVertex_ ovrDistortionVertex
 
typedef struct ovrDistortionMesh_ ovrDistortionMesh
 
typedef struct ovrFovPort_ ovrFovPort
 

Enumerations

enum  DistortionEqnType { Distortion_No_Override = -1 , Distortion_Poly4 = 0 , Distortion_RecipPoly4 = 1 , Distortion_CatmullRom10 = 2 , Distortion_LAST }
 
enum  HmdTypeEnum {
  HmdType_None , HmdType_DKProto , HmdType_DK1 , HmdType_DKHDProto , HmdType_DKHD2Proto , HmdType_DKHDProto566Mi ,
  HmdType_CrystalCoveProto , HmdType_DK2 , HmdType_Unknown , HmdType_LAST
}
 
enum  HmdShutterTypeEnum { HmdShutteRT_global , HmdShutter_RollingTopToBottom , HmdShutter_RollingLeftToRight , HmdShutter_RollingRightToLeft , HmdShutter_LAST }
 
enum  EyeCupType {
  EyeCup_DK1A = 0 , EyeCup_DK1B = 1 , EyeCup_DK1C = 2 , EyeCup_DK2A = 3 , EyeCup_DKHD2A , EyeCup_OrangeA ,
  EyeCup_RedA , EyeCup_PinkA , EyeCup_BlueA , EyeCup_Delilah1A , EyeCup_Delilah2A , EyeCup_JamesA ,
  EyeCup_SunMandalaA , EyeCup_LAST
}
 
enum  { NumCoefficients = 11 }
 

Functions

bool FitCubicPolynomial (float *pResult, const float *pFitX, const float *pFitY)
 
float EvalCatmullRom10Spline (float const *K, float scaledVal)
 
SLMat4f ovrMatrix4f_OrthoSubProjection (SLMat4f projection, SLVec2f orthoScale, float orthoDistance, float eyeViewAdjustX)
 
SLVec2f TransformTanFovSpaceToScreenNDC (DistortionRenderDesc const &distortion, const SLVec2f &tanEyeAngle, bool usePolyApprox)
 
void TransformScreenNDCToTanFovSpaceChroma (SLVec2f *resultR, SLVec2f *resultG, SLVec2f *resultB, DistortionRenderDesc const &distortion, const SLVec2f &framebufferNDC)
 
SLVec2f TransformTanFovSpaceToRendertargetNDC (ScaleAndOffset2D const &eyeToSourceNDC, SLVec2f const &tanEyeAngle)
 
SLVec2f TransformRendertargetNDCToTanFovSpace (const ScaleAndOffset2D &eyeToSourceNDC, const SLVec2f &textureNDC)
 
ScaleAndOffset2D CreateNDCScaleAndOffsetFromFov (ovrFovPort tanHalfFov)
 
SLMat4f CreateProjection (bool rightHanded, ovrFovPort tanHalfFov, float zNear, float zFar)
 
void createSLDistortionMesh (DistortionMeshVertexData **ppVertices, uint16_t **ppTriangleListIndices, SLuint *pNumVertices, SLuint *pNumTriangles, bool rightEye, const HmdRenderInfo &hmdRenderInfo, const DistortionRenderDesc &distortion, const ScaleAndOffset2D &eyeToSourceNDC)
 
void createSLDistortionMesh (SLGLProgram *stereoOculusDistProgram, SLEyeType eye, SLGLVertexArray &vao)
 

Macro Definition Documentation

◆ TPH_SPLINE_STATISTICS

#define TPH_SPLINE_STATISTICS   0

Typedef Documentation

◆ ovrDistortionMesh

◆ ovrDistortionVertex

◆ ovrFovPort

typedef struct ovrFovPort_ ovrFovPort

Enumeration Type Documentation

◆ anonymous enum

anonymous enum
Enumerator
NumCoefficients 

◆ DistortionEqnType

Enumerator
Distortion_No_Override 
Distortion_Poly4 
Distortion_RecipPoly4 
Distortion_CatmullRom10 
Distortion_LAST 

◆ EyeCupType

enum EyeCupType
Enumerator
EyeCup_DK1A 
EyeCup_DK1B 
EyeCup_DK1C 
EyeCup_DK2A 
EyeCup_DKHD2A 
EyeCup_OrangeA 
EyeCup_RedA 
EyeCup_PinkA 
EyeCup_BlueA 
EyeCup_Delilah1A 
EyeCup_Delilah2A 
EyeCup_JamesA 
EyeCup_SunMandalaA 
EyeCup_LAST 

◆ HmdShutterTypeEnum

Enumerator
HmdShutteRT_global 
HmdShutter_RollingTopToBottom 
HmdShutter_RollingLeftToRight 
HmdShutter_RollingRightToLeft 
HmdShutter_LAST 

◆ HmdTypeEnum

Enumerator
HmdType_None 
HmdType_DKProto 
HmdType_DK1 
HmdType_DKHDProto 
HmdType_DKHD2Proto 
HmdType_DKHDProto566Mi 
HmdType_CrystalCoveProto 
HmdType_DK2 
HmdType_Unknown 
HmdType_LAST 

Function Documentation

◆ CreateNDCScaleAndOffsetFromFov()

ScaleAndOffset2D CreateNDCScaleAndOffsetFromFov ( ovrFovPort  tanHalfFov)

◆ CreateProjection()

SLMat4f CreateProjection ( bool  rightHanded,
ovrFovPort  tanHalfFov,
float  zNear,
float  zFar 
)

◆ createSLDistortionMesh() [1/2]

void createSLDistortionMesh ( DistortionMeshVertexData **  ppVertices,
uint16_t **  ppTriangleListIndices,
SLuint pNumVertices,
SLuint pNumTriangles,
bool  rightEye,
const HmdRenderInfo hmdRenderInfo,
const DistortionRenderDesc distortion,
const ScaleAndOffset2D eyeToSourceNDC 
)

◆ createSLDistortionMesh() [2/2]

void createSLDistortionMesh ( SLGLProgram stereoOculusDistProgram,
SLEyeType  eye,
SLGLVertexArray vao 
)

◆ EvalCatmullRom10Spline()

float EvalCatmullRom10Spline ( float const *  K,
float  scaledVal 
)

◆ FitCubicPolynomial()

bool FitCubicPolynomial ( float *  pResult,
const float *  pFitX,
const float *  pFitY 
)

◆ ovrMatrix4f_OrthoSubProjection()

SLMat4f ovrMatrix4f_OrthoSubProjection ( SLMat4f  projection,
SLVec2f  orthoScale,
float  orthoDistance,
float  eyeViewAdjustX 
)

◆ TransformRendertargetNDCToTanFovSpace()

SLVec2f TransformRendertargetNDCToTanFovSpace ( const ScaleAndOffset2D eyeToSourceNDC,
const SLVec2f textureNDC 
)

◆ TransformScreenNDCToTanFovSpaceChroma()

void TransformScreenNDCToTanFovSpaceChroma ( SLVec2f resultR,
SLVec2f resultG,
SLVec2f resultB,
DistortionRenderDesc const &  distortion,
const SLVec2f framebufferNDC 
)

◆ TransformTanFovSpaceToRendertargetNDC()

SLVec2f TransformTanFovSpaceToRendertargetNDC ( ScaleAndOffset2D const &  eyeToSourceNDC,
SLVec2f const &  tanEyeAngle 
)

◆ TransformTanFovSpaceToScreenNDC()

SLVec2f TransformTanFovSpaceToScreenNDC ( DistortionRenderDesc const &  distortion,
const SLVec2f tanEyeAngle,
bool  usePolyApprox 
)