* clutter/clutter-entry.c:
* clutter/clutter-label.c:
* clutter/clutter-rectangle.c:
* clutter/clutter-script.c:
* clutter/clutter-stage.c: Use the ParamSpecColor and GValue
API for ClutterColor-based properties.
* clutter/cogl/cogl-color.h:
* clutter/cogl/cogl-path.h:
* clutter/cogl/cogl-types.h:
* clutter/cogl/common/cogl-color.c: Deprecated cogl_color()
in favour of cogl_set_source_color() and friends; store the
CoglColor components as unsigned bytes instead of fixed point
normalized values; add functions for allocating, copying and
freeing CoglColor, for use of language bindings.
* clutter/cogl/cogl.h.in:
* clutter/cogl/cogl-deprecated.h: Added cogl-deprecated.h,
an header file containing the deprecation symbols similar
to clutter-deprecated.h.
* clutter/cogl/gl/Makefile.am:
* clutter/cogl/gl/cogl-texture.c:
* clutter/cogl/gl/cogl.c:
* clutter/cogl/gles/Makefile.am:
* clutter/cogl/gles/cogl-texture.c:
* clutter/cogl/gles/cogl.c: Update the GL and GLES implementations
of COGL after the CoglColor changes.
* clutter/clutter-actor.c:
* clutter/clutter-clone-texture.c:
* clutter/clutter-entry.c:
* clutter/clutter-label.c:
* clutter/clutter-rectangle.c:
* clutter/clutter-texture.c: Do not use CoglColor whenever it
is possible, and use cogl_set_source_color4ub() instead.
* clutter/pango/cogl-pango-render.c: Ditto as above.
* doc/reference/clutter/subclassing-ClutterActor.xml:
* doc/reference/cogl/cogl-sections.txt: Update the documentation.
* tests/interactive/test-cogl-offscreen.c:
* tests/interactive/test-cogl-primitives.c:
* tests/interactive/test-cogl-tex-convert.c:
* tests/interactive/test-cogl-tex-foreign.c:
* tests/interactive/test-cogl-tex-getset.c:
* tests/interactive/test-cogl-tex-polygon.c:
* tests/interactive/test-cogl-tex-tile.c:
* tests/interactive/test-paint-wrapper.c: Drop the usage of
CoglColor whenever it is possible.
Bug 1210 - Add CoglColor API
* clutter/cogl/cogl-color.h:
* clutter/cogl/cogl.h.in:
* clutter/cogl/common/Makefile.am:
* clutter/cogl/common/cogl-color.c:
* clutter/cogl/gl/Makefile.am:
* clutter/cogl/gl/cogl.c:
* clutter/cogl/gles/Makefile.am:
* clutter/cogl/gles/cogl-texture.c:
* clutter/cogl/gles/cogl.c: Add a new color-type, to be used by
COGL. CoglColor is optimized to allow the minimum amount of
conversions possible for both GL and GLES implementations.
* clutter/clutter-actor.c:
* clutter/clutter-clone-texture.c:
* clutter/clutter-entry.c:
* clutter/clutter-main.c:
* clutter/clutter-rectangle.c:
* clutter/clutter-stage.c:
* clutter/clutter-texture.c: Use CoglColor when needed.
* clutter/pango/pangoclutter-render.c: Use CoglColor when needed.
* doc/reference/cogl/cogl-docs.sgml:
* doc/reference/cogl/cogl-sections.txt: Update the documentation.
* tests/test-cogl-offscreen.c:
* tests/test-cogl-primitives.c:
* tests/test-cogl-tex-convert.c:
* tests/test-cogl-tex-foreign.c:
* tests/test-cogl-tex-getset.c:
* tests/test-cogl-tex-polygon.c:
* tests/test-cogl-tex-tile.c:
* tests/test-paint-wrapper.c: Update the tests.
* README: Update release notes.
* clutter/clutter-rectangle.c:
* clutter/clutter-group.c:
* clutter/clutter-entry.c:
* clutter/clutter-clone-texture.c: Remove unnecessary calls to
cogl_{push,pop}_matrix. The matrix is preserved in
clutter_actor_paint whenever the actor's transformation is applied
so there should be no need to push the matrix in actor paint
implementations unless it does some additional transformations
itself.
Bug #815 - Split up request, allocation, and paint box
* clutter/clutter-actor.[ch]: Rework the size allocation,
request and paint area. Now ::request_coords() is called
::allocate(), and ::query_coords() has been split into
::get_preferred_width() and ::get_preferred_height(). See
the documentation and the layout test on how to implement
a container and layout manager with the new API. (#915,
based on a patch by Havoc Pennington, Lucas Rocha and Johan
Bilien)
* clutter/clutter-clone-texture.c: Port CloneTexture to
the new size negotiation API; it just means forwarding
the requests to the parent texture.
* clutter/clutter-deprecated.h: Add deprecated and replaced
API.
* clutter/clutter-entry.c: Port Entry to the new size
negotiation API.
* clutter/clutter-group.c: Port Group to the new size
negotiation API; the semantics of the Group actor do not
change.
* clutter/clutter-label.c: Port Label to the new size
negotiation API, and vastly simplify the code.
* clutter/clutter-main.[ch]: Add API for executing a
relayout when needed.
* clutter/clutter-private.h: Add new Stage private API.
* clutter/clutter-rectangle.c: Update the get_abs_opacity()
call to get_paint_opacity().
* clutter/clutter-stage.c:
(clutter_stage_get_preferred_width),
(clutter_stage_get_preferred_height),
(clutter_stage_allocate),
(clutter_stage_class_init): Port Stage to the new size
negotiation API.
* clutter/clutter-texture.c: Port Texture to the new size
negotiation API.
* clutter/clutter-types.h: Add ClutterRequestMode enumeration.
* clutter/x11/clutter-stage-x11.c: Port the X11 stage
implementation to the new size negotiation API.
* tests/Makefile.am: Add the layout manager test case.
* tests/test-opacity.c: Update.
* tests/test-project.c: Update.
* tests/test-layout.c: Test case for a layout manager implemented
using the new size negotiation API; the layout manager handles
both transformed and untransformed children.
* clutter/clutter-rectangle.c:
(clutter_rectangle_paint): Remove commented out call to
cogl_enable(); the call is not needed and the comment is
in C99.
race when both are set from clutter script also makes it more
consistent with the behavior of other actors.)
* clutter/clutter-rectangle.c: (clutter_rectangle_set_color): stop
setting the opacity of the actor from the specified color.
(clutter_rectangle_paint): combine the absolute opacity of the actor
with the alpha of the color when painting.
primitives and path API a bit smaller and more resembling cairo.
* clutter/cogl/gl/cogl-primitives.c:
* clutter/cogl/gles/cogl-primitives.c:
* clutter/cogl/gles/cogl.c:
* clutter/clutter-actor.c:
* clutter/clutter-rectangle.c:
* tests/test-cogl-offscreen.c:
* tests/test-cogl-primitives.c:
* tests/test-cogl-tex-convert.c:
* tests/test-cogl-tex-foreign.c:
* tests/test-cogl-tex-getset.c:
* tests/test-cogl-tex-tile.c: updated according to changes in cogl.
* clutter/clutter-actor.h:
* clutter/clutter-actor.c:
(clutter_actor_get_abs_opacity): Add function that does what
get_opacity() does now...
(clutter_actor_get_opacity): ... and make get_opacity() do what
it's supposed to be doing. The original get_opacity() returned
a composited value, and there's no way to actually extract the
real opacity value set with set_opacity().
* clutter/clutter-clone-texture.c:
* clutter/clutter-rectangle.c:
* clutter/clutter-texture.c: Update to use get_abs_opacity().
* clutter/clutter-entry.c:
* clutter/clutter-label.c: Ditto. Also, never change the stored
alpha value. (#804)
* tests/Makefile.am:
* tests/test-opacity.c: Test suite for the get_opacity() and
get_abs_opacity() API, and correct opacity handling.
* README: Add note about the change in get_opacity().
Apply a patch from Neil Roberts (bug 488) for fixing the drawing of the
rectangle border, by not overdrawing the rectangle on the border and by
doing the correct check on the border colour.
* clutter/clutter-rectangle.c:
Comment out color match check for now as appears to be causing
borders to always get pained.
* clutter/clutter-texture.h:
Add some format defines (unused as yet)
* clutter/cogl/gles/cogl.c:
* clutter/egl/clutter-stage-egl.c:
* configure.ac:
Various OpenGL ES backend related fixes and tweaks.
* clutter/Makefile.am:
* clutter/clutter-actor.c:
* clutter/clutter-clone-texture.c:
* clutter/clutter-rectangle.c:
* clutter/clutter-stage.c:
* clutter/clutter-texture.c:
* clutter/cogl/cogl.h:
* clutter/cogl/gl/Makefile.am:
* clutter/cogl/gl/cogl-defines.h:
* clutter/cogl/gl/cogl.c:
* clutter/cogl/gles/Makefile.am:
* clutter/cogl/gles/cogl-defines.h:
* clutter/cogl/gles/cogl.c:
* clutter/glx/Makefile.am:
* clutter/glx/clutter-stage-glx.c:
* clutter/pango/Makefile.am:
* clutter/pango/pangoclutter-render.c:
* configure.ac:
Add initial 'cogl' implementation. 'cogl' is a simple abstration
layer over GL and GL/ES used by clutter internally. It should
eventually allow clutter applications to be run on both GL and GL/ES
with just a recompile as well as provide more debugging and potentially
profiling information for GL and GL/ES usage.
This commit contains the initial GL implementation.
* clutter/clutter-color.h:
* clutter/clutter-color.c: Expose clutter_color_copy()
and clutter_color_free() for the python bindings, so that
they can manager the conversion automatically; use the
slice allocator when copying/freeing a ClutterColor.
* clutter/clutter-private.h: Add our own READABLE,
WRITABLE and READWRITE paramspec flags, declaring the
string components of the properties GParamSpec as static;
this should shave off some bytes in the memory footprint
and avoid relocations.
* clutter/clutter-actor.c:
* clutter/clutter-behaviour.c:
* clutter/clutter-behaviour-opacity.c:
* clutter/clutter-behaviour-path.c:
* clutter/clutter-behavuour-scale.c:
* clutter/clutter-clone-texture.c:
* clutter/clutter-label.c:
* clutter/clutter-rectangle.c:
* clutter/clutter-stage.c:
* clutter/clutter-texture.c:
* clutter/clutter-timeline.c: Use the CLUTTER_PARAM_*
macros we just added.
* clutter/clutter-behaviour-scale.c: Add properties for
the scale begin, scale end and gravity parameters.
* clutter/clutter-behaviour-path.h: Mark the ClutterKnot
memory management functions as public (for the bindings),
since we use the slice allocator for copying knots around;
add a clutter_knot_equal() function.
* clutter/clutter-behaviour-path.c:
(node_distance): Use clutter_knot_equal() as a fast path
to avoid the sqrt() in case the nodes we are using are
at the same position.
(path_total_length): Additional check on the existence
of the next node.
* examples/behave.c: Do not leak the ClutterBehaviour
objects around.
* clutter/clutter-rectangle.h:
* clutter/clutter-rectangle.c: Add border to the ClutterRectangle
actor; add "border-width", "border-color" and "has-border"
properties, plus their accessors. The border generation code is
pretty lame, at the moment.
* examples/behave.c: Add code to test the new rectangle properties.
* clutter/clutter-actor.c: (clutter_actor_paint):
* clutter/clutter-clone-texture.c: (clutter_clone_texture_paint):
* clutter/clutter-group.c: (clutter_group_paint):
* clutter/clutter-rectangle.c: (clutter_rectangle_paint):
* clutter/clutter-texture.c: (clutter_texture_paint):
Fix for #156.
clutter_actor_paint() now translates to actor position as
to not fix scaled groups positioning. Sub classes now paint
at 0,0.
* clutter-color.h:
* clutter-color.c: Reimplement ClutterColor as a boxed type;
add convenience API for color handling, like: add, subtract,
shade, HSL color-space conversion, packing and unpacking.
* clutter-private.h: Update ClutterMainContext, and export the
main context pointer here.
* clutter-rectangle.h:
* clutter-rectangle.c: Update the color-related code; make
clutter_rectangle_new() and empty constructor and provide
clutter_rectangle_new_with_color(); provide color setter
and getter API.
* clutter-label.h:
* clutter-label.c: Rename the "font" property to "font-name";
update the color-related code to the new ClutterColor object;
rename clutter_label_new() to clutter_label_new_with_text(),
and add setters and getters for the properties.
* clutter-marshal.list: Add VOID:OBJECT and VOID:BOXED marshallers
generators.
* clutter-stage.h:
* clutter-stage.c: Rework the API: provide a default constructor
for a singleton object, named clutter_stage_get_default(), which
supercedes the clutter_stage() function in clutter-main; provide
new events: button-press-event, button-release-event,
key-press-event and key-release-event; update the color-related
code;
(clutter_stage_snapshot): Allow negative width and height when
taking a snapshot (meaning: use full width/height).
(clutter_stage_get_element_at_pos): Rename clutter_stage_pick().
* clutter-element.c (clutter_element_paint): Clean up the
stage and color related code.
* clutter-event.h:
* clutter-event.c: Add generic ClutterAnyEvent type; add
clutter_event_new(), clutter_event_copy() and clutter_event_free();
make ClutterEvent a boxed type.
* clutter-main.h:
* clutter-main.c: Remove clutter_stage(); add clutter_main_quit(),
for cleanly quitting from clutter_main(); add multiple mainloops
support; allocate the ClutterCntx instead of adding it to the
stack; re-work the ClutterEvent dispatching.
* clutter-group.c (clutter_group_add), (clutter_group_remove): Keep
a reference on the element when added to a ClutterGroup.
* examples/rects.py
* examples/test.c:
* examples/test-text.c:
* examples/video-cube.c:
* examples/super-oh.c:
* examples/test-video.c: Update.