Commit Graph

4874 Commits

Author SHA1 Message Date
Elliot Smith
7c196d31b4 cookbook: Added scribble example for pointer motion recipe
Simple scribbler application which demonstrates tracking
mouse enter and motion events on a texture, drawing with
COGL and ClutterPath as they occur.
2010-08-20 12:39:48 +01:00
Elliot Smith
b648bff10c cookbook: Renamed example for pointer crossing
Decided might be better to cover crossing and motion under
a broader "pointer motion" recipe, so renamed the example
(which only shows pointer crossing event handling).
2010-08-20 12:39:48 +01:00
Elliot Smith
72ddd471f0 cookbook: Added example for pointer cross recipe
Code example demonstrates detecting pointers entering/leaving
an actor by implementing a (very) simple button with hover
effect.
2010-08-20 12:39:48 +01:00
Emmanuele Bassi
213bd1eab4 debug: Add a macro for checking debug flags 2010-08-19 13:57:10 +01:00
Emmanuele Bassi
459a6bb24c click-action: Add a method to force a release
It can be useful to be able to forcibly break the grab set up by the
ClickAction. The newly added release() method provides a mechanism to
release the grab and unset the :held state of the ClickAction.
2010-08-19 12:10:43 +01:00
Emmanuele Bassi
db7d821ef6 click-action: Add attribution
The ClickAction semantics were inspired by the StClickable widget in the
GNOME Shell Toolkit (St).
2010-08-19 11:26:51 +01:00
Robert Bragg
5ccaa61e4f docs: Clarifies that queue_redraw also applies to picking
This clarifies the documentation for clutter_actor_queue_redraw to
explain that custom actors should call this whenever some private state
changes that affects painting *or* picking.
2010-08-18 18:30:31 +01:00
Robert Bragg
f8940e3c9a clutter-texture: queue redraw when changing pick_with_alpha
The expectation is that actors should call clutter_actor_queue_redraw
when ever some private state changes that affects painting *or* picking.
ClutterTexture was not doing this for pick_with_alpha property changes.
2010-08-18 18:30:30 +01:00
Robert Bragg
965907deb3 Cache a full pick render if we have a static stage
The idea is that if we see multiple picks per frame then that implies
the visible scene has become static. In this case we can promote the
next pick render to be unclipped so we have valid pick values for the
entire stage. Now we can continue to read from this cached buffer until
the stage contents do visibly change.

Thanks to Luca Bruno on #clutter for this idea!
2010-08-18 18:30:30 +01:00
Emmanuele Bassi
c646a366c6 actor: Ignore paint() on actors being destroyed
OBVIOUS OPTIMIZATION IS OBVIOUS
2010-08-18 18:20:45 +01:00
Emmanuele Bassi
56097df60c docs: Improve paint() documentation 2010-08-18 18:20:04 +01:00
Elliot Smith
444d315078 cookbook: Use GdkPixbuf instead of getting data from a texture
Rewrote example for single texture + COGL to use
a GdkPixbuf to load images, rather than reading data
out of another CoglTexture.

The data is then loaded from the pixbuf to a region of
the CoglTexture (as before).
2010-08-18 16:02:51 +01:00
Elliot Smith
c207820bef cookbook: Added a recipe for cross-fading between two images
The recipe covers a two texture approach (using the Clutter API)
and a single texture approach (using COGL).

It also discusses issues with cross-fading between images of
different sizes with the COGL API, and gives a longer
example of cycling through multiple images in a slideshow
application.
2010-08-18 11:42:00 +01:00
Elliot Smith
c492faecb2 cookbook: Modified COGL example for consistency
Changed the stage size so the COGL API example for cross-fade
has a stage the same size as the two texture example.
2010-08-18 11:41:32 +01: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
e332236b87 cookbook: Added a longer slideshow example
Cross-fading between two images is straightforward,
but cycling between more than two is more efficient
if done by copying COGL textures between the
two textures, rather than trying to reposition the
textures.

The example demonstrates how to reuse a pair of
textures to cycle through multiple images.
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
Emmanuele Bassi
dc7d62a42a Post-release version bump to 1.3.13 2010-08-18 11:41:32 +01:00
Emmanuele Bassi
6d751bf951 Release Clutter 1.3.12 (developers snapshot) 2010-08-18 11:41:32 +01:00
Emmanuele Bassi
ad0c36e1a1 docs: Fixes to avoid gtk-doc warnings 2010-08-17 14:54:20 +01:00
Emmanuele Bassi
50f4bfd7f7 build: Remove dolt remnants
We don't use Dolt any more, since we depend on libtool 2.2.
2010-08-17 12:22:51 +01:00
Emmanuele Bassi
06ecaa98f1 docs: Add :keep-aspect-ratio behaviour to the notes 2010-08-16 16:33:32 +01:00
Emmanuele Bassi
92b1a33eb3 texture: Default square textures to height-for-width
Square textures should have a preferred geometry request set to
height-for-width, as it is the default for Clutter itself.
2010-08-16 15:56:49 +01:00
Emmanuele Bassi
dc2aee4300 Post-release version bump to 1.3.13 2010-08-16 13:37:57 +01:00
Emmanuele Bassi
e75e6e0c97 Release Clutter 1.3.12 (developers snapshot) 2010-08-16 13:23:43 +01:00
Emmanuele Bassi
fd6d6a93f1 build: Fix distcheck errors 2010-08-16 13:23:10 +01:00
Emmanuele Bassi
3142b15a9f build: Use maintainer-clean for the ignore files removal
Instead of distclean.
2010-08-15 18:42:54 +01:00
Emmanuele Bassi
c4913bfce9 Revert "build: Distclean generated ignore files"
Git ignore files are not dist'ed, so it's pointless to remove them on
distclean.

