Subversion Repositories gelsvn

Rev

Rev 125 | Go to most recent revision | Blame | Last modification | View Log | RSS feed

#ifndef __TEXMAP_H__
#define __TEXMAP_H__

#include <string>
#include "CGLA/Vec3f.h"
#include "Graphics/gel_gl.h"

namespace Geometry
{
        class Texmap 
        {
                GLuint id;
                unsigned char *image;
                unsigned int bpp;
                int size_x;
                int size_y;
                int load_size_x;
                int load_size_y;
                std::string name;

        public:

                // Constuctor/destructor
                Texmap();
                ~Texmap();

                const std::string& get_name() const {return name;}
                bool load(const std::string& _name);
                CGLA::Vec3f get_texel(int u, int v);

                void gl_init();
                void gl_bind();
        };

}
#endif