GPUImage
GPUImage copied to clipboard
GPUImageView EXC_BAD_ACCESS
Hi. I'm getting an EXC_BAD_ACCESS (EXC_ARM_DA_ALIGN) on GPUImageView:167, when renderbufferStorage is called (EAGLContext_renderbufferStorage).
It's happening in examples too (SimpleVideoFilter).
I'm running in an iPhone 5 with iOS 8.
Any ideas?
Facing same issue on startup of app. Feels like it only started happening after switching running device to iOS8.3 (and dev machine to Xcode 6.3.2). Before I used 8.0.2 and it worked fine..
I have participated from Apple WWDC and I get this EXC_BAD_ACCESS happened on XCode 6.3.2 and XCode 7 deploing the app in iOS 8.3 and iOS 9.
What is hapening is that all Apps compiled in Release version Crashes. If you compile with Debug version you can't debug your App but the App can Run.
I have talked with the apple Engineers in the WWDC Labs and the only thing that we could figure out is if you go to Product -> Scheme -> Edit Scheme ... And for the Run Debug configuration (on left side) choose "Options" (on right side) and configure "GPU Frame Capture" as Disabled.
This is the only way to stop having this EXC_BAD_ACCESS, but this is not a solution because application still crashes if you run Release version, you still cant debug and can't make use of the Instruments too. I have tested with the Sample Code provided with the library and same error occurs.
I think that this issue is something related with race condition of some threads, but I am trying to fix it, but nothing until now.
So it appears that every app that uses GPUImage will crash when iOS 9 was released.
I'm also having this issue using plain GLKit with OpenGLES in 8.3.
I'm also faced with this issue. XCode 6.3.1, iOS 8.3
Facing the same issue on iOS 8.3
I'm also having the issue with simple video preview sample. Xcode 6.3.2, iOS 8.3
Yup same issue here on 8.3 on ipad. Ios 9 beta 2 on iphone 6 plus is fine though.
limagustavo, you have made my day, thank you very much.
So the current version of GPUImage
is going to be not compatible with iOS 8.4? Will compiling the app with version 0.1.6
going to cause problems with this issue?
So I just had a chance to look into this, and with Xcode 6.4 and iOS 8.4 on an iPhone 6 I can't reproduce this. It's possible this was a bug in iOS 8.3 and the first beta of iOS 9, since people are reporting that the latest beta of iOS 9 doesn't exhibit this behavior. I've tested my example applications against both debug and release builds, with and without GPU frame capture enabled.
There wasn't anything special about what I was doing with that line of code. It's standard OpenGL ES rendering code for associating rendered content with a CAEAGLLayer. I've used code like that since iPhone OS 2.0 without issue.
Does anyone still see this with Xcode 6.4 and iOS 8.4 or the latest iOS 9.0 beta? If so, do any of the sample applications that ship with the framework exhibit this behavior? If I have a reproducible test case, I can look into it further.
@BradLarson I am still able to reproduce it on iOS 8.4, iPhone 5s, Xcode4. Yes it really is a standard OpenGL ES rendering code, nothing special about it. Yet turning off GPU Frame Capture helps avoiding it. I will try to make a test app asap, yet you need iPhone 5s to reproduce. Still it seems to me, that it is not your fault, Apple might fix it in Xcode 8.4.1 or something
I had this issue with iOS 8.3. After I upgraded test device operating system to iOS 8.4, it has not been exhibiting anymore (iPad 3rd generation, xCode 6.4).
I can verify I just ran in to this on iOS 8.3 and Xcode Version 6.4 (6E35b). Updating to 8.4 appeared to clear it for me. I also wonder if opening the project in the Xcode 7 Beta might have left some cruft in the project, but that's pure speculation.
@BradLarson It works well on Xcode 6.4 and iOS 8.4. Thank you.
killing DerivedData/ and recompiling project using xcode 6.2 did not resolve the issue for me. I have to kill GPU image usage on devices prior to 8.4 CGFloat iOSVersion = [[[UIDevice currentDevice] systemVersion] floatValue]; if(iOSVersion<8.4) { // gpuimage no longer works on ios prior to 8.4 in xcode 6.4 [self processCorners:1 forImage:uiImage]; }else { GPUImagePicture stillImageSource = [[GPUImagePicture alloc] initWithImage:uiImage]; GPUImageHarrisCornerDetectionFilter *harrisFilter = [GPUImageShiTomasiFeatureDetectionFilter new]; harrisFilter.cornersDetectedBlock = ^(GLfloat cornerArray, NSUInteger cornersDetected, CMTime frameTime) { [self processCorners:cornersDetected forImage:uiImage]; }; [stillImageSource addTarget:harrisFilter]; [harrisFilter useNextFrameForImageCapture]; [stillImageSource processImage]; } :-[[[[
@sndive - I think this is only localized to 8.3. 8.2 and below worked just fine in all of my testing. Are you seeing issues deploying from Xcode 6.4 to iOS versions below 8.3?
Disable GPU Frame Capture work well on iOS 8.3
I have the same problem. I have an iPhone 6 on iOS 8.3, It crashed at that place. Then I update iOS to 8.4. It never crashed.
Is there already a solution for it, it appears to crash only when i run it via xcode 6.4 when i kill the app and launch it without xcode it works like a charm iOS version 8.3 xCode version 6.4 Hope this will be solved :-)
This problem is present on Xcode 7 Beta 4 with iOS 8.3 devices (only on debug mode), it's work with iOS 9 Beta 4 devices.
Face the same issue here on Xcode 6.4 with iOS 8.3 devices like iPhone 5\iPhone 6 when debug.Now try to download 8.4 update for testing.
"@sndive - I think this is only localized to 8.3. 8.2 and below worked just fine in all of my testing. Are you seeing issues deploying from Xcode 6.4 to iOS versions below 8.3?"
works fine on 8.4, 8.0 and 7.1.2 thanks Brad
same here, crashes on iPhone4s, iPhone6, iPhone6+ with vanilla 8.3
works fine in XCode 6.3, iOS 8.3 crashes in XCode 7.1.1, iOS 8.3
Resolved by disabled "GPU Frame Capture", thank you limagustavo
i change
EAGLContext *context = [[EAGLContext alloc] initWithAPI:kEAGLRenderingAPIOpenGLES2 sharegroup:_sharegroup];
to
EAGLContext *context = [[EAGLContext alloc] initWithAPI:kEAGLRenderingAPIOpenGLES2];
the problem solved
nice
// in iOS8.x CALayer *superLayer = layer.superlayer; [layer removeFromSuperlayer]; if( ! [context_ renderbufferStorage:GL_RENDERBUFFER fromDrawable:layer] ) { NSLog(@"failed to call context"); } if (superLayer) { [superLayer addSublayer:layer]; }