BreakingChanges

From ClanLib Game SDK

This file describes breaking changes between versions.

Contents

[edit] Version 2.3.0: Not released yet

[edit] Version 2.2.3: Not released yet

[edit] Version 2.2.2: Released 24 August 2010

[edit] Version 2.2.1: Released 5 August 2010

[edit] Version 2.2.0: Released 20 July 2010

CL_String is now an utf-8 string on all platforms. No need for cl_text wrapper around text, and there are no more -uc libraries generated.
If you use cl_text a lot in your code. Visual Studio Find/Replace can remove them for you: Find="cl_text\({:q}\)", Replace="\1", Regular expressions enabled.
If strings contain unicode. Save the source code as: UNICODE(UTF-8 without signature)
Under Visual Studio, the default location for the compiled libraries have changed. The 32 and 64 bit versions of ClanLib libraries are now located under Win32 / x64 subdirectories in the selected target directory. You will need to change the Visual Studio VC++ Directories settings; adding Win32 and/or x64 dirs under Library Directories.
Instead, use CL_PixelBuffer and specify the source rectangle.
Instead, use CL_PixelBuffer.get_format() to obtain the format enum (for example cl_rgba8) and if you require the pixel masks etc, these have been moved into the CL_PixelBuffer API.
If you use this class then you will need to set it to equal the desired rectangle of "buffer"
If you use CL_ProgramObjects with the GL target, you have to modify your programs if they contain gl_ModelViewMatrix, gl_ProjectionMatrix, gl_ModelViewProjectionMatrix, gl_NormalMatrix. Change these to cl_ModelViewMatrix, cl_ProjectionMatrix, cl_ModelViewProjectionMatrix, cl_NormalMatrix
Remember to add:
 "uniform mat4 cl_ModelViewMatrix;"
 "uniform mat4 cl_ProjectionMatrix;"
 "uniform mat4 cl_ModelViewProjectionMatrix;"
 "uniform mat3 cl_NormalMatrix;"
If you don't require all these uniforms, you can select which ones use want via the CL_ProgramMatrixFlags in gc.set_program_object(program, program_matrix_flags);
(Note, program_matrix_flags defaults to cl_program_matrix_all_standard)
If you require it, copy it directly into your application.
Return value false = Entire buffer updated, because the target does not support partial updates
Legacy defines and functions have been removed.
(From deprecated and removed features in OpenGL 3.3 Specification)
Templates defined for: int (CL_Circle), float (CL_Circlef), double (CL_Circled)
Note, CL_ScreenInfo still exists, to returns the geometries of the attached screens and the index of the primary screen in the returned array (although, currently this is not implemented on linux)
It changed from
 dest.rgba = src.a*src.rgba + (1-src.a)*dest.rgba
to:
 dest.rgb = src.a*src.rgb + (1-src.a)*dest.rgb
 dest.a = src.a + (1-src.a)*dest.a

[edit] Version 2.1.3: Not released yet

[edit] Version 2.1.2: Released 19 July 2010

[edit] Version 2.1.1: Released 10 December 2009

On linux, this function does not do anything. It used to use the libxxf86vm library, but this caused various problems. It would only report the current mode on most system, and xf86vidmode is considered sort of deprecated by upstream xorg.
(Note, since clanlib v2.x no longer changes the video resolution, CL_DisplayWindowMode has no real use).
There was no requirement to link with this library
Instead internally, ClanLib uses dlopen(). Your application now can use the libgl.so local on the machine it runs on (so it uses the configured driver on the machine, not the driver that the application was compiled with)
Instead, a free GUI theme (GUIThemeBasic) is included for use with the ClanLib examples (or your application).
"CL_Mat2<float> CL_Mat2d;" was changed to "CL_Mat2<double> CL_Mat2d;"

[edit] Version 2.1.0: Released 20 october 2009

There was a discrepancy between the documentation and what it actually did. Previously, using floats, we lost accuracy. Now control of animation speed should now be 100% accurate.
If you previously did sprite.update(float), you now need to feed it a number 1000 as large (or stop dividing CL_System::get_time() by 1000.0f when calculating delta time). If you don't use a time parameter to sprite.update() it is calculated automatically as before.
To solve some problems with co-hosting different versions of ClanLib, and to better support breaking changes in the future, we've changed how ClanLib names its libraries under Unix. ClanLib now creates libclan21Core.so, libclan21Display.so (and so on), instead of naming it libclanCore.so and libclanDisplay.so. Every breaking release will increase the 2.x.0 number. Every backward compatible release will get a 2.1.x version.
This was done because clanGDI is better and faster. ClanSDL is still available in the Contrib repository - read more about it on http://clanlib.org/development.html
It was placed in the wrong class in the last release. CL_Line is an line with an infinite length, thus requires a different clipping method.
The image is now no longer upside-down.
It's now always successful.
Add CL_File::access_read, CL_File::access_write or CL_File::access_read_write.

[edit] Version 2.0.4: Released 17 september 2009

Use CL_KeepAlive::process() instead
It was a bug with it being optional.
Thus positions may be different.
Use func_close() (from CL_GUIComponent), but note, it returns a bool (true = message consumed) so you need to change your signature to bool on_close();
Use CL_PopupMenuItem's func_clicked() instead (returned from CL_PopupMenu::insert_item()).
Use CL_GUIComponent::func_activated and func_deactivated instead.
Use set_accelerator_table(const CL_AcceleratorTable &table) instead if you use accelerators.

[edit] Version 2.0.3: Released 15 july 2009

Example before: CL_RGB8 Now: cl_rgb8
The CL_Timer implementation no longer require any knowledge of the windowing system message queue, and therefore no longer requires any CL_DisplayWindow for creation. As a consequence of this change, CL_Timer has been moved to <ClanLib/Core/System/timer.h> and now uses the CL_KeepAlive system to invoke the timer callback.
As it is no longer required (see CL_Timer post above). To create a timer object, simply construct the CL_Timer object and start using it.
Use the CL_GUITopLevelDescription to set wanted geometry, either using set_position on it, or using the new convenience constructors including position.

[edit] Version 2.0.2 Released 18 may 2009

- No breaking changes since 2.0.1

[edit] Version 2.0.1 Released 28 april 2009

CL_Contour no longer exposes internal variables - use getter functions instead.

[edit] Version 2.0.0 Released 22 april 2009