Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMitchell Stokes <mogurijin@gmail.com>2014-03-31 05:35:02 +0400
committerMitchell Stokes <mogurijin@gmail.com>2015-12-08 06:25:12 +0300
commit964107fbce77fac3badf2de027e6096cc8efe7ca (patch)
tree0a46a17d7c07acfb9e4fb7f99a88ad1973297568 /source/gameengine/Ketsji/KX_PythonInit.cpp
parentfe2f3a131d96e4b0d1c85e1379b30c73f6378ffd (diff)
BGE code cleanup: Removing RAS_GLExtensionManager.
This class did nothing but print out extensions if they were found. Instead, the code from bge.logic.PrintGLInfo() is now printed as the Rasterizer is initialized. This gives better information, and it removes some GL code from KX_PythonInit.cpp (the PrintGLInfo method now calls the Rasterizer to print the information). Differential Revision: https://developer.blender.org/D438
Diffstat (limited to 'source/gameengine/Ketsji/KX_PythonInit.cpp')
-rw-r--r--source/gameengine/Ketsji/KX_PythonInit.cpp69
1 files changed, 4 insertions, 65 deletions
diff --git a/source/gameengine/Ketsji/KX_PythonInit.cpp b/source/gameengine/Ketsji/KX_PythonInit.cpp
index 26c6fcaa928..d35f09dd820 100644
--- a/source/gameengine/Ketsji/KX_PythonInit.cpp
+++ b/source/gameengine/Ketsji/KX_PythonInit.cpp
@@ -647,71 +647,10 @@ static PyObject *pyPrintStats(PyObject *,PyObject *,PyObject *)
static PyObject *pyPrintExt(PyObject *,PyObject *,PyObject *)
{
-#define pprint(x) std::cout << x << std::endl;
- bool count=0;
- bool support=0;
- pprint("Supported Extensions...");
- pprint(" GL_ARB_shader_objects supported? "<< (GLEW_ARB_shader_objects?"yes.":"no."));
- count = 1;
-
- support= GLEW_ARB_vertex_shader;
- pprint(" GL_ARB_vertex_shader supported? "<< (support?"yes.":"no."));
- count = 1;
- if (support) {
- pprint(" ----------Details----------");
- int max=0;
- glGetIntegerv(GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB, (GLint*)&max);
- pprint(" Max uniform components." << max);
-
- glGetIntegerv(GL_MAX_VARYING_FLOATS_ARB, (GLint*)&max);
- pprint(" Max varying floats." << max);
-
- glGetIntegerv(GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB, (GLint*)&max);
- pprint(" Max vertex texture units." << max);
-
- glGetIntegerv(GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB, (GLint*)&max);
- pprint(" Max combined texture units." << max);
- pprint("");
- }
-
- support=GLEW_ARB_fragment_shader;
- pprint(" GL_ARB_fragment_shader supported? "<< (support?"yes.":"no."));
- count = 1;
- if (support) {
- pprint(" ----------Details----------");
- int max=0;
- glGetIntegerv(GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB, (GLint*)&max);
- pprint(" Max uniform components." << max);
- pprint("");
- }
-
- support = GLEW_ARB_texture_cube_map;
- pprint(" GL_ARB_texture_cube_map supported? "<< (support?"yes.":"no."));
- count = 1;
- if (support) {
- pprint(" ----------Details----------");
- int size=0;
- glGetIntegerv(GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB, (GLint*)&size);
- pprint(" Max cubemap size." << size);
- pprint("");
- }
-
- support = GLEW_ARB_multitexture;
- count = 1;
- pprint(" GL_ARB_multitexture supported? "<< (support?"yes.":"no."));
- if (support) {
- pprint(" ----------Details----------");
- int units=0;
- glGetIntegerv(GL_MAX_TEXTURE_UNITS_ARB, (GLint*)&units);
- pprint(" Max texture units available. " << units);
- pprint("");
- }
-
- pprint(" GL_ARB_texture_env_combine supported? "<< (GLEW_ARB_texture_env_combine?"yes.":"no."));
- count = 1;
-
- if (!count)
- pprint("No extenstions are used in this build");
+ if (gp_Rasterizer)
+ gp_Rasterizer->PrintHardwareInfo();
+ else
+ printf("Warning: no rasterizer detected for PrintGLInfo!\n");
Py_RETURN_NONE;
}