• 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
Re: EXC_BAD_ACCESS when calling CGContextDrawLayerInRect
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: EXC_BAD_ACCESS when calling CGContextDrawLayerInRect


  • Subject: Re: EXC_BAD_ACCESS when calling CGContextDrawLayerInRect
  • From: Nathan Vander Wilt <email@hidden>
  • Date: Mon, 14 Apr 2008 09:02:28 -0700

On Apr 13, 2008, at 7:15 AM, Carter R. Harrison wrote:
CGContextRef context = [[NSGraphicsContext currentContext] graphicsPort];
CGContextDrawLayerInRect(context, CGRectMake([self frame].origin.x, [self frame].origin.y, [self frame].size.width, [self frame].size.height), cgback);


cgback is a instance variable pointing to a CGLayer.

So my code works, the correct things are being drawn to my view (more or less), but what happens is that after several seconds of use, the app crashes and I get an EXC_BAD_ACCESS error.


Can you post more information regarding your cgback variable? How is it being allocated? That parameter seems to be the most likely culprit.

-nvw
_______________________________________________

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: EXC_BAD_ACCESS when calling CGContextDrawLayerInRect
      • From: "Carter R. Harrison" <email@hidden>
References: 
 >EXC_BAD_ACCESS when calling CGContextDrawLayerInRect (From: "Carter R. Harrison" <email@hidden>)

  • Prev by Date: Re: Using Properties at Outlets
  • Next by Date: Re: warning: Image scaling is not supported on Mac OS X versions prior to 10.5.
  • Previous by thread: Re: EXC_BAD_ACCESS when calling CGContextDrawLayerInRect
  • Next by thread: Re: EXC_BAD_ACCESS when calling CGContextDrawLayerInRect
  • Index(es):
    • Date
    • Thread