PDA

View Full Version : ClanLib V2.2 API Wish list



rombust
01-21-2010, 08:47 PM
This is my wish list for the ClanLib V2.2 API

This wish list EXCLUDES the minor items in todo.txt and Examples.

Feel free to add your wishes and comment about existing wishes.

If anyone wants to code any of this, post a message so we are not duplicating work :)

SSE2:

"clanCore, clanGDI and clanSound" all require SSE2 chipsets.
It may be preferable to allow clanCore and clanSound to run on non SSE2 machines.
clanGDI would run too slow without SSE2.

To achieve this, I was thinking of adding: CL_System::is_sse2()

Looking at the existing CL_System's detect_3dnow(), detect_mmx(), detect_ext_3dnow(), maybe a generic CL_System::get_cpu_info() function is preferable.

An intrinsic function is available on win32: http://msdn.microsoft.com/en-us/library/hskdteyh.aspx .Linux has something similar I believe

CL_PixelBuffer:
I feel this should become an interface of some form. So that it can extended to support all "enum CL_TextureFormat" pixel buffer formats.

It would require unpack and pack functions to convert to/from a standard datatype (maybe RGBA8 or RGBA float). So, you can convert formats easily.

ClanLib should natively support cl_rgba8 at least.

There is a question regarding CL_PixelBuffer::flip_vertical() and the CL_PixelBuffer::premultiply_alpha() function.

This does not really fit in CL_PixelBuffer (as it's only a container of pixels).

It could either go into CL_PixelBufferHelp ( http://clanlib.org/docs/clanlib-2.1/reference_doxygen/classCL__PixelBufferHelp.html ) or direct into the texture format code ( For example: CL_PixelBuffer_RGB8::flip_vertical(), draw_pixel() etc )

Also there is a question regarding image loading (direct or with resources).
At the moment, there is no method of specifying what format you wish the image to become except through "enum CL_ImageImportFlags" (that has recently been added).

OpenGL Pixel Buffer Objects:

I am unsure about the API for Pixel Buffer Objects. Maybe it should be tied into CL_PixelBuffer or indirectly via gc.set_pixel_buffer(). I do not know.

OpenGL Instancing:

ClanLib should support this. It can give a significant speed improvement when used to draw duplicated vertex buffers.

rombust
01-22-2010, 12:18 PM
Committed to SVN, SSE2 detection code. Many thanks to Animehunter.

See the new example: Examples/CpuExt

Nightwind0
01-22-2010, 08:24 PM
I'd like to be able to get at the pixel buffers of a CL_Sprite's frame.

Magnus Norddahl
01-25-2010, 05:00 PM
My 3D pacman game needs instanced rendering to draw the cheese on the map. So I will probably add that as soon as I find the motivation (real soon now). :)

rombust
02-23-2010, 04:55 PM
I would like a method to turn off the "compatibility profile only" for OpenGL 3.2

rombust
03-02-2010, 03:22 PM
Thanks Magnus for implementing instancing.

In addition:

Texture Buffer Objects was promoted to a core feature in OpenGL 3.1.
http://www.opengl.org/registry/specs/ARB/texture_buffer_object.txt

ClanLib currently does not support it

rombust
03-17-2010, 04:09 PM
CL_PixelBuffer's have been modified to allow multiple pixel buffer types

CL_PixelBuffer's also supports OpenGL Pixel Buffer Objects (by supplying it with a graphics context)

Also:
CL_TransformFeedbackBuffer, CL_UniformBuffer and CL_TextureBuffer have been partially implemented (untested, and some functionality probably will be missing)

rombust
03-31-2010, 06:53 AM
I have removed: CL_TransformFeedbackBuffer, CL_UniformBuffer and CL_TextureBuffer

For 3 reasons)
1) I don't plan to use or develop it
2) ClanLib is not an OpenGL C++ wrapper. You can still use this in an application using GL commands.
3) It would make creating a DirectX 10 target more difficult.

Attached is the files I have deleted (for reference). Deleted in SVN 4411