Nesting GLKView into UIViewController

后端 未结 1 713
旧巷少年郎
旧巷少年郎 2021-02-09 06:17

I\'m trying to use GLKView in UIViewController, my code looks like this

CustomViewController.h

#import 
#import 

        
相关标签:
1条回答
  • 2021-02-09 06:41

    Initialize OpenGL in your viewDidLoad, just as you're currently doing.

    Take a look at registering your view controller as the GLKView's delegate. The delegate's glkView:(GLKView *)view drawInRect: method will be invoked whenever a redraw is required.

    This tutorial may help.

    0 讨论(0)
提交回复
热议问题