Commit Graph

10 Commits

Author SHA1 Message Date
Emmanuele Bassi
26aa4b5290 docs: Remove clutter_stage_get_default()
A lot of the example code in the cookbook and the API reference still
uses the default stage — sometimes as if it were a non-default one,
which once again demonstrates how the default stage was a flawed concept
that just confused people.
2011-11-10 15:37:51 +00:00
nobled
aece642adb doc: fix clutter_init() usage in examples
Make sure users get the idea that clutter_init()
has a return value that needs to be checked.

These were fixed via sed magic:

sed -i -s -e "s/clutter_init (.*)/\
if (& != CLUTTER_INIT_SUCCESS)\n    return 1/"\
 doc/*/*/*.{c,xml} doc/*/*.xml

http://bugzilla.clutter-project.org/show_bug.cgi?id=2574
2011-02-28 14:10:05 +00:00
Elliot Smith
f9d2310b72 cookbook: Make example code C90 compliant
Modified all cookbook example code to prevent ISO C90 compliance
warnings occurring during compilation.
2010-11-12 10:18:31 +00:00
Elliot Smith
e54d3e716b cookbook: Added video of two texture cross-fade
Added a video showing the two texture cross-fade.

Modified the example code to animate on key press, so
this video could be captured.

Also altered the stage size to minimise the video size.
2010-08-18 11:41:32 +01:00
Elliot Smith
0486c56a41 cookbook: Removed unused constant 2010-08-18 11:41:32 +01:00
Elliot Smith
8c0c2924ae cookbook: Renamed front/back to top/bottom in cross-fade example
Front/back seems like the wrong terminology when discussing
actors arranged in layers. Top/bottom fits better with Clutter
API function names and other recipes, so renamed variables.
2010-08-18 11:41:32 +01:00
Elliot Smith
1e4578d1dd cookbook: Don't need to set keep-aspect-ratio for simple example 2010-08-18 11:41:32 +01:00
Elliot Smith
1b2606a850 cookbook: Modified ordering of statements in cross-fade example
Changed the order of statements in the sample code to match
the order they will be explained in the walk-through in the recipe.
2010-08-18 11:41:32 +01:00
Elliot Smith
c230fd8dfd cookbook: Made code examples more consistent
Modified the code example for the Clutter API version
of the cross-fade to use the same command line
as the COGL version.

This also simplifies the explanation in the recipe.

Also made the COGL code sample more consistent with
the Clutter API code sample.
2010-08-18 11:41:32 +01:00
Elliot Smith
83a8d0b3bb cookbook: Added example code for texture cross-fading
Added simple image viewer which loads image file names
from a directory, displays the first one, then displays
the next in the list with each key press. Uses the
primitive fade front in/fade back out approach.

Also adapted Emmanuele's example code which uses Cogl
to produce a similar effect, but within a single texture.
This code loads two images specified on the command
line and cross-fades between them.
2010-08-18 11:41:32 +01:00