Account Options

  1. Sign in
The old Google Groups will be going away soon.
Switch to the new Google Groups.
Google Groups Home
« Groups Home
ccTouchesBegan to heavy?
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  5 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
webmaster@deathtodesign.c om  
View profile  
 More options Dec 23 2008, 4:30 pm
From: "webmas...@deathtodesign.com" <webmas...@deathtodesign.com>
Date: Tue, 23 Dec 2008 13:30:37 -0800 (PST)
Local: Tues, Dec 23 2008 4:30 pm
Subject: ccTouchesBegan to heavy?
I am almost certain this is the cause of some new issues im having
with my app..
it seems that this new proxy might be too resource heavy, but i might
be wrong..
it seems now when i do rapid succession of touches the touch events
start to not register after about 5 or so. then about 1-2 seconds
later they start working again..

the weird thing is i notice this when testing on ipod touch, iphone 2g
and iphone 3g but not the new touch.. so possibly the new touch's
speed is better suited for whatever is going on behind the scenes. So
my question is how thoroughly is this new touch proxy implemented  so
maybe i could make a few changes to test without it to be 100%
certain.


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
riq  
View profile  
 More options Dec 23 2008, 4:48 pm
From: riq <ricardoques...@gmail.com>
Date: Tue, 23 Dec 2008 19:48:26 -0200
Local: Tues, Dec 23 2008 4:48 pm
Subject: Re: [cocos2d-iphone] ccTouchesBegan to heavy?
On Tue, Dec 23, 2008 at 7:30 PM, webmas...@deathtodesign.com

<webmas...@deathtodesign.com> wrote:

> I am almost certain this is the cause of some new issues im having
> with my app..
> it seems that this new proxy might be too resource heavy, but i might
> be wrong..
> it seems now when i do rapid succession of touches the touch events
> start to not register after about 5 or so. then about 1-2 seconds
> later they start working again..

mmm.... the new  touch has an additional copy.

{
        if( eventsEnabled )  {
                NSArray *copyArray = [eventHandlers copy];
                NSEnumerator *enumerator = [copyArray reverseObjectEnumerator];  //
XXX this might be the problem
                for( id eventHandler in enumerator ) {
                        if( [eventHandler
respondsToSelector:@selector(ccTouchesCancelled:withEvent:)] ) {
                                if( [eventHandler ccTouchesCancelled:touches withEvent:event] ==
kEventHandled )
                                        break;
                        }
                }
                [copyArray release];
        }

}

try replacing with these 2 lines:
                NSEnumerator *enumerator = [copyArray reverseObjectEnumerator];  //
XXX this might be the problem
                for( id eventHandler in enumerator ) {
with this ones:
                for( id eventHandler in copyArray ) {

If this works fast then it is a problem with v0.6.
The fix is to add the handlers at the beginning and not at the end.

riq.

--
http://blog.sapusmedia.com
http://monodiario.blogspot.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
webmaster@deathtodesign.c om  
View profile  
 More options Dec 23 2008, 5:07 pm
From: "webmas...@deathtodesign.com" <webmas...@deathtodesign.com>
Date: Tue, 23 Dec 2008 14:07:08 -0800 (PST)
Local: Tues, Dec 23 2008 5:07 pm
Subject: Re: ccTouchesBegan to heavy?
its hard to tell if it helped. i totally replaced the touch events
with the old (5.1) touch methods and it seemed to help slightly. it
seems to recover from a choke a tad faster.. but it still chokes... i
cant figure out if this is an issue with something apple related or
not.. its just so odd that i can go crazy tapping on the 2g and it
doesnt miss 1 event. but the phones/ipod touch(old) hiccup pretty
quickly.

i read somewhere about touch events not getting priority on glviews..
i dont really know if that is true..

On Dec 23, 1:48 pm, riq <ricardoques...@gmail.com> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
riq  
View profile  
 More options Dec 23 2008, 5:16 pm
From: riq <ricardoques...@gmail.com>
Date: Tue, 23 Dec 2008 20:16:46 -0200
Local: Tues, Dec 23 2008 5:16 pm
Subject: Re: [cocos2d-iphone] Re: ccTouchesBegan to heavy?

> its hard to tell if it helped. i totally replaced the touch events
> with the old (5.1) touch methods and it seemed to help slightly. it
> seems to recover from a choke a tad faster.. but it still chokes... i
> cant figure out if this is an issue with something apple related or
> not.. its just so odd that i can go crazy tapping on the 2g and it
> doesnt miss 1 event. but the phones/ipod touch(old) hiccup pretty
> quickly.

another thing that you can try is to remove the other [copy]
([eventHandlers copy]).
But you won't be able to add/remove CocosNode within a touch event.

I've just commited the change that does the touch event with only one
copy, like in v0.5.x
r393.

riq.

--
http://blog.sapusmedia.com
http://monodiario.blogspot.com


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
webmaster@deathtodesign.c om  
View profile  
 More options Dec 23 2008, 5:19 pm
From: "webmas...@deathtodesign.com" <webmas...@deathtodesign.com>
Date: Tue, 23 Dec 2008 14:19:10 -0800 (PST)
Local: Tues, Dec 23 2008 5:19 pm
Subject: Re: ccTouchesBegan to heavy?
this helped out significantly!
https://devforums.apple.com/message/15029#15029

i just stuck that in the beginning of my main step function.. not sure
if thats the proper place but it has made a dramatic improvment.

On Dec 23, 2:07 pm, "webmas...@deathtodesign.com"


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »