mirror of
https://github.com/glest/glest-source.git
synced 2025-09-29 00:48:58 +02:00
- got built in memory leak working. Just edit leak_dumper.h and uncomment:
//#define SL_LEAK_DUMP - got better / more accurate stack dumps when we detect errors in game. - Both of these need to be worked on in windows next, win32 may not compile for now until i fix it on that platform. - BE VERY CAREFUL when working in leak_dumper.* it may cause GCC and your system to crash if you don't know what you are doing!
This commit is contained in:
@@ -10,12 +10,11 @@
|
||||
// ==============================================================
|
||||
|
||||
#include "shader_manager.h"
|
||||
|
||||
#include <stdexcept>
|
||||
|
||||
#include "graphics_interface.h"
|
||||
#include "graphics_factory.h"
|
||||
#include "util.h"
|
||||
#include "platform_util.h"
|
||||
#include "leak_dumper.h"
|
||||
|
||||
using namespace Shared::Util;
|
||||
@@ -37,13 +36,13 @@ void ShaderManager::init(){
|
||||
for(unsigned int i=0; i<shaders.size(); ++i){
|
||||
shaders[i]->init();
|
||||
if(!shaders[i]->compile(logString)){
|
||||
throw runtime_error("Can't compile shader\n");
|
||||
throw megaglest_runtime_error("Can't compile shader\n");
|
||||
}
|
||||
}
|
||||
for(unsigned int i=0; i<shaderPrograms.size(); ++i){
|
||||
shaderPrograms[i]->init();
|
||||
if(!shaderPrograms[i]->link(logString)){
|
||||
throw runtime_error("Can't link shader\n");
|
||||
throw megaglest_runtime_error("Can't link shader\n");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user