Not receiving gesture end/begin events

Asked by Amit Nayar

Hi,

Could anyone help me with this gesture events problem I'm having with Geis V2.

I don't seem to be receiving gesture end events (or "touch up") for a 1 finger touch gesture but I do receive a gesture begin (only if there is no fingers currently touching the screen). I also do not receive gesture begin on 2 or more finger gestures.

I may be misunderstanding how the events are created...
I am expecting that when a finger (or more than 1 finger) is placed down, the GEIS_EVENT_GESTURE_BEGIN gets added, followed by updates until all fingers are lifted from the screen where a GEIS_EVENT_GESTURE_END is added? I seem to only be receiving UPDATE events. I'm trying to bear in mind as well that I need to allow more than 1 gesture to occur at the same time which is making things a bit complicated.

My subscription/filter set up is:

m_geisSubscription = geis_subscription_new(m_geisObject, "subscription", GEIS_SUBSCRIPTION_CONT);

GeisFilter filter1 = geis_filter_new(m_geisObject, "filter1");
status = geis_filter_add_term(
    filter1,
    GEIS_FILTER_CLASS,
    GEIS_CLASS_ATTRIBUTE_NAME, GEIS_FILTER_OP_EQ, GEIS_GESTURE_TAP, // Don't seem to receive any tap gestures.
    GEIS_CLASS_ATTRIBUTE_NAME, GEIS_FILTER_OP_EQ, GEIS_GESTURE_DRAG,
    GEIS_CLASS_ATTRIBUTE_NAME, GEIS_FILTER_OP_EQ, GEIS_GESTURE_TOUCH,
    GEIS_GESTURE_ATTRIBUTE_TOUCHES, GEIS_FILTER_OP_EQ, 1,
    NULL);

geis_subscription_add_filter(m_geisSubscription, filter1);

GeisFilter filter2 = geis_filter_new(m_geisObject, "filter2");
status = geis_filter_add_term(
    filter2,
    GEIS_FILTER_CLASS,
    GEIS_CLASS_ATTRIBUTE_NAME, GEIS_FILTER_OP_EQ, GEIS_GESTURE_ROTATE,
    GEIS_GESTURE_ATTRIBUTE_TOUCHES, GEIS_FILTER_OP_EQ, 2,
    NULL);

geis_subscription_add_filter(m_geisSubscription, filter2);

Another issue I'm having is that I am not receiving an event for a 2 finger gesture if the fingers are placed one after the other over a period of time. So if I want to allow a 1 finger touch to morph into a 2 finger rotate (for example), how would I do this?

Thanks in advance!
(and sorry for all the Qs)

Question information

Language:
English Edit question
Status:
Solved
For:
Geis Edit question
Assignee:
No assignee Edit question
Solved by:
Amit Nayar
Solved:
Last query:
Last reply:
Revision history for this message
Amit Nayar (amit-nyr) said :
#1

OK, so I've found that the example way of processing geis events using geis_next_event (i.e popping the event stack manually) doesn't give you all the events - in particular the gesture end gets missed.
Alternatively, using the event callback system ( geis_register_event_callback ), you get all the events.