• 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: Refresh woes for custom OGL pane
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Refresh woes for custom OGL pane


  • Subject: Re: Refresh woes for custom OGL pane
  • From: Brent Gulanowski <email@hidden>
  • Date: Tue, 30 Apr 2002 10:00:11 -0400

On Tuesday, April 30, 2002, at 01:04 AM, Erik M. Buck wrote:

I'm basically calling [self drawRect] everytime the view changes via
user input, etc... This works WAY better. Two problems though (so
far :)

NEVER CALL -drawRect:! Call -display or -displayRect: or -setNeedsDisplay:
or -setNeedsDisplayInRect:. Your failure to call one of these methods may
explain all of your problems.

Erik, did you have a bad experience with a -drawRect: call or something? Flashbacks? Insomnia? Memory loss? I'm sure we can find you some help for that ;-)

I think his actual problem, aside from breaking protocol, was that he was trying to call his draw routine initially before a context had been created. A call to [self openGLContext] in initWithFrame: fixes that.

So what BAD THINGS HAPPEN when you call -drawRect: directly?

brent
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

  • Follow-Ups:
    • Re: Refresh woes for custom OGL pane
      • From: Cryx <email@hidden>
    • Re: Refresh woes for custom OGL pane
      • From: "Erik M. Buck" <email@hidden>
References: 
 >Re: Refresh woes for custom OGL pane (From: "Erik M. Buck" <email@hidden>)

  • Prev by Date: Using NSImage in command line tool
  • Next by Date: Re: Can't import a header file? + other warnings
  • Previous by thread: Re: Refresh woes for custom OGL pane
  • Next by thread: Re: Refresh woes for custom OGL pane
  • Index(es):
    • Date
    • Thread