[clutter] [pyclutter] animations never call destructor
I'm playing around with pyclutter and have noticed that an animation is never destroyed and holds a reference to the actor indefinitely. Because of this, every actor I use implicit animations with can never be garbage collected. From my limited understanding of python bindings it appears as though the destructor is never called. Is there a way around this? BR, K -- To unsubscribe send a mail to clutter+unsubscr...@o-hand.com
[clutter] pyclutter chaining animations problems
Hi all, I'm trying to chain together a couple of animations using ClutterActor.animate in python, however if I use the completed signal from the animation to start off a second animation the second animation jumps to the end rather than playing through. Attached is a simple example of the problem I'm having, if you click anywhere on the stage two animations should occur one following the others completed, however the second animation appears to end at the first frame. BR, K import clutter import cairo import math class TestActor(clutter.CairoTexture): def __init__( self ): clutter.CairoTexture.__init__(self, 50, 50) cr = self.cairo_create() cr.arc(25, 25, 24, 0.0, 2*math.pi) cr.set_source_rgba(1,0,1,0.5) cr.fill() def start_move( self, blah, blab ): anim = self.animate(clutter.LINEAR, 800, x, 200) anim.connect(completed, self.chain) def chain( self, anim ): self.animate(clutter.LINEAR, 800, x, 0) if __name__ == '__main__': bg_color = clutter.Color(0xe0, 0xf2, 0xfc, 0xff) stage = clutter.Stage() stage.set_size(300, 300) stage.set_color(bg_color) stage.connect('destroy', clutter.main_quit) actor = TestActor() stage.add(actor) stage.connect('button-press-event', actor.start_move) stage.show_all() clutter.main()
[clutter] PyClutter Segfault with cairo textures
When running the example cairo-texture.py for pyclutter I'm getting a segfault. I'm currently using a fresh git clone. As it's not so easy to always debug python I haven't managed to ascertain very much about the crash. Here's what I did manage to get. Program received signal SIGSEGV, Segmentation fault. 0x714e65e2 in _wrap_clutter_cairo_texture_create (self=value optimized out) at clutter-cairotexture.override:129 129 return PycairoContext_FromContext (ret, PyClutterCairoContext_Type, NULL); (gdb) bt #0 0x714e65e2 in _wrap_clutter_cairo_texture_create (self=value optimized out) at clutter-cairotexture.override:129 #1 0x0020 in ?? () #2 0x003a7d505c98 in PyThread_get_thread_ident () at Python/thread_pthread.h:220 #3 0x00694cd8 in ?? () #4 0x0060a4c0 in ?? () #5 0x0096ddc0 in ?? () #6 0x0001 in ?? () #7 0x008d5a28 in ?? () #8 0x77ef2210 in ?? () #9 0x00694cd8 in ?? () #10 0x006951a4 in ?? () #11 0x in ?? () Anyone seen this kind of thing before, hardware is nvidia 8xxx series BR, K -- To unsubscribe send a mail to clutter+unsubscr...@o-hand.com
[clutter] transforming a x,y point to a relative x,y point at a depth
Hi all, I'm trying to figure out a way of taking an x,y co-ordinate from the mouse and calculating where that x,y co-ordinate is relative to a specific depth. So at a given depth I can know an exact position relative to actors at that depth, also calculating the other way would be good too. I believe this will require some probable use of cogl_matrix_* but am unsure how to proceed into this. BR, K -- To unsubscribe send a mail to clutter+unsubscr...@o-hand.com
Re: [clutter] questions regarding captured event
Anyone want to acknowledge and reply? BR, K On Thu, 2009-08-13 at 09:38 +0100, Karl Lattimer wrote: Hi all, I'm having some trouble with captured-event, from the documentation gboolean user_function (ClutterActor *actor, ClutterEvent *event, gpointer user_data) : Run Last actor : the actor which received the signal Now I've taken this to mean that 'actor' is the actor which originally received the event, for instance, a button inside of a container. However it appears to be the actor the event has been captured by. This leaves no way to determine what has received the event within the captured event call back. Is this the correct behaviour, or am I correct in assuming that I should be receiving the actor for which the event would have been received by if it weren't for capturing it. BR, K -- To unsubscribe send a mail to clutter+unsubscr...@o-hand.com
Re: [clutter] questions regarding captured event
On Fri, 2009-08-14 at 10:26 +0100, Emmanuele Bassi wrote: On Thu, 2009-08-13 at 09:38 +0100, Karl Lattimer wrote: Hi all, I'm having some trouble with captured-event, from the documentation gboolean user_function (ClutterActor *actor, ClutterEvent *event, gpointer user_data) : Run Last actor : the actor which received the signal this should be the actor that emitted the signal; copy and paste on docs should be disabled by default. :-/ Heh, it's always the way :) Now I've taken this to mean that 'actor' is the actor which originally received the event, for instance, a button inside of a container. However it appears to be the actor the event has been captured by. yes, for obvious reasons we cannot emit signals on actors that did not receive the event. Ah, I was thinking there was some jiggery pokery going on so you knew where the event would have been emitted. This of course makes obvious sense now :) This leaves no way to determine what has received the event within the captured event call back. clutter_event_get_source(). Great, I missed that, thanks :) Although just to clarify, this will return where the event would have ended up right? Like a button in a container say, where I've captured the event on the container instead of letting it drop through to the button. /me goes away to play with it anyway Is this the correct behaviour, or am I correct in assuming that I should be receiving the actor for which the event would have been received by if it weren't for capturing it. the ::captured-event signal works exactly like the ::event signal, which has the same semantics used by gtk+, only it works from the top-most container to the actor. the event is propagated, in case of the ::event signal, from the reactive actor that received the event from the windowing system (as determined by the pick) to its parents until it reaches the stage; the ::captured-event signal is emitted before the ::event signal and is emitted on the stage that contains the actor and down through the actor's parents until it reaches the actor itself. Thanks again for clearing this up. BR, K -- To unsubscribe send a mail to clutter+unsubscr...@o-hand.com
[clutter] questions regarding captured event
Hi all, I'm having some trouble with captured-event, from the documentation gboolean user_function (ClutterActor *actor, ClutterEvent *event, gpointer user_data) : Run Last actor : the actor which received the signal Now I've taken this to mean that 'actor' is the actor which originally received the event, for instance, a button inside of a container. However it appears to be the actor the event has been captured by. This leaves no way to determine what has received the event within the captured event call back. Is this the correct behaviour, or am I correct in assuming that I should be receiving the actor for which the event would have been received by if it weren't for capturing it. BR, K -- To unsubscribe send a mail to clutter+unsubscr...@o-hand.com
Re: [clutter] Guide for updating from 0.8
On Mon, 2009-08-10 at 16:46 +0100, Emmanuele Bassi wrote: On Mon, 2009-08-10 at 16:42 +0100, Karl Lattimer wrote: Is there a guide available anywhere to assist in updating code from clutter-0.8 to clutter-1.0? I've been looking at the rest of the changes, and was planning to add a units-floats guide as well. This is the bit I'm having a few issues with as it goes :/ ClutterUnit to ClutterUnits seems a little more complicated than I first thought although looking through the docs it probably isn't too difficult. obviously, if somebody comes up with other topics, then feel free to mention them on the mailing list or open a bug; patches, as always, are welcome. ClutterFixed throws out a few errors but they're pretty self explanatory maybe a few simple notes to help could be useful. BR, K -- To unsubscribe send a mail to clutter+unsubscr...@o-hand.com
[clutter] clutter cairo patch
Hi all, Had some trouble building the latest git of clutter-cairo, attached is a patch to remove the old clutter_clone_texture_new and replace it with clutter_clone_new in the bubbles example. BR, K diff --git a/examples/bubbles.c b/examples/bubbles.c index e6adcd6..34c711f 100644 --- a/examples/bubbles.c +++ b/examples/bubbles.c @@ -142,7 +142,7 @@ main (int argc, char **argv) { ClutterActor *actor; - actor = clutter_clone_texture_new (CLUTTER_TEXTURE (bubble)); + actor = clutter_clone_new (bubble); clutter_actor_set_position (actor, i * BUBBLE_R*2, -BUBBLE_R*2); clutter_container_add_actor (CLUTTER_CONTAINER (stage), actor); signature.asc Description: This is a digitally signed message part