X API break
+ new features
% modified features
- removed features, fixed bugs
=========================================================
1.5.0 : 2010 Feb 15
X TCODRandom::getIntFromByteArray has been deleted    
X the random number generator module now support two algorithms (Mingos)
  Mersenne twister, used in previous versions of libtcod
  Complementary Multiply With Carry, 2 to 3 times faster and has a much better period. This is the default algo.
  You can choose the algorithm in the constructor :
  typedef enum {
    TCOD_RNG_MT,
    TCOD_RNG_CMWC
  } TCOD_random_algo_t;
  TCODRandom() => CMWC, default seed
  TCODRandom(uint32 seed) => CMWC, custom seed
  TCODRandom(TCOD_random_algo_t algo) => default seed, custom algo
  TCODRandom(uint32 seed, TCOD_random_algo_t aldo) => custom algo and seed
X removed bitfield from TCOD_key_t and TCOD_mouse_t to ease wrappers writing.
  existing working wrappers might be broken, though.
X TCODConsole::printFrame now takes an extra argument: TCOD_bkgnd_flag_t
X renamed libraries on Linux to improve portability :
    libtcod++.so  => libtcodxx.so
    libtcod-gui.so => libtcodgui.so
+ added text field toolkit (undocumented)    
+ added functions for fast python full console coloring:
	console_fill_foreground(con,r,g,b)
	console_fill_background(con,r,g,b)
	r,g,b are 1D arrays of console_width * console_height     
+ added fast python rendering sample (Jotaf)	
+ added TCODConsole::resetCredits() to restart credits animation before it's finished
+ added TCODConsole::setDirty(int x, int y, int w,int h) to force libtcod to redraw a part of the console
    This might by needed when using the SDL renderer
+ added TCODSystem::getCharSize(int *w, int *h) to get the current font's character size
+ added name generation module (Mingos)
+ added Dijkstra pathfinding (Mingos)
+ added approximated gaussian distribution functions in the RNG module
    float TCODRandom::getGaussian(float min, float max)
+ added subcell resolution blitting function TCODImage::blit2x
+ added more portable filesystem utilities :
    static bool TCODSystem::isDirectory(const char *path)
    static TCODList<const char *> TCODSystem::getDirectoryContent(const char *path, const char *pattern)   
+ added TCODConsole::putCharEx(int x, int y, int c, TCODColor &fore, TCODColor &back) (at last!)
+ added waitThread and thread conditions support in (undocumented) threading api
+ added unicode support and 4 unicode fonts courtesy of Mingos. Functions with unicode support are :
    static void TCODConsole::mapStringToFont(const wchar_t *s, int fontCharX, int fontCharY);
    void TCODConsole::printLeft(int x, int y, TCOD_bkgnd_flag_t flag, const wchar_t *fmt, ...); 
    void TCODConsole::printRight(int x, int y, TCOD_bkgnd_flag_t flag, const wchar_t *fmt, ...); 
    void TCODConsole::printCenter(int x, int y, TCOD_bkgnd_flag_t flag, const wchar_t *fmt, ...); 
    int TCODConsole::printLeftRect(int x, int y, int w, int h, TCOD_bkgnd_flag_t flag, const wchar_t *fmt, ...); 
    int TCODConsole::printRightRect(int x, int y, int w, int h, TCOD_bkgnd_flag_t flag, const wchar_t *fmt, ...); 
    int TCODConsole::printCenterRect(int x, int y, int w, int h, TCOD_bkgnd_flag_t flag, const wchar_t *fmt, ...); 
    int TCODConsole::getHeightLeftRect(int x, int y, int w, int h, const wchar_t *fmt, ...); 
    int TCODConsole::getHeightRightRect(int x, int y, int w, int h, const wchar_t *fmt, ...); 
    int TCODConsole::getHeightCenterRect(int x, int y, int w, int h,const wchar_t *fmt, ...);
  C versions of the functions have _utf suffixes. Unicode fonts are :
    fonts/consolas_unicode_10x10.png
    fonts/consolas_unicode_12x12.png
    fonts/consolas_unicode_16x16.png
    fonts/consolas_unicode_8x8.png
