Archives for: November 2007, 08

11/08/07

Clutter reflections

Clutter reflections

See src/view-reflection.c in your local gallery git clone. Suboptimal code, no slideshow (only displays the first picture for a given tag), but well.

Maybe I should try to load images (using GdkPixbuf or something alike), use GEGL to do some transforms on them (more optimized than my hackish filters :-P), then use these transformed images on a Clutter texture...

I wonder how hard it would be to play a movie using clutter-gst and add reflections of it.

Permalink . Ikke . 01:12:18 pm . 79 Words . Linux, Desktop, Coding Corner . . 3411 views . Leave a comment
Clutter, advanced UI graphics made fun

Today I looked at Clutter, a nifty "rich UI" creation library using OpenGL and the like. After playing around with some of the samples, reading some API docs and writing one dumb simple text-rotating application (think Windows' text-message screensaver, you know), I wanted to make something more advanced (hum-hum).

I decided writing some photo slideshow application would be cool. We already have several of those, obviously, remember this is just a playground.
Having some sort of F-Spot (a great photo management application) integration would be nifty too, so I started with that: loading taglists and picture-paths for one tag. In the end it turned out writing that took more time than writing the simple view I created.

Next I wrote the Clutter driver code and some system to be able to easily switch view functions. I only implemented one so far, which just fades between images (in, out, next image in, out etc) and stores the GdkPixbuf's in a ringbuffer. Not optimal, no cleanup code yet, jadajadajada.

No screenshots as a static screenshot would not be very impressive (the current application neither but hey ;-)).

Anyway, it might be useful as a sample/basic Clutter application for some people. You can find the source code, clone URL and compilation instructions here. If you implement some nifty view, share it!

Enjoy.

Permalink . Ikke . 02:54:57 am . 219 Words . Linux, Desktop, Coding Corner . . 2907 views . 6 comments