Review issues on OpenGL 1.1
This commit is contained in:
parent
10c2eea14b
commit
87b75a6c95
1 changed files with 4 additions and 0 deletions
|
@ -1429,8 +1429,10 @@ void rlClearScreenBuffers(void)
|
||||||
// Update GPU buffer with new data
|
// Update GPU buffer with new data
|
||||||
void rlUpdateBuffer(int bufferId, void *data, int dataSize)
|
void rlUpdateBuffer(int bufferId, void *data, int dataSize)
|
||||||
{
|
{
|
||||||
|
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
|
||||||
glBindBuffer(GL_ARRAY_BUFFER, bufferId);
|
glBindBuffer(GL_ARRAY_BUFFER, bufferId);
|
||||||
glBufferSubData(GL_ARRAY_BUFFER, 0, dataSize, data);
|
glBufferSubData(GL_ARRAY_BUFFER, 0, dataSize, data);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
//----------------------------------------------------------------------------------
|
//----------------------------------------------------------------------------------
|
||||||
|
@ -3533,6 +3535,7 @@ void CloseVrSimulator(void)
|
||||||
// Set stereo rendering configuration parameters
|
// Set stereo rendering configuration parameters
|
||||||
void SetVrConfiguration(VrDeviceInfo hmd, Shader distortion)
|
void SetVrConfiguration(VrDeviceInfo hmd, Shader distortion)
|
||||||
{
|
{
|
||||||
|
#if defined(GRAPHICS_API_OPENGL_33) || defined(GRAPHICS_API_OPENGL_ES2)
|
||||||
// Reset vrConfig for a new values assignment
|
// Reset vrConfig for a new values assignment
|
||||||
memset(&vrConfig, 0, sizeof(vrConfig));
|
memset(&vrConfig, 0, sizeof(vrConfig));
|
||||||
|
|
||||||
|
@ -3610,6 +3613,7 @@ void SetVrConfiguration(VrDeviceInfo hmd, Shader distortion)
|
||||||
SetShaderValue(vrConfig.distortionShader, GetShaderLocation(vrConfig.distortionShader, "hmdWarpParam"), hmd.lensDistortionValues, UNIFORM_VEC4);
|
SetShaderValue(vrConfig.distortionShader, GetShaderLocation(vrConfig.distortionShader, "hmdWarpParam"), hmd.lensDistortionValues, UNIFORM_VEC4);
|
||||||
SetShaderValue(vrConfig.distortionShader, GetShaderLocation(vrConfig.distortionShader, "chromaAbParam"), hmd.chromaAbCorrection, UNIFORM_VEC4);
|
SetShaderValue(vrConfig.distortionShader, GetShaderLocation(vrConfig.distortionShader, "chromaAbParam"), hmd.chromaAbCorrection, UNIFORM_VEC4);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
// Detect if VR simulator is running
|
// Detect if VR simulator is running
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue