* added documentation (in-code and pasdoc generated)
[glBitmap.git] / readme.txt
1 glBitmap by Steffen Xonna aka Lossy eX (2003-2008)
2 http://www.opengl24.de/index.php?cat=header&file=glbitmap
3
4 modified by Delphi OpenGL Community (http://delphigl.com/) (2013)
5
6 ------------------------------------------------------------
7 The contents of this file are used with permission, subject to
8 the Mozilla Public License Version 1.1 (the "License"); you may
9 not use this file except in compliance with the License. You may
10 obtain a copy of the License at
11 http://www.mozilla.org/MPL/MPL-1.1.html
12 ------------------------------------------------------------
13 The glBitmap is a Delphi/FPC unit that contains several wrapper classes
14 to manage OpenGL texture objects. Below you can find a list of the main
15 functionality of this classes:
16 - load texture data from file (e.g. BMP, TGA, DDS, PNG, JPEG, ...)
17 - load texture data from several other image objects (e.g. TBitmap, TLazIntfImage, SDL Surface)
18 - save texture data to file (e.g. BMP, TGA, DDS, PNG, JPEG, ...)
19 - save texture data to several other image objects (e.g. TBitmap, TLazIntfImage, SDL Surface)
20 - support for many texture formats (e.g. RGB8, BGR8, RGBA8, BGRA8, ...)
21 - manage texture properties (e.g. Filter, Clamp, Mipmap, ...)
22 - upload texture data to video card
23 - download texture data from video card
24 - manipulate texture data (e.g. add alpha, remove alpha, convert to other format, switch RGB, ...)
25 ------------------------------------------------------------
26 History
27 20-11-2013
28 - refactoring of the complete library
29 - glBitmap is managed by git, so this history is not maintenanced any longer
30 21-03-2010
31 - The define GLB_DELPHI dosn't check versions anymore. If you say you are using delphi
32   then it's your problem if that isn't true. This prevents the unit for incompatibility
33   with newer versions of Delphi.
34 - Problems with D2009+ resolved (Thanks noeska and all i forgot)
35 - GetPixel isn't set if you are loading textures inside the constructor (Thanks Wilson)
36 10-08-2008
37 - AddAlphaFromglBitmap used the custom pointer instead the imagedatapointer (Thanks Wilson)
38 - Additional Datapointer for functioninterface now has the name CustomData
39 24-07-2008
40 - AssigneAlphaToBitmap overwrites his own palette (Thanks Wilson)
41 - If you load an texture from an file the property Filename will be set to the name of the file
42 - Three new properties to attach custom data to the Texture objects
43   - CustomName  (free for use string)
44   - CustomNameW (free for use widestring)
45   - CustomDataPointer (free for use pointer to attach other objects or complex structures)
46 27-05-2008
47 - RLE TGAs loaded much faster
48 26-05-2008
49 - fixed some problem with reading RLE TGAs.
50 21-05-2008
51 - function clone now only copys data if it's assigned and now it also copies the ID
52 - it seems that lazarus dont like comments in comments.
53 01-05-2008
54 - It's possible to set the id of the texture
55 - define GLB_NO_NATIVE_GL deactivated by default
56 27-04-2008
57 - Now supports the following libraries
58   - SDL and SDL_image
59   - libPNG
60   - libJPEG
61 - Linux compatibillity via free pascal compatibility (delphi sources optional)
62 - BMPs now loaded manuel
63 - Large restructuring
64 - Property DataPtr now has the name Data
65 - Functions are more flexible between RGB(A) and BGR(A). RGB can be saved as Bitmap and will be saved as BGR
66 - Unused Depth removed
67 - Function FreeData to freeing image data added
68 24-10-2007
69 - ImageID flag of TGAs was ignored. (Thanks Zwoetzen)
70 15-11-2006
71 - Function SetBorderColor implemented (only used by opengl if wrap is set to GL_CLAMP_TO_BORDER)
72 - Function AddAlphaFromValue implemented to use an fixed Value as Alphachannel
73 - Function ReadOpenGLExtension is now only intern
74 29-06-2006
75 - pngimage now disabled by default like all other versions.
76 26-06-2006
77 - Setting up an anisotropic filter of 0 isnt allowed by nvidia (Thanks Ogridi)
78 22-06-2006
79 - Fixed some Problem with Delphi 5
80 - Now uses the newest version of pngimage. Makes saving pngs much easier.
81 22-03-2006
82 - Property IsCompressed and Size removed. Not really supported by Spec (Thanks Ogridi)
83 09-03-2006
84 - Internal Format ifDepth8 added
85 - function GrabScreen now supports all uncompressed formats
86 31-01-2006
87 - AddAlphaFromglBitmap implemented
88 29-12-2005
89 - LoadFromResource and LoadFromResourceId now needs an Instance and an ResourceType (for ID)
90 28-12-2005
91 - Width, Height and Depth internal changed to TglBitmapPixelPosition.
92   property Width, Height, Depth are still existing and new property Dimension are avail
93 11-12-2005
94 - Added native OpenGL Support. Breaking the dglOpenGL "barrier".
95 19-10-2005
96 - Added function GrabScreen to class TglBitmap2D
97 18-10-2005
98 - Added support to Save images
99 - Added function Clone to Clone Instance
100 11-10-2005
101 - Functions now works with Cardinals for each channel. Up to 32 Bits per channel.
102   Usefull for Future
103 - Several speed optimizations
104 09-10-2005
105 - Internal structure change. Loading of TGA, PNG and DDS improved.
106   Data, format and size will now set directly with SetDataPtr.
107 - AddFunc now works with all Types of Images and Formats
108 - Some Funtions moved to Baseclass TglBitmap
109 06-10-2005
110 - Added Support to decompress DXT3 and DXT5 compressed Images.
111 - Added Mapping to convert data from one format into an other.
112 05-10-2005
113 - Added method ConvertTo in Class TglBitmap2D. Method allows to convert every
114   supported Input format (supported by GetPixel) into any uncompresed Format
115 - Added Support to decompress DXT1 compressed Images.
116 - SwapColors replaced by ConvertTo
117 04-10-2005
118 - Added Support for compressed DDSs
119 - Added new internal formats (DXT1, DXT3, DXT5)
120 29-09-2005
121 - Parameter Components renamed to InternalFormat
122 23-09-2005
123 - Some AllocMem replaced with GetMem (little speed change)
124 - better exception handling. Better protection from memory leaks.
125 22-09-2005
126 - Added support for Direct Draw Surfaces (.DDS) (uncompressed images only)
127 - Added new internal formats (RGB8, RGBA8, RGBA4, RGB5A1, RGB10A2, R5G6B5)
128 07-09-2005
129 - Added support for Grayscale textures
130 - Added internal formats (Alpha, Luminance, LuminanceAlpha, BGR8, BGRA8)
131 10-07-2005
132 - Added support for GL_VERSION_2_0
133 - Added support for GL_EXT_texture_filter_anisotropic
134 04-07-2005
135 - Function FillWithColor fills the Image with one Color
136 - Function LoadNormalMap added
137 30-06-2005
138 - ToNormalMap allows to Create an NormalMap from the Alphachannel
139 - ToNormalMap now supports Sobel (nmSobel) function.
140 29-06-2005
141 - support for RLE Compressed RGB TGAs added
142 28-06-2005
143 - Class TglBitmapNormalMap added to support Normalmap generation
144 - Added function ToNormalMap in class TglBitmap2D to genereate normal maps from textures.
145   3 Filters are supported. (4 Samples, 3x3 and 5x5)
146 16-06-2005
147 - Method LoadCubeMapClass removed
148 - LoadCubeMap returnvalue is now the Texture paramter. Such as LoadTextures
149 - virtual abstract method GenTexture in class TglBitmap now is protected
150 12-06-2005
151 - now support DescriptionFlag in LoadTga. Allows vertical flipped images to be loaded as normal
152 10-06-2005
153 - little enhancement for IsPowerOfTwo
154 - TglBitmap1D.GenTexture now tests NPOT Textures
155 06-06-2005
156 - some little name changes. All properties or function with Texture in name are
157   now without texture in name. We have allways texture so we dosn't name it.
158 03-06-2005
159 - GenTexture now tests if texture is NPOT and NPOT-Texture are supported or
160   TextureTarget is GL_TEXTURE_RECTANGLE. Else it raised an exception.
161 02-06-2005
162 - added support for GL_ARB_texture_rectangle, GL_EXT_texture_rectangle and GL_NV_texture_rectangle
163 25-04-2005
164 - Function Unbind added
165 - call of SetFilter or SetTextureWrap if TextureID exists results in setting properties to opengl texture.
166 21-04-2005
167 - class TglBitmapCubeMap added (allows to Create Cubemaps)
168 29-03-2005
169 - Added Support for PNG Images. (http://pngdelphi.sourceforge.net/)
170   To Enable png's use the define pngimage
171 22-03-2005
172 - New Functioninterface added
173 - Function GetPixel added
174 27-11-2004
175 - Property BuildMipMaps renamed to MipMap
176 21-11-2004
177 - property Name removed.
178 - BuildMipMaps is now a set of 3 values. None, GluBuildMipmaps and SGIS_generate_mipmap
179 22-05-2004
180 - property name added. Only used in glForms!
181 26-11-2003
182 - property FreeDataAfterGenTexture is now available as default (default = true)
183 - BuildMipmaps now implemented in TglBitmap1D (i've forgotten it)
184 - function MoveMemory replaced with function Move (little speed change)
185 - several calculations stored in variables (little speed change)
186 29-09-2003
187 - property BuildMipsMaps added (default = true)
188   if BuildMipMaps isn't set GenTextures uses glTexImage[12]D else it use gluBuild[12]dMipmaps
189 - property FreeDataAfterGenTexture added (default = true)
190   if FreeDataAfterGenTexture is set the texturedata were deleted after the texture was generated.
191 - parameter DisableOtherTextureUnits of Bind removed
192 - parameter FreeDataAfterGeneration of GenTextures removed
193 12-09-2003
194 - TglBitmap dosn't delete data if class was destroyed (fixed)
195 09-09-2003
196 - Bind now enables TextureUnits (by params)
197 - GenTextures can leave data (by param)
198 - LoadTextures now optimal
199 03-09-2003
200 - Performance optimization in AddFunc
201 - procedure Bind moved to subclasses
202 - Added new Class TglBitmap1D to support real OpenGL 1D Textures
203 19-08-2003
204 - Texturefilter and texturewrap now also as defaults
205   Minfilter = GL_LINEAR_MIPMAP_LINEAR
206   Magfilter = GL_LINEAR
207   Wrap(str) = GL_CLAMP_TO_EDGE
208 - Added new format tfCompressed to create a compressed texture.
209 - propertys IsCompressed, TextureSize and IsResident added
210   IsCompressed and TextureSize only contains data from level 0
211 18-08-2003
212 - Added function AddFunc to add PerPixelEffects to Image
213 - LoadFromFunc now based on AddFunc
214 - Invert now based on AddFunc
215 - SwapColors now based on AddFunc
216 16-08-2003
217 - Added function FlipHorz
218 15-08-2003
219 - Added function LaodFromFunc to create images with function
220 - Added function FlipVert
221 - Added internal format RGB(A) if GL_EXT_bgra or OpenGL 1.2 isn't supported
222 29-07-2003
223 - Added Alphafunctions to calculate alpha per function
224 - Added Alpha from ColorKey using alphafunctions
225 28-07-2003
226 - First full functionally Version of glBitmap
227 - Support for 24Bit and 32Bit TGA Pictures added
228 25-07-2003
229 - begin of programming