Go to the documentation of this file.00001
00002
00003 #ifndef __TEXTURE_H__
00004 #define __TEXTURE_H__
00005
00006 #endif
00007
00008
00009
00010
00011 #include <windows.h>
00012 #include <stdio.h>
00013 #include <gl\gl.h>
00014
00015
00016
00017
00018 typedef struct
00019 {
00020 GLubyte* imageData;
00021 GLuint bpp;
00022 GLuint width;
00023 GLuint height;
00024 GLuint texID;
00025 GLuint type;
00026 }Texture;
00027
00028 typedef struct
00029 {
00030 GLubyte Header[12];
00031 }TGAHeader;
00032
00033 typedef struct
00034 {
00035 GLubyte header[6];
00036 GLuint bytesPerPixel;
00037 GLuint imageSize;
00038 GLuint type;
00039 GLuint Height;
00040 GLuint Width;
00041 GLuint Bpp;
00042 }TGA;
00043
00044
00045
00046
00048
00050
00051
00052
00053 bool LoadTGA(Texture* texture, char * filename);
00054 bool LoadUncompressedTGA(Texture *, char *, FILE *,TGAHeader tgaheader_t,TGA tga_t);
00055 bool LoadCompressedTGA(Texture *, char *, FILE *,TGAHeader tgaheader_t,TGA tga_t);
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104
00105
00106
00107
00108
00109
00110
00111
00112
00113
00114
00115
00116
00117
00118
00119
00120
00121
00122