% new compilation system with a debug and release version of the library
% makefiles have been moved to a makefiles subdirectory
% libtcod credits now use subcell resolution
- fixed wrong ascii code returned by check/waitForKeypress with AltGr+0-9 combination
- fixed RNG going mad if you delete the default RNG
- fixed wait_for_keypress not working in python
- now the parser can handle strings/identifiers with unlimited size (previously limited to 256 chars)
- fixed TCODZip module missing from MSVC release
- fixed issue with TCOD_COLCTRL_FORE_RGB and TCOD_COLCTRL_BACK_RGB when using 10 or 37 in rgb values
- fixed issue in color_set_hsv python wrapper
- fixed bug in console blitting when destination coordinates are outside the destination console
=========================================================
1.4.2 : 2009 Oct 06
X TCODConsole::blit now takes 2 float parameters :
   static void blit(const TCODConsole *src,int xSrc, int ySrc, int wSrc, int hSrc, TCODConsole *dst, int xDst, int yDst, float foreground_alpha=1.0f, float background_alpha=1.0f)
+ added possiblity to use SDL drawing functions on top of the root console with TCODSystem::registerSDLRenderer   
+ added Mingos' restrictive precise angle shadowcasting fov algorithm as FOV_RESTRICTIVE
+ heightmap : added missing TCOD_heightmap_set_value function
+ new consolas, dejavu, lucida and prestige fonts from Mingos
- fixed R/B inversion in color operations in python
- fixed a crash when saving a TCODImage before initializing the root console
- fixed a crash when destroying an empty TCODZip (file not found)
- fixed torch effect in C++ sample
- fixed ASCII_IN_ROW flag not working
- fixed path_new_using_function not working in python wrapper
- fixed alignment issues in TCOD_console_print_* with strings containing ascii codes > 127
- fixed color controls not working with autowrap
- fixed fov post-processing step to handle opaque walkable cells (for example bush)
=========================================================
1.4.1 : 2009 Mar 22
X Default colors have been changed/added. 
X TCODMap::computeFov changed to support several algorithms :
   void computeFov(int playerX,int playerY, int maxRadius,bool light_walls = true, TCOD_fov_algorithm_t algo = FOV_BASIC)
   available algorithms :
   FOV_BASIC : classic libtcod fov
   FOV_DIAMOND : http://www.geocities.com/temerra/los_rays.html
   FOV_SHADOW : http://roguebasin.roguelikedevelopment.org/index.php?title=FOV_using_recursive_shadowcasting
   FOV_PERMISSIVE : http://roguebasin.roguelikedevelopment.org/index.php?title=Precise_Permissive_Field_of_View
   light_walls : if false, wall cells are not put in the fov
X setCustomFont changed :
   defines the font number of characters instead of character size
   if not specified, it is deduced from the layout flag (16x16 for ascii, 32x8 for tcod)
   setCustomFont(const char *fontFile, int flags=TCOD_FONT_LAYOUT_ASCII_INCOL,int nbCharHoriz=0, int nbCharVertic=0)
   The flag values have changed too:
     TCOD_FONT_LAYOUT_ASCII_INCOL=1,
     TCOD_FONT_LAYOUT_ASCII_INROW=2,
     TCOD_FONT_TYPE_GREYSCALE=4,
     TCOD_FONT_TYPE_GRAYSCALE=4,
     TCOD_FONT_LAYOUT_TCOD=8,
+ added python wrapper
+ added arial, courier fonts courtesy of Mingos
+ added some non portable filesystem utilities in TCODSystem :
	bool TCODSystem::createDirectory(const char *path);
	bool TCODSystem::deleteDirectory(const char *path);
	bool TCODSystem::deleteFile(const char *path);