This reverts commit f14587aadc.
2010-08-15 18:33:10 +01:00
Emmanuele Bassi
e43215a5c9 build: Rule for quick publishing of the cookbook
Just call `make publish`.
2010-08-14 08:53:18 +01:00
Emmanuele Bassi
94c8635d0f build: Autogenerate more ignore files
The tests/accessibility, tests/micro-bench and the examples directory
in the coobook create a lot of non-installed binaries. Since we know who
they are, and we ignore them, we can auto-generate the ignore files as
well.

The rest of Clutter is covered by the main ignore file.
2010-08-14 08:43:16 +01:00
Emmanuele Bassi
f14587aadc build: Distclean generated ignore files 2010-08-13 18:35:35 +01:00
Emmanuele Bassi
a3bc2ebfa7 build: Make test-conform depend on Makefile changes 2010-08-13 18:32:10 +01:00
Emmanuele Bassi
1e0a83b881 build: Autogenerate interactive/.gitignore
Exactly like we did for conform/.gitignore
2010-08-13 18:31:44 +01:00
Emmanuele Bassi
7c412464c2 build: Generate the conformance/.gitignore file
Since we are generating a lot of files that we should ignore, we should
generate the Git ignore file as well.
2010-08-13 18:25:22 +01:00
Emmanuele Bassi
e888da2180 build: Split up the test-conformance SOURCES
Having different sections should make it easier to add new test units to
the build.
2010-08-13 18:15:01 +01:00
Emmanuele Bassi
ff9a5a01b4 clutter.modules: Remove deps on gir-repository
Keep it in the moduleset, but don't let Clutter depend on it.
2010-08-13 18:14:10 +01:00
Emmanuele Bassi
a25cf14e97 Revert "clutter.modules: Remove deps on gir-repository"
This reverts commit 0ce9cf730b.

The commit contained unrelated changes
2010-08-13 18:12:43 +01:00
Emmanuele Bassi
0ce9cf730b clutter.modules: Remove deps on gir-repository
Keep it in the moduleset, but don't let Clutter depend on it.
2010-08-13 18:09:28 +01:00
Emmanuele Bassi
175b16a5c8 clutter.modules: Add a gtk2 module for gtk+ 2.x
Mx (and others) depend on gtk+ 2.x, and not on gtk+ 3.x.
2010-08-13 18:00:23 +01:00
Emmanuele Bassi
271e0d9604 animator: Plug some leaks 2010-08-13 17:03:02 +01:00
Robert Bragg
12031ca2c5 material: Implements weak materials
Weak materials are ones that don't take a reference on their parent and
they are associated with a callback that notifies when the material is
destroyed, because its parent was freed or modified.

More details can be found at:
http://wiki.clutter-project.org/wiki/CoglDesign/CoglMaterial

For now the concept is internal only but the plan is to make this public
at some point once we have tested the design internally.
2010-08-13 16:23:19 +01:00
Emmanuele Bassi
50c5ecfe87 state: Plug some memory leakage
Thanks to Valgrind, test-state-base now reports 0 bytes definitely lost.
2010-08-13 12:12:59 +01:00
Emmanuele Bassi
6c6e93d27a Merge remote branch 'elliot/cookbook-events-mouse-scroll'
* elliot/cookbook-events-mouse-scroll:
  cookbook: Cleaning up grammar and wording in mouse scroll recipe
  cookbook: Added more explanation about setting y coord on scrollable
  cookbook: Mentioned the animation in the sample code
  cookbook: Included video of the scroll example running
  cookbook: Made stage slightly smaller for scroll event example
  cookbook: Added video showing scrollable actor
  cookbook: Added walk through of code example for mouse scroll
  cookbook: Fixed link to example in mouse scroll recipe
  cookbook: Simplified full scroll example
  cookbook: Improved wording and formatting in mouse scroll intro.
  cookbook: Handle all possible mouse scroll directions
  cookbook: Build mouse scroll example with cookbook
  cookbook: Cleaned up redundant comments in code example
  cookbook: Added xmlns for XInclude to events docbook file
  cookbook: Added basic mouse scroll recipe
2010-08-12 18:29:08 +01:00
Neil Roberts
12f2481462 docs: Update the build instructions in the reference
This removes all references to SDL in the build instructions as the
backend is no longer available.  The OpenGL version required is only
1.2 not 1.4. The Windows build instructions were out of date and have
been replaced with a link to the wiki instead.
2010-08-12 17:30:45 +01:00
Emmanuele Bassi
daf6e73936 Remove last uses of cogl_program_uniform*
Following the commits:

  c03544da - clutter-shader: use cogl_program_set_uniform_xyz API
  a26119b5 - tests: Remove use of cogl_program_use

Remove the users of cogl_program_uniform_* and cogl_program_use() in the
shader-based effects.
2010-08-12 17:08:26 +01:00