Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/trunk/src/lib/graphics/importer/multi_frame_texture.h @ 5859

Last change on this file since 5859 was 5859, checked in by bensch, 18 years ago

orxonox/trunk: small changes in the Texture interface

File size: 1.1 KB
Line 
1/*!
2 * @file texture.h
3 * @brief Contains the texture class, that handles the reading of Images into Texutre-files.
4 */
5
6#ifndef _MULTI_FRAME_TEXTURE_H
7#define _MULTI_FRAME_TEXTURE_H
8
9#include "texture.h"
10
11#include "glincl.h"
12#include <vector>
13
14/* Forward Declaration */
15struct SDL_Surface;
16
17//! A Class, that reads in Textures from different fileformats.
18  class MultiFrameTexture : public Texture
19  {
20    public:
21      MultiFrameTexture(unsigned int count, ...);
22  //  Texture(TEXTURE_TYPE type, int resolution);
23      ~MultiFrameTexture();
24
25      bool loadImages(unsigned int cound, ...);
26      bool rebuild();
27
28      /** @returns The textureID of this texture.  */
29      inline GLuint getFrameTexture(unsigned int frameNumber) const { return this->textures[frameNumber]; };
30
31      const SDL_Surface* const getFrameImage(unsigned int frameNumber) const { return this->images[frameNumber]; };
32
33    private:
34      std::vector<GLuint>          textures;            //!< The Texture-ID of opengl from this Texture.
35      std::vector<SDL_Surface*>    images;              //!< The SDL_Surfce that stores the Texture on it.
36  };
37
38#endif /* _MULTI_FRAME_TEXTURE_H */
Note: See TracBrowser for help on using the repository browser.