X-Git-Url: http://git.tdb.fi/?p=libs%2Fgl.git;a=blobdiff_plain;f=source%2Fmisc.h;h=32adc9bf04794a37ff5f1d3cdd718dddacf03d92;hp=11cb3a60fdc24f9d94e713f89f17cdd9bd351ca6;hb=97b8f0d945474582c2213b70418d399e5641f0d5;hpb=98c810b6d2256aa65986bbde12c38917678121bb diff --git a/source/misc.h b/source/misc.h index 11cb3a60..32adc9bf 100644 --- a/source/misc.h +++ b/source/misc.h @@ -1,10 +1,3 @@ -/* $Id$ - -This file is part of libmspgl -Copyright © 2007 Mikko Rasa, Mikkosoft Productions -Distributed under the LGPL -*/ - #ifndef MSP_GL_MISC_H_ #define MSP_GL_MISC_H_ @@ -17,36 +10,9 @@ void enable(GLenum); void disable(GLenum); void set(GLenum, bool); -///Deprecated (can't properly pass an array through a reference) -void get(GLenum, int &); - -void get(GLenum, int *); int get_i(GLenum); - -class Bind -{ -private: - struct Base - { - virtual ~Base() { } - }; - - template - struct Binder: Base - { - const T &obj; - - Binder(const T &o): obj(o) { obj.bind(); } - ~Binder() { obj.unbind(); } - }; - - Base *binder; - -public: - template - Bind(const T &o): binder(new Binder(o)) { } - ~Bind() { delete binder; } -}; +int get_shader_i(unsigned, GLenum); +int get_program_i(unsigned, GLenum); } // namespace GL } // namespace Msp