Merge branch 'master' of github.com:supertuxkart/stk-code
This commit is contained in:
@@ -21,6 +21,7 @@
|
||||
#endif
|
||||
#include <GL/gl.h>
|
||||
#if defined(_IRR_OPENGL_USE_EXTPOINTER_)
|
||||
typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode);
|
||||
#include "glext.h"
|
||||
#endif
|
||||
#include "wglext.h"
|
||||
@@ -36,6 +37,7 @@
|
||||
#endif
|
||||
#include <OpenGL/gl.h>
|
||||
#if defined(_IRR_OPENGL_USE_EXTPOINTER_)
|
||||
typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode);
|
||||
#include "glext.h"
|
||||
#endif
|
||||
#elif defined(_IRR_COMPILE_WITH_SDL_DEVICE_) && !defined(_IRR_COMPILE_WITH_X11_DEVICE_)
|
||||
@@ -49,6 +51,7 @@
|
||||
#define NO_SDL_GLEXT
|
||||
#include <SDL/SDL_video.h>
|
||||
#include <SDL/SDL_opengl.h>
|
||||
typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode);
|
||||
#include "glext.h"
|
||||
#else
|
||||
#if defined(_IRR_OPENGL_USE_EXTPOINTER_)
|
||||
@@ -61,6 +64,7 @@
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glx.h>
|
||||
#if defined(_IRR_OPENGL_USE_EXTPOINTER_)
|
||||
typedef void (APIENTRYP PFNGLBLENDEQUATIONPROC) (GLenum mode);
|
||||
#include <GL/glext.h>
|
||||
#undef GLX_ARB_get_proc_address // avoid problems with local glxext.h
|
||||
#include <GL/glxext.h>
|
||||
|
||||
@@ -618,7 +618,7 @@ namespace UserConfigParams
|
||||
&m_graphics_quality,
|
||||
"Whether vertical sync is enabled") );
|
||||
PARAM_PREFIX BoolUserConfigParam m_pixel_shaders
|
||||
PARAM_DEFAULT( BoolUserConfigParam(true, "pixel_shaders",
|
||||
PARAM_DEFAULT( BoolUserConfigParam(false, "pixel_shaders",
|
||||
&m_graphics_quality,
|
||||
"Whether to enable pixel shaders (splatting, normal maps, ...)") );
|
||||
PARAM_PREFIX BoolUserConfigParam m_motionblur
|
||||
|
||||
@@ -421,10 +421,11 @@ void IrrDriver::initDevice()
|
||||
m_gui_env = m_device->getGUIEnvironment();
|
||||
m_video_driver = m_device->getVideoDriver();
|
||||
|
||||
int GLMajorVersion;
|
||||
int GLMajorVersion = 0, GLMinorVersion = 0;
|
||||
glGetIntegerv(GL_MAJOR_VERSION, &GLMajorVersion);
|
||||
printf("OPENGL VERSION IS %d\n", GLMajorVersion);
|
||||
m_glsl = (GLMajorVersion >= 3) && UserConfigParams::m_pixel_shaders;
|
||||
glGetIntegerv(GL_MINOR_VERSION, &GLMinorVersion);
|
||||
Log::info("IrrDriver", "OPENGL VERSION IS %d.%d", GLMajorVersion, GLMinorVersion);
|
||||
m_glsl = (GLMajorVersion > 3 || (GLMajorVersion == 3 && GLMinorVersion == 3)) && UserConfigParams::m_pixel_shaders;
|
||||
|
||||
|
||||
// This remaps the window, so it has to be done before the clear to avoid flicker
|
||||
|
||||
@@ -175,7 +175,6 @@ void drawObjectPass1(const GLMesh &mesh, const core::matrix4 & ModelViewProjecti
|
||||
|
||||
void drawObjectRefPass1(const GLMesh &mesh, const core::matrix4 & ModelViewProjectionMatrix, const core::matrix4 &TransposeInverseModelView)
|
||||
{
|
||||
glDisable(GL_CULL_FACE);
|
||||
GLenum ptype = mesh.PrimitiveType;
|
||||
GLenum itype = mesh.IndexType;
|
||||
size_t count = mesh.IndexCount;
|
||||
@@ -188,7 +187,6 @@ void drawObjectRefPass1(const GLMesh &mesh, const core::matrix4 & ModelViewProje
|
||||
|
||||
glBindVertexArray(mesh.vao_first_pass);
|
||||
glDrawElements(ptype, count, itype, 0);
|
||||
glEnable(GL_CULL_FACE);
|
||||
}
|
||||
|
||||
void drawGrassPass1(const GLMesh &mesh, const core::matrix4 & ModelViewProjectionMatrix, const core::matrix4 &TransposeInverseModelView, core::vector3df windDir)
|
||||
@@ -326,7 +324,6 @@ void drawSplatting(const GLMesh &mesh, const core::matrix4 &ModelViewProjectionM
|
||||
|
||||
void drawObjectRefPass2(const GLMesh &mesh, const core::matrix4 &ModelViewProjectionMatrix)
|
||||
{
|
||||
glDisable(GL_CULL_FACE);
|
||||
GLenum ptype = mesh.PrimitiveType;
|
||||
GLenum itype = mesh.IndexType;
|
||||
size_t count = mesh.IndexCount;
|
||||
@@ -356,7 +353,6 @@ void drawObjectRefPass2(const GLMesh &mesh, const core::matrix4 &ModelViewProjec
|
||||
|
||||
glBindVertexArray(mesh.vao_second_pass);
|
||||
glDrawElements(ptype, count, itype, 0);
|
||||
glEnable(GL_CULL_FACE);
|
||||
}
|
||||
|
||||
void drawGrassPass2(const GLMesh &mesh, const core::matrix4 & ModelViewProjectionMatrix, core::vector3df windDir)
|
||||
|
||||
@@ -76,7 +76,7 @@ void HighscoreManager::loadHighscores()
|
||||
saveHighscores();
|
||||
if(m_can_write)
|
||||
{
|
||||
Log::error("Highscore Manager", "New highscore file '%s' created.\n",
|
||||
Log::info("Highscore Manager", "New highscore file '%s' created.\n",
|
||||
m_filename.c_str());
|
||||
}
|
||||
delete root;
|
||||
|
||||
Reference in New Issue
Block a user