• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
do i need to create autorelease pool?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

do i need to create autorelease pool?


  • Subject: do i need to create autorelease pool?
  • From: Memo Akten <email@hidden>
  • Date: Wed, 25 Feb 2009 03:28:59 +0000

I know what autorelease pools are and how they work so my question isn't about that.

In my iPhone app I create a NSTimer to run at 60fps, in it I update a bunch of stuff and draw opengl.

Currently I have:
-(void) timerLoop {
	// create autorelease pool in case anything needs it
	NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
	<do all update stuff here and render>
	// release pool
	[pool release];
}

Do I need this autorelease pool here or does UIApplicationMain manage that for every call of timerLoop?
_______________________________________________


Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Follow-Ups:
    • Re: do i need to create autorelease pool?
      • From: Peter N Lewis <email@hidden>
  • Prev by Date: Re: Help with sheets, NSArrayController & NSTableView (all working together) ...
  • Next by Date: Re: Alternative to NSWorkspace iconForFileType for icons?
  • Previous by thread: Re: NSDate And Super Class
  • Next by thread: Re: do i need to create autorelease pool?
  • Index(es):
    • Date
    • Thread