Fixing some bugs in the OSX HMD detection and GL rendering

This commit is contained in:
Brad Davis 2014-08-06 22:48:10 -07:00
parent 5447d1c28e
commit 4a9a2f619d
2 changed files with 4 additions and 4 deletions

View File

@ -293,7 +293,7 @@ DistortionRenderer::GraphicsState::GraphicsState()
char prefix[64];
bool foundVersion = false;
for (int i = 10; i < 30; ++i)
for (int i = 10; i < 40; ++i)
{
int major = i / 10;
int minor = i % 10;
@ -310,7 +310,7 @@ DistortionRenderer::GraphicsState::GraphicsState()
if (!foundVersion)
{
glGetIntegerv(GL_MAJOR_VERSION, &GlMajorVersion);
glGetIntegerv(GL_MAJOR_VERSION, &GlMinorVersion);
glGetIntegerv(GL_MINOR_VERSION, &GlMinorVersion);
}
OVR_ASSERT(GlMajorVersion >= 2);
@ -689,7 +689,7 @@ void DistortionRenderer::initShaders()
} else if (glState->GlMajorVersion < 4 || (glState->GlMajorVersion == 4 && glState->GlMinorVersion < 4)) {
shaderPrefix = glsl3Prefix;
} else {
shaderPrefix = glsl4Prefix;
shaderPrefix = glsl3Prefix;
}
{

View File

@ -229,7 +229,7 @@ void HMDDeviceFactory::EnumerateDevices(EnumerateVisitor& visitor)
if (product == 3)
{ // DK2 prototypes and variants (default to HmdType_DK2)
hmdCreateDesc.SetScreenParameters(desktop.origin.x, desktop.origin.y,
1920, 1080, 0.12576f, 0.07074f, 0.12576f*0.5f, 0.0635f );
1920, 1080, 0.12576f, 0.07074f, 0.07074f*0.5f, 0.0635f );
}
else if (product == 2)
{ // HD Prototypes (default to HmdType_DKHDProto)