+ added multithread utilities in TCODSystem :
	static TCOD_thread_t TCODSystem::newThread(int (*func)(void *), void *data);
	static void TCODSystem::deleteThread(TCOD_thread_t th);
	static TCOD_mutex_t TCODSystem::newMutex();
	static void TCODSystem::mutexIn(TCOD_mutex_t mut);
	static void TCODSystem::mutexOut(TCOD_mutex_t mut);
	static void TCODSystem::deleteMutex(TCOD_mutex_t mut);
	static TCOD_semaphore_t TCODSystem::newSemaphore(int initVal);
	static void TCODSystem::lockSemaphore(TCOD_semaphore_t sem);
	static void TCODSystem::unlockSemaphore(TCOD_semaphore_t sem);
	static void TCODSystem::deleteSemaphore( TCOD_semaphore_t sem);
+ added some image utilities :
	void TCODImage::clear(const TCODColor col)
	void TCODImage::invert()
	void TCODImage::hflip()
	void TCODImage::vflip()
	void TCODImage::scale(int neww, int newh)
	void TCODImage::setKeyColor(const TCODColor keyColor)
	int TCODImage::getAlpha(int x,int y) const
	bool TCODImage::isPixelTransparent(int x, int y) const
+ can now dynamically modify the content of the font bitmap :
	static void TCODSystem::updateChar(int asciiCode, int fontx, int fonty,const TCODImage *img,int x,int y)
+ added C and python code generation in the heightmap tool
+ added function to calculate the height of a printed string (with autowrapping) 
  without actually printing it :
    int TCODConsole::getHeightLeftRect(int x, int y, int w, int h, const char *fmt, ...)
    int TCODConsole::getHeightRightRect(int x, int y, int w, int h, const char *fmt, ...)
    int TCODConsole::getHeightCenterRect(int x, int y, int w, int h, const char *fmt, ...)
+ parser : now strings properties can be splitted. The parser concatenates them :
    myProperty = "string value can use "
                 "multi line layout"
+ parser : added missing getCharProperty when using default listener
+ heightmap : added missing TCOD_heightmap_get_value function
+ now support fonts with unlimited number of characters (was limited to 1024 in 1.4.0)
+ added callback-based atomic bresenham function
    static bool TCODLine::line(int xFrom, int yFrom, int xTo, int yTo, TCODLineListener *listener)
