|
| [Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] |
On 25/03/2009, at 3:45 AM, email@hidden wrote:
Yes, although I see that implementing the initWithFrame:pixelFormat: isn't so much the point, as the fact that the method has to be called during the initWithFrame: method, after you have obtained a pixel format.
The sample code uses the CustomOpenGLView as an abstract class, which I have not done. Neat for re-usability, but I didn't take this approach, and I thought it would be a bit strange to have two init methods in one class. So as in my original post, since the duties normally performed by initWithFrame:pixelFormat: can be handled in the initWithFrame: method, I assume that the inclusion of the initWithFrame:pixelFormat is a convention?
Thank you for that link. I hadn't seen it before. A few reasons for using the Custom view approach are also mentioned in the guide. For myself, I just wanted to try this approach so that the process of setting up the OpenGL view could be plainly seen. As for the guide, I would assume references to sample code are somewhat optional. Understanding the whole thing better now, I can see that all the information is in the guide. IMO, it could be clearer though, in particular: You need to override the
seems a bit confusing to me. Thanks for pointing me in the right direction there. As always, it turned out to be not so mysterious after all. Ian. |
_______________________________________________ Do not post admin requests to the list. They will be ignored. Mac-opengl mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
| References: | |
| >Re: OpenGL Prog Guide for OSX - override initWithFrame (From: email@hidden) |
| Home | Archives | Terms/Conditions | Contact | RSS | Lists | About |
Visit the Apple Store online or at retail locations.
1-800-MY-APPLE
Contact Apple | Terms of Use | Privacy Policy
Copyright © 2011 Apple Inc. All rights reserved.