Volodymyr Dudchak
Volodymyr Dudchak

Reputation: 55

How to get know that CGContext is drawing to screen

I want to get know that current CGContext is used for image, PDF or for screen drawing. In Cocoa I just use [[NSGraphicsContext currentContext] isDrawingToScreen] ([NSGraphicsContext currentContextDrawingToScreen] on 10.10). How can I get the same information from CGContext?

Upvotes: 2

Views: 496

Answers (1)

Nikolai Ruhe
Nikolai Ruhe

Reputation: 81878

Contrary to desktop, on iOS there's no direct drawing to screen as all views are layer backed. So your question probably is: How can I tell if the current context is used to fill the contents of a layer?

I'm not aware of a public API that answers this.

Upvotes: 2

Related Questions