+ added TCODMap::copy function
+ added TCODList fast remove functions (don't preserve the list order)
    template<class T> void TCODList::removeFast(const T elt)
    template<class T> T * TCODList::removeFast(T *elt)
% pathfinding : you don't need to provide coordinates in x,y parameters of Path::walk
% improved double/simple walls special characters in tcod layout fonts
- fixed SDL dependant features not being available before initRoot is called.
  If you want to draw on an offscreen console without calling initRoot, you
  need to call at least setCustomFont to initialize the font. Else characters won't be rendered.
- fixed standalone credits page erasing previously fps limit
- fixed special characters TCOD_CHAR_DTEE* and TCOD_CHAR_DCROSS not printing correctly
- fixed heightmap tool generated code not compiling
- fixed parser C++ error function not prepending file name & line number to the error message
- fixed memory leak in pathfinding
- fixed fov issue with walkable, non transparent cells
- fixed numerical stability issues with heightmap rain erosion
- fixed calculation error in heightmap kernel transformation function
- fixed TCODConsole::renderCredits being able to render the credits only once
- fixed mouse cx,cy coordinates in "padded" fullscreen modes
- fixed mouse cursor hidden when switching fullscreen
- fixed mouse coordinates when going fullscreen->windowed
=========================================================
1.4.0 : 2008 Oct 16
X Noise functions renamed : 
   TCODNoise::getNoise -> TCODNoise::getPerlin
   TCODNoise::getFbm -> TCODNoise::getFbmPerlin
   TCODNoise::getTurbulence -> TCODNoise::getTurbulencePerlin
X Some special char constants (TCOD_CHAR_xxx) added/removed
X setCustomFont changed :
   setCustomFont(const char *fontFile,int charWidth=8, int charHeight=8, int flags=0)
   flags :
	TCOD_FONT_LAYOUT_ASCII_INROW=1
	TCOD_FONT_TYPE_GREYSCALE=2
	TCOD_FONT_LAYOUT_TCOD=4
+ added pathfinding module
+ added BSP module
+ added heightmap module + heightmap tool
+ added compression toolkit
+ added possibility to pre-allocate TCODList's memory
+ added support for PNG images + antialiased fonts from PNG with alpha channel or greyscale
+ added ASCII mapping functions to map an ascii code to any character in your font :
   static void TCODConsole::mapAsciiCodeToFont(int asciiCode, int fontCharX, int fontCharY);
   static void TCODConsole::mapAsciiCodesToFont(int firstAsciiCode, int nbCodes, int fontCharX, int fontCharY);
   static void TCODConsole::mapStringToFont(const char *s, int fontCharX, int fontCharY);
+ parser : now strings can contain octal/hexadecimal ascii values 
   myStringProperty1 = "embedded hex value : \x80"
   myStringProperty2 = "embedded octal value : \200"
+ parser : now can handle list properties.
    myStruct {
        myProperty = [ 1, 2, 3 ]
    }
  to declare : struct.addListProperty("myProperty",TCOD_TYPE_INT,true);
  to read (default parser) : TCODList<int> prop( parser.getListProperty("myStruct.myProperty",TCOD_TYPE_INT) );
+ added color map generator. Interpolate colors from an array of key colors :
   TCODColor::genMap(TCODColor *map, int nbKey, TCODColor const *keyColor, int const *keyIndex)
+ added random generator backup function. You can save the state of a generator with 
    TCODRandom *TCODRandom::save()
  and restore it with
    void TCODRandom::restore(const TCODRandom *backup)
+ added simplex noise, similar to perlin but faster, especially in 4 dimensions and has better contrast : 
   TCODNoise::getSimplex
   TCODNoise::getFbmSimplex
   TCODNoise::getTurbulenceSimplex
   Simplex should be prefered over Perlin for most usages.
+ added wavelet noise, similar to perlin, much slower but doesn't blur at high scales. Doesn't work in 4D :
   TCODNoise::getWavelet
   TCODNoise::getFbmWavelet
   TCODNoise::getTurbulenceWavelet
  Noise functions relative times :
               2D   3D   4D
     simplex :  1    1    1
     perlin :   4    5   17
     wavelet : 32   14    X
+ you can capture a console to an existing image without creating a new image with TCODImage::refreshConsole
+ non rectangular offscreen consoles :
    you can define a key color on offscreen consoles. Cells for which background color = key color are not blitted
+ added libtcod credits function. You can either call :
    TCODConsole::credits() to print the credits page at the start of your game (just after initRoot)
    or
    bool TCODConsole::renderCredits(int x, int y, bool alpha) to print the credits on top of one of your
    existing page (your game menu for example). Call it until it returns true.
% improved TCODConsole::flush performances :
   frames per second for sample "True colors" (terminal.png font) on my reference computer (windowed mode) :
   libtcod 1.3.2 :  130
   libtcod 1.4.0 :  300
% TCODNoise::getTurbulence is twice faster
% improved mouse click detection. Even with a low framerate, mouse clicks will allways be detected and 
   reported in the Xbutton_pressed fields of TCOD_mouse_t.
% you don't need anymore to provide values in TCODLine::step parameters
- fixed memory leak in image module
- fixed DELETE and INSERT keys not detected
- fixed a rendering bug when using a white background color before any other background color
=========================================================
1.3.2 : 2008 Jul 14
+ added documentation for the generic container module TCODList
- fixed not being able to open and close the root console more than once
- fixed parser not being able to attach a sub-structure to more than one structure
- fixed TCOD_image_from_console not working with root console on C version
- fixed TCODParser::newStruct, addFlag, addProperty handling only static names
- fixed web color parser (#rrggbb) in the parser module
- fixed TCODImage constructor / TCOD_image_new crashing if root console not initialized
- fixed mouse status not updated if the keyboard events are not read with checkForKeypress/waitForKeypress
- fixed fbm, turbulence functions returning NaN for high octaves values
=========================================================
1.3.1 : 2008 Jun 05
+ now TCODConsole::putChar/setChar can use ascii code > 255 (ok, it's no more an ascii code, then)
  this allows you to use fonts with more than 255 characters.
+ added default parser listener for basic config files.
+ added fields in TCOD_mouse_t to easily detect button press events :
  lbutton_pressed : left button pressed event  
  rbutton_pressed : right button pressed event  
  mbutton_pressed : middle button pressed event
  and to get the mouse movement in cell coordinates (instead of pixels)
+ added functions to retrieve data from TCODMap
- fixed const correctness in TCODConsole::print*Rect functions
- fixed a bug in fov toolkit if TCODMap width < height
- fixed TCOD_struct_get_type returning TCOD_TYPE_NONE instead of TCOD_TYPE_BOOL for flags.
=========================================================
1.3 : 2008 May 25
X C++ : colors must be initialized by constructor :
  1.2.2 : TCODColor mycol={r,g,b};
  1.3   : TCODColor mycol(r,g,b);
X TCOD_console_check_for_keypress now has a parameter that indicates which events are tracked
  1.2.2 : key = TCOD_console_check_for_keypress();
  1.3   : key = TCOD_console_check_for_keypress(TCOD_KEY_PRESSED);
+ added mouse support
+ added the file parser module
+ added TCODColor::setHSV(float h, float s, float v) and TCODColor::getHSV(float *h, float *s, float *v)
+ added TCODColor addition and scalar multiplication. All r,g,b values are clamped to [0-255] :
  C++ : color1 = color2 * 3.5f;
        color1 = color1 + color2;
  C   : color1 = TCOD_color_multiply_scalar ( color2, 3.5f );
        color1 = TCOD_color_add( color1, color2 );
+ added TCODConsole::setKeyboardRepeat(int initialDelay, int interval) and TCODConsole::disableKeyboardRepeat()
+ added TCODSystem::getCurrentResolution(int *w, int *h)
% now TCODFov::computeFov takes a maxRadius parameter. Use 0 for unlimited range (default)
% the mouse cursor is now automatically hidden when using fullscreen
- fixed closing the window resulting in a fake 'Q' keyboard event
- fixed TCODConsole::print* and TCODConsole::rect functions crashing when printing out of the console
- fixed f parameter modified when calling fbm and turbulence noise functions. Now f is no more modified.
- fixed wrong ascii code in TCOD_key_t.c when pressing Control and a letter key.
=========================================================
1.2.2 : 2008 Mar 18
+ added helpers for real time games
  void TCODSystem::setFps(int val) to limit the number of frames per second. Use 0 for unlimited fps (default)
  int TCODSystem::getFps() to return the number of frames rendered during the last second
  float TCODSystem::getLastFrameLength() to return the length of the last frame in seconds
+ added TCODImage::clear to fill an image with a color
% TCODConsole::hline and vline now have a TCOD_bkgnd_flag_t parameter
% now the TCODConsole::print*Rect functions return the height (number of console lines) of the printed string
- fixed TCODConsole::print*Rect functions not truncating the string if it reaches the bottom of the rectangle
  using a rectangle height of 0 means unlimited height
- fixed a color bug when drawing text using the black color (0,0,0)
- fixed TCODConsole::waitForKeypress(true) resulting in Alt/Ctrl/Shift key state not cleared
=========================================================
1.2.1 : 2008 Mar 09
+ added TCODImage::blitRect to easily map an image on a specific part of a console
+ added possibility to generate an image from an offscreen console
+ added TCODImage::save
+ image toolkit now support reading 8bpp bitmap files.
% Random number generators now support inverted ranges instead of crashing : 
  TCODRandom::getInstance()->getInt(10,2)
  => return a value between 2 and 10.
- fixed image toolkit replacing the green component by the red one when loading a bitmap from a file
- fixed console print*Rect functions unnecessarily splitting the string in some cases
- on Linux, you don't need to link with SDL anymore when using libtcod/libtcod++
- fixed linker issues with Visual Studio
=========================================================
1.2 : 2008 Feb 26
+ new 'image' toolkit replacing some of the features previously in the 'system' toolkit.
+ now windowed mode works even on 16bits desktops
+ improved custom font support. 
  You can now use fonts with characters ordered in rows or columns and with a custom transparent color.
  This allows you to use most existing character sets with the doryen library.
  Font characters with grayscale are still not supported.
+ new time functions :
  uint32 TCODSystem::getElapsedMilli()
  float TCODSystem::getElapsedSeconds()
+ new background blending modes (see the line sample for a demo) :
  TCOD_BKGND_LIGHTEN : newbk = MAX(oldbk,curbk)
  TCOD_BKGND_DARKEN  : newbk = MIN(oldbk,curbk)
  TCOD_BKGND_SCREEN  : newbk = white - (white - oldbk) * (white - curbk) // inverse of multiply : (1-newbk) = (1-oldbk)*(1-curbk)
  TCOD_BKGND_COLOR_DODGE : newbk = curbk / (white - oldbk)
  TCOD_BKGND_COLOR_BURN : newbk = white - (white - oldbk) / curbk
  TCOD_BKGND_ADD : newbk = oldbk + curbk
  TCOD_BKGND_ADDALPHA(alpha) : newbk = oldbk + alpha * curbk, 0.0<=alpha<=1.0
  TCOD_BKGND_BURN : newbk = oldbk + curbk - white
  TCOD_BKGND_OVERLAY : newbk = curbk <= 0.5 ? 2*curbk*oldbk : white - 2*(white-curbk)*(white-oldbk)
  TCOD_BKGND_ALPHA(alpha) : newbk = (1.0f-alpha)*oldbk + alpha*(curbk-oldbk), 0.0<=alpha<=1.0
+ The samples can now use custom bitmap fonts / screen resolution. Use following syntax :
  sample_c[pp] [options]
  options :
  -fullscreen : start directly in fullscreen mode
  -font <font_filename> (default "terminal.bmp")
  -font-char-size <char_width> <char_height> (default 8 8)
  -font-layout <nb_char_horiz> <nb_char_vertic> (default 16 16)
  -font-in-row : characters in the bitmap are ordered in rows (default : columns)
  -font-key-color <r> <g> <b> : transparent color, r,g,b between 0 and 255. (default 0 0 0)
  -fullscreen-resolution <width> <height> (default 640 400)
% headers renamed from tcodlib.h* to libtcod.h*
% on Linux, the library is splitted into libtcod.so and libtcod++.so
  allowing C developpers to use it without installing g++
% the font name is no more a parameter of TCODConsole::initRoot.
% TCODConsole::setBitmapFontSize renamed to TCODConsole::setCustomFont
% TCODConsole::printFrame is now a variadic function, like the other text output functions
% some background blending flags have been renamed :
  TCOD_BKGND_NOBK replaced by TCOD_BKGND_NONE
  TCOD_BKGND_BK replaced by TCOD_BKGND_SET
% the fov toolkit now uses two properties per cell : transparent/walkable. 
  This is necessary to fix a fov issue with window cells (transparent, but not walkable).
  void TCODFov::setTransparent(int x,int y, bool isTransparent) has been replaced by :
  void TCODFov::setProperties(int x,int y, bool isTransparent, bool isWalkable)
% improved const correctness, added some default parameter values in the C++ API.
- fixed the window size when using a custom font size
- fixed TCODK_PRINTSCREEN key event not detected
- fixed crash in printing functions if the string length was > 255. Now they can handle strings of any size.
=========================================================
1.1 : 2008 Jan 27
+ added the noise toolkit
+ added the field of view toolkit
+ added customizable bitmap font size
=========================================================
1.0.1 : 2008 Jan 19
+ added C/C++ samples
% TCODConsole::waitForKeyPress now has a bool parameter indicating if we flush the keyboard buffer before waiting.
- fixed a color bug when drawing text using the grey color (196,196,196)
- fixed wrong key codes returned by wait/checkForKeyPress on some keyboard layouts
=========================================================
1.0 : 2008 Jan 05
Initial release
