Emmanuele Bassi [Tue, 1 Jun 2010 13:45:55 +0000 (14:45 +0100)]
actor: Add "effects" to the animatable metas
Since ClutterEffect is an ActorMeta it should be possible to animate the
properties of named effects using the @effects syntax, just like it
happens for actions and constraints.
Emmanuele Bassi [Mon, 17 May 2010 11:55:46 +0000 (12:55 +0100)]
shader-effect: Simplify setting the shader source
Sub-classes of ShaderEffect currently have to get the handle for the
Cogl shader and call cogl_shader_source(); this makes it awkward to
implement a ShaderEffect, and it exposes handles and Cogl API that we
might want to change in the future.
We should provide a ClutterShaderEffect method that allows to (safely)
set the shader source at the right time for sub-classes to use.
Emmanuele Bassi [Wed, 21 Apr 2010 10:30:06 +0000 (11:30 +0100)]
docs: Add Effects API to the reference
Emmanuele Bassi [Fri, 16 Apr 2010 11:33:20 +0000 (12:33 +0100)]
effect: Rework the OffscreenEffect painting
The OffscreenEffect should set up the off screen draw buffer so that it
has the same projection and modelview as if it where on screen; we
achieve that by setting up the viewport to be the same size of the stage
but with an initial offset given by the left-most vertex of the actor.
When we paint the texture attached to the FBO we then set up the
modelview matrix of the on screen draw buffer so that it's the same as
the stage one: this way, the texture will be painted in screen
coordinates and it will occupy the same area as the actor would have
had.
Emmanuele Bassi [Tue, 13 Apr 2010 23:40:24 +0000 (00:40 +0100)]
effect: Add ColorizeEffect
A copy of DesaturateEffect that converts to grayscale and applies a
user-defined tint to the render target.
Emmanuele Bassi [Fri, 9 Apr 2010 15:14:21 +0000 (16:14 +0100)]
effect: Add DesaturateEffect
A simple shader-based effect that desaturates an actor and its contents
based on a controllable factor.
Emmanuele Bassi [Thu, 8 Apr 2010 17:46:54 +0000 (18:46 +0100)]
effect: Add BlurEffect
A simple, GLSL shader-based blur effect.
The blur shader is taken straight from the test-shader.c interactive
test case. It's a fairly clunky, inefficient and visually incorrect
implementation of a box blur, but it's all we have right now until I
figure out a way to do multi-pass shading with the current API.
Emmanuele Bassi [Tue, 13 Apr 2010 15:40:31 +0000 (16:40 +0100)]
effect: Add ShaderEffect
The ShaderEffect class is an abstract base type for shader-based
effects. GLSL-based effects should be implemented by sub-classing
ShaderEffect and overriding ActorMeta::set_actor() to set the source
code of the shader, and Effect::pre_paint() to update the uniform
values, if any.
The ShaderEffect has a generic API for sub-classes to set the values
of the uniforms defined by their shaders, and it uses the shader
types we defined for ClutterShader, to avoid re-inventing the wheel
every time.
Emmanuele Bassi [Mon, 17 May 2010 10:39:27 +0000 (11:39 +0100)]
effect: Add OffscreenEffect
The OffscreenEffect class is meant to be used to implement Effect
sub-classes that create an offscreen framebuffer and redirect the
actor's paint sequence there. The OffscreenEffect is useful for
effects using fragment shaders.
Any shader-based effect being applied to an actor through an offscreen
buffer should be used before painting the resulting target material and
not for every actor. This means that doing:
pre_paint: cogl_program_use(program)
set up offscreen buffer
paint: [ actors ] → offscreen buffer → target material
post_paint: paint target material
cogl_program_use(null)
Is not correct. Unfortunately, we cannot really do:
post_paint: cogl_program_use(program)
paint target material
cogl_program_use(null)
Because the OffscreenEffect::post_paint() implementation also pops the
offscreen buffer and re-instates the previous framebuffer:
post_paint: cogl_program_use(program)
change frame buffer ← ouch!
paint target material
cogl_program_use(null)
One way to fix it is to allow using the shader right before painting
the target material - which means adding a new virtual inside the
OffscreenEffect class vtable in additions to the ones defined by the
parent Effect class.
The newly-added paint_target() virtual allows the correct sequence of
actions by adding an entry point for sub-classes to wrap the "paint
target material" operation with custom code, in order to implement the
case above correctly as:
post_paint: change frame buffer
cogl_program_use(program)
paint target material
cogl_program_use(null)
The added upside is that sub-classes of OffscreenEffect involving
shaders really just need to override the prepare() and paint_target()
virtuals, since the pre_paint() and post_paint() do all that's needed.
Emmanuele Bassi [Thu, 8 Apr 2010 09:55:15 +0000 (10:55 +0100)]
Add the ClutterEffect abstract class
ClutterEffect is an abstract class that should be used to apply effects
on generic actors.
The ClutterEffect class just defines what an effect should implement; it
could be defined as an interface, but we might want to add some default
behavior dependent on the internal state at a later point.
The effect API applies to any actor, so we need to provide a way to
assign an effect to an actor, and let ClutterActor call the Effect
methods during the paint sequence.
Once an effect is attached to an actor we will perform the paint in this
order:
• Effect::pre_paint()
• Actor::paint signal emission
• Effect::post_paint()
Since an effect might collide with the Shader class, we either allow a
shader or an effect for the time being.
Emmanuele Bassi [Mon, 19 Apr 2010 11:32:15 +0000 (12:32 +0100)]
actor: Reset the modelview matrix
When getting the relative modelview matrix we need to reset it to the
stage's initial state or, at least, initialize it to the identity
matrix, instead of assuming we have an empty stack.
Damien Lespiau [Thu, 3 Jun 2010 10:33:54 +0000 (11:33 +0100)]
build: Distribute cogl-object.h
cogl-object.h is a new public header. Include it in the right list of
source files to have it distributed.
Emmanuele Bassi [Tue, 1 Jun 2010 13:14:41 +0000 (14:14 +0100)]
docs: Miscellaneous fixes to silence gtk-doc
Robert Bragg [Fri, 28 May 2010 00:01:28 +0000 (01:01 +0100)]
clip_stack: Remove use of CoglHandle in the CoglClipStack API
This replaces the use of CoglHandle with strongly type CoglClipStack *
pointers instead. The only function not converted for now is
cogl_is_clip_stack which will be done in a later commit.
Robert Bragg [Thu, 27 May 2010 23:51:40 +0000 (00:51 +0100)]
bitmap: Remove use of CoglHandle in the CoglBitmap API
This replaces the use of CoglHandle with strongly type CoglBitmap *
pointers instead. The only function not converted for now is
cogl_is_bitmap which will be done in a later commit.
Robert Bragg [Thu, 27 May 2010 23:35:47 +0000 (00:35 +0100)]
path: Remove use of CoglHandle in the CoglPath API
This replaces the use of CoglHandle with strongly type CoglPath *
pointers instead. The only function not converted for now is
cogl_is_path which will be done in a later commit.
Robert Bragg [Tue, 1 Jun 2010 10:50:02 +0000 (11:50 +0100)]
cogl: avoid ‘_cogl_xyz_handle_new’ defined but not used warnings
This patch makes it so that only the backwards compatibility
COGL_HANDLE_DEFINE macro defines a _cogl_xyz_handle_new function. The
new COGL_OBJECT_DEFINE macro only defines a _cogl_xyz_object_new
function.
Damien Lespiau [Thu, 27 May 2010 12:30:07 +0000 (13:30 +0100)]
analysis: Fix some CoglFixed API
2 functions where not correctly defined/documented, use the actual
symbol name instead.
Damien Lespiau [Thu, 27 May 2010 12:28:43 +0000 (13:28 +0100)]
analysis: Use static functions when possible
It's best to ensure the functions only used in one compilation unit are
marked as static so GCC can inline them if it feels like it.
Damien Lespiau [Thu, 27 May 2010 11:18:29 +0000 (12:18 +0100)]
analysis: Make all function declarations be protoypes
It's valid C to declare a function omitting it prototype, but it seems
to be a good practise to always declare a function with its
corresponding prototype.
Damien Lespiau [Thu, 27 May 2010 08:23:26 +0000 (09:23 +0100)]
analysis: Fix the "key-press-event" callback signature
We were returning FALSE in a function declared as returning a gpointer.
Turns out that the function should return a gboolea instead.
Damien Lespiau [Thu, 27 May 2010 08:07:11 +0000 (09:07 +0100)]
analysis: None used in pointer context
While this is totally fine (None is 0L and, in the pointer context, will
be converted in the right internal NULL representation, which could be a
value with some bits to 1), I believe it's clearer to use NULL instead
of None when we talk about pointers.
Damien Lespiau [Thu, 27 May 2010 07:28:29 +0000 (08:28 +0100)]
analysis: FALSE/0 used in pointer context
While this is totally fine (0 in the pointer context will be converted
in the right internal NULL representation, which could be a value with
some bits to 1), I believe it's clearer to use NULL in the pointer
context.
It seems that, in most case, it's more an overlook than a deliberate
choice to use FALSE/0 as NULL, eg. copying a _COGL_GET_CONTEXT (ctx, 0)
or a g_return_val_if_fail (cond, 0) from a function returning a
gboolean.
Emmanuele Bassi [Sun, 30 May 2010 14:24:18 +0000 (15:24 +0100)]
Update git ignore file
Robert Bragg [Thu, 27 May 2010 22:40:40 +0000 (23:40 +0100)]
buffer: Remove use of CoglHandle in the CoglBuffer API
This replaces the use of CoglHandle with strongly type CoglBuffer *
pointers instead. The only function not converted for now is
cogl_is_buffer which will be done in a later commit.
Robert Bragg [Thu, 27 May 2010 22:31:40 +0000 (23:31 +0100)]
Start eradicating the CoglHandle typedef
CoglHandle is a common source of complaints and confusion because people
expect a "handle" to be some form of integer type with some indirection
to lookup the corresponding objects as opposed to a direct pointer.
This patch starts by renaming CoglHandle to CoglObject * and creating
corresponding cogl_object_ APIs to replace the cogl_handle ones.
The next step though is to remove all use of CoglHandle in the Cogl APIs
and replace with strongly typed pointer types such as CoglMaterial * or
CoglTexture * etc also all occurrences of COGL_INVALID_HANDLE can just
use NULL instead.
After this we will consider switching to GTypeInstance internally so we
can have inheritance for our types and hopefully improve how we handle
bindings.
Note all these changes will be done in a way that maintains the API and
ABI.
Neil Roberts [Fri, 28 May 2010 17:12:53 +0000 (18:12 +0100)]
cogl-texture-2d: Regenerate the mipmaps when the texture is modified
When the texture is modified by cogl_texture_set_region, it wasn't
setting mipmaps_dirty so it would never update the mipmaps.
Robert Bragg [Fri, 28 May 2010 16:11:31 +0000 (17:11 +0100)]
texture: don't use a static bool to gate warning
in create_pick_material we were using a static boolean to gate when we
show a warning, but that would mean if the problem recurs between
different textures then the warning will only be shown once. We now have
a private bitfield flag instead, just so we don't spew millions of
warnings if the problem is recurring.
Robert Bragg [Fri, 25 Sep 2009 18:14:40 +0000 (19:14 +0100)]
[texture] Support picking textures according to their alpha channel
This adds a boolean "pick-with-alpha" property to ClutterTexture and when
true, it will use the textures alpha channel to define the actors shape when
picking.
Users should be aware that it's a bit more expensive to pick textures like
this (so probably best not to blindly enable it on *all* your textures)
since it implies rasterizing the texture during picking whereas we would
otherwise just send a solid filled quad to the GPU. It will also interrupt
the internal batching of geometry for pick renders which can otherwise often
be done in a single draw call.
Robert Bragg [Fri, 25 Sep 2009 18:04:13 +0000 (19:04 +0100)]
[material] fix _set_alpha_test_function: missing a glEnable(GL_ALPHA_TEST)
Since the default alpha test function of GL_ALWAYS is equivalent to
GL_ALPHA_TEST being disabled we don't need to worry about Enabling/Disabling
it when flushing material state, instead it's enough to leave it always
enabled. We will assume that any driver worth its salt wont incur any
additional cost for glEnable (GL_ALPHA_TEST) + GL_ALWAYS vs
glDisable (GL_ALPHA_TEST).
This patch simply calls glEnable (GL_ALPHA_TEST) in cogl_create_context
Robert Bragg [Wed, 23 Sep 2009 18:04:03 +0000 (19:04 +0100)]
[texture] remove redundant if (paint_opacity == 0) bailout
clutter_texture_paint shouldn't need to optimize the case where
paint_opacity == 0 and bailout, since we've been doing this optimization for
all actors in clutter_actor_paint for a while now.
Emmanuele Bassi [Thu, 27 May 2010 15:32:32 +0000 (16:32 +0100)]
test-scrolling: Use a better looking bounce easing
Neil Roberts [Thu, 27 May 2010 13:54:14 +0000 (14:54 +0100)]
cogl-vertex-buffer: Don't disable any texture coord arrays
The enabled state of the texture coord arrays is cached in the cogl
context so there is no need to disable them when we've finished
rendering a vbo.
Neil Roberts [Thu, 27 May 2010 13:51:44 +0000 (14:51 +0100)]
cogl: Record new enabled arrays in _cogl_disable_other_texcoord_arrays
When _cogl_disable_other_texcoord_arrays is called it disables the
neccessary texcoord arrays and then removes the bits for the disabled
arrays in ctx->texcoord_arrays_enabled. However none of the places
that call the function then set any bits in ctx->texcoord_arrays_enabled
so the arrays would never get marked and they would never get disabled
again.
This patch just changes it so that _cogl_disable_other_texcoord_arrays
also sets the corresponding bits in ctx->texcoord_arrays_enabled.
Emmanuele Bassi [Thu, 27 May 2010 11:32:45 +0000 (12:32 +0100)]
test-scrolling: Animate intermediate positions
Animating intermediate positions in the viewport panning is a neat
effect.
Emmanuele Bassi [Thu, 27 May 2010 11:30:22 +0000 (12:30 +0100)]
drag-action: Re-use press_button in emit_drag_end()
Since emit_drag_end() can be called from a MOTION event capture we
cannot call clutter_event_get_button(). We should, instead, use the
press_button value because if we're emitting ::drag-end it means we
also emitted ::drag-begin and the value is valid.
Emmanuele Bassi [Wed, 26 May 2010 15:09:47 +0000 (16:09 +0100)]
actor: Add accessors pair for :clip-to-allocation
We should have an accessors pair for the :clip-to-allocation property,
to avoid going through the generic GObject accessors.
Emmanuele Bassi [Wed, 26 May 2010 14:58:15 +0000 (15:58 +0100)]
Add a scrolling interactive example
We can use a container with :clip-to-allocation set to TRUE and a
DragAction to create a panning viewport.
Emmanuele Bassi [Wed, 26 May 2010 13:18:19 +0000 (14:18 +0100)]
Use ClickAction in test-animation
Instead of using ::button-press-event.
Emmanuele Bassi [Wed, 26 May 2010 13:16:48 +0000 (14:16 +0100)]
actor: Fix a type check thinko in add_action_with_name()
Emmanuele Bassi [Wed, 26 May 2010 13:09:24 +0000 (14:09 +0100)]
docs: Description fixes for Action and Constraint
Emmanuele Bassi [Wed, 26 May 2010 12:43:42 +0000 (13:43 +0100)]
state: Minor fixes and documentation additions
Clean up the code a bit, and move common code paths into separate
function. Also, document clutter_state_set() with examples.
Emmanuele Bassi [Wed, 26 May 2010 12:40:18 +0000 (13:40 +0100)]
introspection: Add --pkg atk
We need to tell the introspection scanner all the dependencies we
require, including the pkg-config name to use when compiling the
GIR file into a typelib object.
Emmanuele Bassi [Tue, 25 May 2010 12:27:29 +0000 (13:27 +0100)]
click-action: Handle the event
In case we did handle the event, we should return TRUE from the ::event
signal handler.
Emmanuele Bassi [Tue, 25 May 2010 12:10:38 +0000 (13:10 +0100)]
docs: Fix DragAction documentation
The ::drag-motion signal does not have a ModifierType argument; also,
there's no need to connect to the ::drag-motion signal any more.
Emmanuele Bassi [Tue, 25 May 2010 12:03:24 +0000 (13:03 +0100)]
Fix typo in get_accessible()
Emmanuele Bassi [Tue, 25 May 2010 11:54:59 +0000 (12:54 +0100)]
actor: Put get_accessible() at the end of the class structure
New virtual functions cannot go wherever they want, if we need to
preserve the ABI.
Also, the coding style should match the rest of ClutterActor and
Clutter's own coding style.
Emmanuele Bassi [Tue, 25 May 2010 10:53:59 +0000 (11:53 +0100)]
docs: Add ClickAction to the API reference
And clean up the reference index.
Emmanuele Bassi [Mon, 24 May 2010 10:30:17 +0000 (11:30 +0100)]
actor-meta: Disconnect on actor destroy
When destroying an Actor the various ActorMeta instance should already
be disposed - unless something is holding a reference to them, in which
case we should use the ::destroy signal to unset the ActorMeta:actor
back pointer.
Emmanuele Bassi [Mon, 24 May 2010 09:41:19 +0000 (10:41 +0100)]
action: Add ClickAction
ClickAction adds "clickable" semantics to an actor. It provides all
the business logic to emit a high-level "clicked" signal from the
various low-level signals inside ClutterActor.
Emmanuele Bassi [Tue, 25 May 2010 10:01:46 +0000 (11:01 +0100)]
drag: Add a default drag-motion behaviour
The DragAction should, by default, drag the actor to which it has been
applied, instead of delegating what to do to the developer. If custom
code need to override it, g_signal_stop_emission_by_name() can be called
to stop the default handler to ever running.
Emmanuele Bassi [Mon, 24 May 2010 15:57:35 +0000 (16:57 +0100)]
Post-release version bump to 1.3.3
Emmanuele Bassi [Mon, 24 May 2010 15:50:36 +0000 (16:50 +0100)]
Release 1.3.2 (snapshot)
Emmanuele Bassi [Mon, 24 May 2010 15:46:38 +0000 (16:46 +0100)]
docs: Add Actor.get_accessible() to the API reference
Emmanuele Bassi [Mon, 24 May 2010 15:12:47 +0000 (16:12 +0100)]
docs: Update NEWS
Øyvind Kolås [Mon, 24 May 2010 14:39:01 +0000 (15:39 +0100)]
state: replaced test with a more complex one
Øyvind Kolås [Mon, 24 May 2010 15:10:00 +0000 (16:10 +0100)]
state: fix clutter_state_change (state, "state-name", FALSE)
Properties were not being updated correctly.
Neil Roberts [Mon, 24 May 2010 11:40:11 +0000 (12:40 +0100)]
cogl: Use a CoglBitmask to store the list of used texcoord arrays
Instead of directly using a guint32 to store a bitmask for each used
texcoord array, it now stores them in a CoglBitmask. This removes the
limitation of 32 layers (although there are still other places in Cogl
that imply this restriction). To disable texcoord arrays code should
call _cogl_disable_other_texcoord_arrays which takes a bitmask of
texcoord arrays that should not be disabled. There are two extra
bitmasks stored in the CoglContext which are used temporarily for this
function to avoid allocating a new bitmask each time.
http://bugzilla.openedhand.com/show_bug.cgi?id=2132
Neil Roberts [Thu, 20 May 2010 16:31:42 +0000 (17:31 +0100)]
cogl: Add an internal CoglBitmask type
This implements a growable array of bits called CoglBitmask. The
CoglBitmask is intended to be cheap if less than 32 bits are used. If
more bits are required it will allocate a GArray. The type is meant to
be allocated on the stack but because it can require additional
resources it also has a destroy function.
http://bugzilla.openedhand.com/show_bug.cgi?id=2132
Neil Roberts [Wed, 19 May 2010 23:40:24 +0000 (00:40 +0100)]
cogl-material: Fix the count of the number of layers
Previously the counter for the number of layers was only updated
whenever the texture handle for a layer changes. However there are
many other ways for a new layer to be created for example by setting a
layer combine constant. Also by default the texture on a layer is
COGL_INVALID_HANDLE so if the application tries to create an explicit
layer with no texture by calling cogl_material_set_layer with
COGL_INVALID_HANDLE then it also wouldn't update the count.
This patch fixes that by incrementing the count in
cogl_material_get_layer instead. This function is called by all
functions that may end up creating a layer so it seems like the most
appropriate place.
http://bugzilla.openedhand.com/show_bug.cgi?id=2132
Neil Roberts [Wed, 19 May 2010 23:16:49 +0000 (00:16 +0100)]
cogl-vertex-buffer: Don't disable layers with no texture coords
It should be quite acceptable to use a texture without defining any
texture coords. For example a shader may be in use that is doing
texture lookups without referencing the texture coordinates. Also it
should be possible to replace the vertex colors using a texture layer
without a texture but with a constant layer color.
enable_state_for_drawing_buffer no longer sets any disabled layers in
the overrides. Instead of counting the number of units with texture
coordinates it now keeps them in a mask. This means there can now be
gaps in the list of enabled texture coordinate arrays. To cope with
this, the Cogl context now also stores a mask to track the enabled
arrays. Instead of code manually iterating each enabled array to
disable them, there is now an internal function called
_cogl_disable_texcoord_arrays which disables a given mask.
I think this could also fix potential bugs when a vertex buffer has
gaps in the texture coordinate attributes that it provides. For
example if the vertex buffer only had texture coordinates for layer 2
then the disabling code would not disable the coordinates for layers 0
and 1 even though they are not used. This could cause a crash if the
previous data for those arrays is no longer valid.
http://bugzilla.openedhand.com/show_bug.cgi?id=2132
Neil Roberts [Wed, 19 May 2010 22:42:40 +0000 (23:42 +0100)]
test-cogl-materials: Test invalid layers with a constant color
This adds a test using a layer with no texture but that replaces the
fragment color with the layer constant. This currently causes the test
to fail.
http://bugzilla.openedhand.com/show_bug.cgi?id=2132
Neil Roberts [Wed, 19 May 2010 22:36:18 +0000 (23:36 +0100)]
test-cogl-materials: Run the 'all layers' test with different prims
The drawing code from test_invalid_texture_layers which draws a
rectangle, a polygon and a vertex buffer has been split out to
separate function. test_using_all_layers now also uses this so that it
will also test the other two primitives. This causes the test to fail
when all of the layers are drawn using a vertex buffer.
http://bugzilla.openedhand.com/show_bug.cgi?id=2132
Alejandro Piñeiro [Tue, 13 Apr 2010 11:23:15 +0000 (13:23 +0200)]
Implement AtkImplementor on ClutterActor
Implements AtkImplementor interface on ClutterActor, and his method
atk_implementor_ref_accessible.
More information:
http://library.gnome.org/devel/atk/stable/AtkObject.html#AtkImplementor
Alejandro Piñeiro [Mon, 12 Apr 2010 18:10:24 +0000 (20:10 +0200)]
Implemented clutter_actor_get_accessible
Added the implementation for clutter_actor_get_accessible, virtual
ClutterActor function, used to obtain the accessible object of
any ClutterActor.
As it is defined virtual, it would be possible to redefine it, so
any custom clutter actor could implement their accessibility object,
withouth relying totally on a accessibility implementation module.
See gtkiconview as example.
http://bugzilla.openedhand.com/show_bug.cgi?id=2070
Alejandro Piñeiro [Mon, 12 Apr 2010 17:34:06 +0000 (19:34 +0200)]
Added Atk dependency
Added Atk dependency, in order to implement a built-in
accessibility support on Clutter.
Emmanuele Bassi [Mon, 24 May 2010 14:34:43 +0000 (15:34 +0100)]
build: Remove shave files from EXTRA_DIST
We don't use Shave any more, and require automake 1.11 instead.
Emmanuele Bassi [Mon, 24 May 2010 14:14:09 +0000 (15:14 +0100)]
state: Use Interval.compute() instead of compute_value()
Use the newly-added compute() variant to avoid creating a GValue only
for getting it copied by g_object_set_property().
Emmanuele Bassi [Mon, 24 May 2010 14:06:14 +0000 (15:06 +0100)]
interval: Add a pointer variant to compute_value()
ClutterInterval.compute_value() computes the new value given a progress
and copies it to a given GValue. Since most of the time we want to pass
that very same value to another function that copies it again, we should
have a compute_value() variant that stores that computed value inside
ClutterInterval and returns a pointer to it. This way we initialize the
result GValue just once and we never copy it, as long as the Interval
instance is valid.
Emmanuele Bassi [Mon, 24 May 2010 13:20:23 +0000 (14:20 +0100)]
docs: Align parameter names between header and source code
Emmanuele Bassi [Mon, 24 May 2010 11:00:43 +0000 (12:00 +0100)]
docs: Add ClutterState to the API reference
Emmanuele Bassi [Mon, 24 May 2010 09:42:03 +0000 (10:42 +0100)]
Merge branch 'wip/state-machine'
* wip/state-machine:
Do not use wildcards in test-state
script: Implement State deserialization
state: added a "target-state" property
state: documented data structures
Add State interactive tests to the ignore file
state: Documentation and introspection annotation fixes
state: Minor coding style fixes
state: Clean up the header's documentation
state: Constify StateKey accessors
Do not include clutter.h from a Clutter header file
state-machine: made clutter_state_change take a boolean animate argument
state-machine: use clutter_timeline_get_progress
state-machine: add completed signal
state machine: added state machine
Conflicts:
.gitignore
Emmanuele Bassi [Fri, 21 May 2010 13:38:37 +0000 (14:38 +0100)]
Merge branch 'wip/framebuffer-bits'
* wip/framebuffer-bits:
Implement accessors for the color bits in a framebuffer
Emmanuele Bassi [Fri, 21 May 2010 13:22:56 +0000 (14:22 +0100)]
Do not use wildcards in test-state
Use named states, like in a real case.
Emmanuele Bassi [Fri, 21 May 2010 13:13:14 +0000 (14:13 +0100)]
script: Implement State deserialization
It should be possible to describe ClutterState transitions using
ClutterScript in a similar way as ClutterAnimator.
Emmanuele Bassi [Fri, 21 May 2010 09:55:09 +0000 (10:55 +0100)]
Merge branch 'wip/constraints'
* wip/constraints: (24 commits)
Add the Cogl API reference to the fixxref extra directories
Document the internal MetaGroup class
Remove the construct-only flag from ActorMeta:name
doc: Remove gtk-doc annotations from the json-glib copy
doc: Fix parameter documentation
Add named modifiers for Action and Constraint
Remove a redundant animation
Set the stage resizable in test-constraints
Use a 9 grid for the constraints test
Miscellaneous documentation fixes
docs: Document animating action and constraint properties
docs: Document BindConstraint and AlignConstraint
constraint: Rename BindConstraint:bind-axis
constraints: Add AlignConstraint
tests: Add a constraints interactive test
constraint: Add BindConstraint
actor: Implement Animatable
animation: Use the new Animatable API for custom properties
animatable: Add custom properties to Animatable
constraint: Add ClutterConstraint base class
...
Conflicts:
configure.ac
Øyvind Kolås [Fri, 21 May 2010 09:37:42 +0000 (10:37 +0100)]
state: added a "target-state" property
When set the ClutterState transitions to the new state.
Øyvind Kolås [Thu, 20 May 2010 22:05:16 +0000 (23:05 +0100)]
state: documented data structures
Emmanuele Bassi [Thu, 20 May 2010 17:58:30 +0000 (18:58 +0100)]
Add State interactive tests to the ignore file
Emmanuele Bassi [Thu, 20 May 2010 17:57:27 +0000 (18:57 +0100)]
state: Documentation and introspection annotation fixes
Emmanuele Bassi [Thu, 20 May 2010 17:34:34 +0000 (18:34 +0100)]
state: Minor coding style fixes
Emmanuele Bassi [Thu, 20 May 2010 16:46:52 +0000 (17:46 +0100)]
state: Clean up the header's documentation
Emmanuele Bassi [Thu, 20 May 2010 16:34:36 +0000 (17:34 +0100)]
state: Constify StateKey accessors
Since the accessors do not modify the StateKey we should constify the
argument.
Emmanuele Bassi [Thu, 20 May 2010 16:34:02 +0000 (17:34 +0100)]
Do not include clutter.h from a Clutter header file
Clutter header files should just include the needed headers.
Robert Bragg [Thu, 20 May 2010 13:54:44 +0000 (14:54 +0100)]
math: Adds an experimental cogl_vector3_* API
This adds a math utility API for handling 3 component, single precision
float vectors with the following; mostly self explanatory functions:
cogl_vector3_init
cogl_vector3_init_zero
cogl_vector3_equal
cogl_vector3_equal_with_epsilon
cogl_vector3_copy
cogl_vector3_free
cogl_vector3_invert
cogl_vector3_add
cogl_vector3_subtract
cogl_vector3_multiply_scalar
cogl_vector3_divide_scalar
cogl_vector3_normalize
cogl_vector3_magnitude
cogl_vector3_cross_product
cogl_vector3_dot_product
cogl_vector3_distance
Since the API is experimental you will need to define
COGL_ENABLE_EXPERIMENTAL_API before including cogl.h if you want to use
the API.
Øyvind Kolås [Thu, 20 May 2010 15:13:46 +0000 (16:13 +0100)]
state-machine: made clutter_state_change take a boolean animate argument
Most of the time this will be TRUE, pass FALSE to change to the target
state immediately.
Øyvind Kolås [Thu, 20 May 2010 14:41:29 +0000 (15:41 +0100)]
state-machine: use clutter_timeline_get_progress
Øyvind Kolås [Wed, 12 May 2010 16:03:25 +0000 (17:03 +0100)]
state-machine: add completed signal
Added a completed signal to the animator
Øyvind Kolås [Tue, 11 May 2010 14:04:34 +0000 (15:04 +0100)]
state machine: added state machine
Emmanuele Bassi [Thu, 20 May 2010 15:19:25 +0000 (16:19 +0100)]
cookbook: Add a recipe for CairoTexture
The Clutter cookbook has a chapter for textures. It would be useful to
provide a recipe on simple uses of ClutterCairoTexture as part of that.
Some suggested content is attached.
Neil Roberts [Thu, 20 May 2010 11:37:56 +0000 (12:37 +0100)]
cogl-texture-2d: Optimise _cogl_texture_2d_is_pot
This takes the simple algorithm from here:
http://graphics.stanford.edu/~seander/bithacks.html#DetermineIfPowerOf2
This avoids a loop and is much faster.
Emmanuele Bassi [Thu, 20 May 2010 11:03:47 +0000 (12:03 +0100)]
Add the Cogl API reference to the fixxref extra directories
Emmanuele Bassi [Thu, 20 May 2010 11:03:10 +0000 (12:03 +0100)]
Document the internal MetaGroup class
Just because it's an internal class, ClutterMetaGroup should not be left
undocumented.
Emmanuele Bassi [Thu, 20 May 2010 11:02:13 +0000 (12:02 +0100)]
Remove the construct-only flag from ActorMeta:name
The ClutterActorMeta:name property should be read-write, and be
writeable at any time.
Emmanuele Bassi [Thu, 20 May 2010 10:45:54 +0000 (11:45 +0100)]
doc: Remove gtk-doc annotations from the json-glib copy
There's no need to use gtk-doc annotations: the API is internal to
Clutter.
Emmanuele Bassi [Thu, 20 May 2010 10:45:25 +0000 (11:45 +0100)]
doc: Fix parameter documentation
Emmanuele Bassi [Thu, 20 May 2010 10:19:51 +0000 (11:19 +0100)]
Add named modifiers for Action and Constraint
The ClutterActor API should have modifier methods for adding, removing
and retrieving Actions and Constraints using the ClutterActorMeta:name
property - mostly, for convenience.
Emmanuele Bassi [Wed, 19 May 2010 17:23:29 +0000 (18:23 +0100)]
Remove a redundant animation
Emmanuele Bassi [Wed, 19 May 2010 17:20:27 +0000 (18:20 +0100)]
Set the stage resizable in test-constraints
To demonstrate that constraints can be used to reposition actors in a
resizable stage, set the :user-resizable property to TRUE, and spend the
next 15 minutes playing with the stage size.
Emmanuele Bassi [Wed, 19 May 2010 17:17:49 +0000 (18:17 +0100)]
Use a 9 grid for the constraints test
Let's complicate the interactive constraints test a little bit by adding
more actors and animating two constraints at a time.