• 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
Problem drawing offscreen with NSOpenGLView (gets drawn onscreen too)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Problem drawing offscreen with NSOpenGLView (gets drawn onscreen too)


  • Subject: Problem drawing offscreen with NSOpenGLView (gets drawn onscreen too)
  • From: "E. Wing" <email@hidden>
  • Date: Thu, 11 Jan 2007 19:16:02 -0800

I am using a custom subclass of NSOpenGLView. In my drawRect: routine,
I have an if-else block like the following:

if([[NSGraphicsContext currentContext] isDrawingToScreen])
{
// Draw onscreen stuff
}
else
{
// Draw special printer representation
}

In my offscreen representation, I want to modify the presentation
slightly to make more sense for a printer. When I test this code by
selecting print and (select Preview from the Print panel), I notice
that my printer representation also gets rendered on-screen in my app.
Then when Preview finishes loading, my app goes back to normal and
renders the normal represenation again. I don't want this to happen.
How can I prevent this? (Is this supposed to even happen?)

Thanks,
Eric
_______________________________________________

Cocoa-dev mailing list (email@hidden)

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


  • Prev by Date: Re: int and short int on intel
  • Next by Date: Re: NOT solved: using long double math functions like sinl() with Cocoa
  • Previous by thread: Re: int and short int on intel
  • Next by thread: Re: NOT solved: using long double math functions like sinl() with Cocoa
  • Index(es):
    • Date
    • Thread