30 March 2009

Clutter/Qt Creator IDE

A new incomer into the free IDE arena: QT Creator from trolltech/nokia.



The Windows version is based on the Mingw32 environment.... So Clutter is compilable with it.



http://www.qtsoftware.com/downloads/sdk-windows-cpp


Very neat IDE. Provided to spread Qt4.5 all around the world, this IDE is included in the Qt SDK. Dont be afraid, you can use it to build your project without any Qt in them.

To build Clutter(*) on Windows using this one: you need to follow the prebuild.bat step (see previous posts), to allow Clutter to be built under a minimalistic MinGW environment.

And get the project file Clutter.pro, for use with QtCreator, to be modified for your needs.

cheers

(*: Nokia/Qt and Intel/Clutter are competitors concerning mobile frameworks... Kinda ironic to build one using the other)

20 March 2009

Win32 Clutter (0.9.2 and Bleeding edge) compilation...

... Still using code::blocks:

Okay i enhanced my scripts to make all this compiling with a native code::blocks install, but various clutter versions...

Basically all you need is:

- to get Clutter sources: using GIT repository (origin/master branch fe), or here : http://www.clutter-project.org/sources/clutter/0.9/ (0.9.2)
- to create some %CLUTTER%\clutter\build\codeblocks directory
- to unzip in there, content of http://alimbourg.googlepages.com/codeblocks.zip
- to modify 'prebuild.bat' which configures various compilation defines, plus generates some .h/.c files using glib tools: so you have to change some paths to point your glib directory...
- run 'prebuild.bat': it will ask for perl.exe, but if you don't have it installed, will copy my own "clutter-enum-types.c/.h" (hence, should be out of sync at some point)

Read http://www.clutter-project.org/blog/?p=68 for dependencies. See previous posts about how to get them.

After that, everything should be ok for you to compile...

For Visual Studio Users: all you have to do is to create .vcproj with all the source files... But probably that some typical gcc include files would be missing (i dont have visual right right now to check that) like libintl.h, iconv.h (?).
gettext, libiconv package for win32 are available here, but i dont know how they integrate themselves into a visual studio framework...

PM or Comment if you need some more ;-).

11 March 2009

Clutter, 0.9 and above, places to look for

BTW: for those interested in clutter 0.9.0 and above, i'm recommending using the test files as turorials as the other repo directories are still not very 0.9 friendly. And things did change a lot(!) between 0.8 and 0.9....

Anyway, browsing clutter-xxx/tests/interactive and clutter-xxx/tests/conform directories should bring you with enough juice to start.

Coming soon, some basic clutter code of mine.

09 March 2009

Bleeding Edge Clutter (Win32 build with C::B)


Using GIT to retrieve repository:
GIT binaries here: http://code.google.com/p/msysgit/

  • Start "Git GUI"
  • 'Clone Depot'
  • Source Depot is git://git.clutter-project.org/clutter
  • Target is yours: c:\Prog\clutter
  • Press 'Clone' and wait a while



Thanks to them, they improved Win32 support :) No more dirty GL hacks to make it work.

Get the latest CB files (see previous post about building Clutter on Win32): unzip this into your clutter\build\cb\: http://alimbourg.googlepages.com/cb-latest.zip

Run prebuild.bat and that's it. Open Code::Blocks and the workspace: everything should rock'n'roll...

I'm doing some application tests to confirm my first impression: Clutter *is* pretty smart (even if i miss the 3rd dimension of OpenGL :|)

Cheers,

05 March 2009

Clutter 0.9 (CodeBlocks/MinGW/Win32 build)

Do you know Clutter ?

"Clutter is an open source software library for creating fast, visually rich and animated graphical user interfaces. "

http://www.clutter-project.org/

Great Project. Really.

A bit too much intricated with gnome/gtk, not really win32 native ;), not so much pictures to display about, but... Nice and Smart code: really promising architecture.
Wanted to figure this on win32, as i'd like to create some click n play frontends for my htpc...
Good news: it's buildable on Windows/CodeBlocks (mingw) with a bit of luck and elbow grease :)

Here is a recipe:

Get Code::Blocks (Mingw flavor): http://www.codeblocks.org/downloads/5

Get Clutter0.9, and unzip-it somewhere on your hdd.

Get GTK dependencies from http://www.gtk.org/download-windows.html (binaries+dev packages): pango, cairo, glib, gtk+

Get some Mingw port from http://sourceforge.net/project/showfiles.php?group_id=7382 :
gettext, libiconv

I put all those libraries side by side with clutter-0.9.

Now some OpenGL trickeries: this is the main problem when compiling on win32 as internal OGL support is only up to 1.2, and clutter is more 1.4. So, as usual, we'll play with extensions and runtime function pointers retrieval.
Note that clutter/cogl is dealing with >1.4 extensions as well: mine is a hack concerning 'some functions 'between' OGL 1.2 and 1.4... So:

Get latest glext.h, to update your probably old \codeblocks\mingw\include\GL\GLext.h.

Create clutter-0.9.0\build\cb directory ('cb' stands for code::blocks, took the directory location from the old msvc_2k5 port).

Unzip this patch/project archive file in clutter-0.9.0\build\cb.

Run cb/prebuild.bat: it will copy some config files, create the actor-marshall.h/.c, and replace some files with a patched version (have a look into prebuild.bat as it probably wont fit with your directory configuration).

Now open code::blocks and cb\clutter.workspace: you should be ready to compile and link both clutter and interactive_d projects.

To execute interactive_d.exe: you need a bunch of dll in the running directory as the content of clutter-0.9\test\data. This is my complete build folder.

interactive_d.exe needs the name of the test to be ran, as a parameter, such as 'interactive_d.exe test-clutter-cairo-flowers'. Here is a two rows list of possible params:


test-actor-clone test-actors
test-animation test-behave
test-binding-pool test-clip
test-clutter-cairo-flowers test-cogl-multitexture
test-cogl-offscreen test-cogl-primitives
test-cogl-tex-convert test-cogl-tex-foreign
test-cogl-tex-getset test-cogl-tex-polygon
test-cogl-tex-tile test-depth
test-easing test-events
test-fbo test-fullscreen
test-grab test-layout
test-main test-model
test-multistage test-offscreen
test-paint-wrapper test-perspective
test-pixmap test-project
test-random-text test-rotate
test-scale test-score
test-script test-shader
test-stage-read-pixels test-text-field
test-text test-texture-quality
test-textures test-threads
test-unproject test-viewport

That's it for Clutter 0.9 :)
I'm going to dive more and more into it next days... And will publish my investigations in there. Stay tuned ?