/*
 *  psychlops_g_shader_Win32GL.cpp
 *  Psychlops Standard Library (Universal)
 *
 *  Last Modified 2009/12/14 by Kenchi HOSOKAWA
 *  (C) 2009 Kenchi HOSOKAWA, Kazushi MARUYA and Takao SATO
 */


#include "../../../core/ApplicationInterfaces/psychlops_code_exception.h"
#define PSYCHLOPS_SHADER_PLATFORM
#include "../../../platform/psychlops_platform_selector.h"

//#include "tokoi/glext.h"
//#include "tokoi/glsl.h"

#include "../../../platform/gl/extension/psychlops_g_shader_gl.h"

namespace Psychlops {

	bool global_initialized = false;
	ShaderAPI::ShaderAPI()
	{
		initializeInstance();
		//if(!global_initialized) initialize();
		//global_initialized = true;
	}
	void ShaderAPI::initialize()
	{
		if(!global_initialized)
		{
			if(glewInit()) throw new Exception("This system does not support shader although　this program requires it.");
//			if(glslInit()) throw new Exception("This system does not support shader although　this program requires it.");
			global_initialized = true;
		}
	}

}	/*	<- namespace Psycholops 	*/
