Skip to content

Commit c04c592

Browse files
committed
Don’t check for GL errors when there is no context set.
1 parent 3ded029 commit c04c592

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

cocos2d/Platforms/iOS/CCGLView.m

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,10 @@ CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
8383
#import "CCDirector_Private.h"
8484
#import "CCRenderDispatch.h"
8585

86+
87+
extern EAGLContext *CCRenderDispatchSetupGL(EAGLRenderingAPI api, EAGLSharegroup *sharegroup);
88+
89+
8690
//CLASS IMPLEMENTATIONS:
8791

8892

@@ -226,8 +230,6 @@ - (id) initWithFrame:(CGRect)frame pixelFormat:(NSString*)format depthFormat:(GL
226230
*/
227231
self.multipleTouchEnabled = YES;
228232

229-
CC_CHECK_GL_ERROR_DEBUG();
230-
231233
_touchEvent = [[CCTouchEvent alloc] init];
232234
}
233235

@@ -248,8 +250,6 @@ -(id) initWithCoder:(NSCoder *)aDecoder
248250
if( ! [self setupSurfaceWithSharegroup:nil] ) {
249251
return nil;
250252
}
251-
252-
CC_CHECK_GL_ERROR_DEBUG();
253253
}
254254

255255
return self;
@@ -295,8 +295,6 @@ -(BOOL) setupSurfaceWithSharegroup:(EAGLSharegroup*)sharegroup
295295

296296
_discardFramebufferSupported = [[CCConfiguration sharedConfiguration] supportsDiscardFramebuffer];
297297

298-
CC_CHECK_GL_ERROR_DEBUG();
299-
300298
return YES;
301299
}
302300

0 commit comments

Comments
 (0)