After scanning for some seconds with a Scan quality insufficient : 0.0, I get a "GPUImageFramebuffer unlock" Exception.
kikolobo opened this issue · 9 comments
2016-03-21 17:50:02.556 PassportScanner[9842:4849034] *** Assertion failure in -[GPUImageFramebuffer unlock], /Users/frlobo/Downloads/PassportScanner-master-2/Pods/GPUImage/framework/Source/GPUImageFramebuffer.m:269
2016-03-21 17:50:02.558 PassportScanner[9842:4849034] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Tried to overrelease a framebuffer, did you forget to call -useNextFrameForImageCapture before using -imageFromCurrentFramebuffer?'
*** First throw call stack:
(0x18382d900 0x182e9bf80 0x18382d7d0 0x1841a099c 0x100197c80 0x100197e2c 0x184ac447c 0x184ac3510 0x18370d664 0x184ac3210 0x18370d664 0x18851cc24 0x182eb5ae8 0x18371142c 0x18411741c 0x1841d6728 0x101b65bb0 0x101b6b658 0x1837e4bb0 0x1837e2a18 0x183711680 0x184c20088 0x188588d90 0x1001005e4 0x1832b28b8)
libc++abi.dylib: terminating with uncaught exception of type NSException
I have done some work on this issue before. See issue #2
Apparently this is a known issue for the GPUImage library
Is the crash in your case reproducible or was it an one time instance?
I have a problem reproducing this issue.
Could you tell me what your iPhone, iOS and XCode version is?
Sure.
iPhone 6S
It is intermittent error, unpredictable when it will happen.
I am also having a hard time detecting passports on paper. On screen it's easier although not super easy.
I haven't been able to scan a paper passport.
When I get success can the 7 it's confused by a 1.
I will give it more in depth tries in different lighting conditions.
Thanks for the library, I will try to contribute as much as I can.
I have had very good results with an iPhone 6 (see video) but on a 5 the result was also not so optimal. The OCR library has some specific requirements for the image in order to make a good scan. It feels like i have to test different settings and use those based on the device version.
Way is this
On 22 Mar 2016 9:52 am, "Kiko Lobo" notifications@github.com wrote:
2016-03-21 17:50:02.556 PassportScanner[9842:4849034] *** Assertion
failure in -[GPUImageFramebuffer unlock],
/Users/frlobo/Downloads/PassportScanner-master-2/Pods/GPUImage/framework/Source/GPUImageFramebuffer.m:269
2016-03-21 17:50:02.558 PassportScanner[9842:4849034] *** Terminating app
due to uncaught exception 'NSInternalInconsistencyException', reason:
'Tried to overrelease a framebuffer, did you forget to call
-useNextFrameForImageCapture before using -imageFromCurrentFramebuffer?'
*** First throw call stack:
(0x18382d900 0x182e9bf80 0x18382d7d0 0x1841a099c 0x100197c80 0x100197e2c
0x184ac447c 0x184ac3510 0x18370d664 0x184ac3210 0x18370d664 0x18851cc24
0x182eb5ae8 0x18371142c 0x18411741c 0x1841d6728 0x101b65bb0 0x101b6b658
0x1837e4bb0 0x1837e2a18 0x183711680 0x184c20088 0x188588d90 0x1001005e4
0x1832b28b8)
libc++abi.dylib: terminating with uncaught exception of type NSException—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
#3
I am trying to do my scanning on an iPhone 6S. I am guessing that an approach might be to ask the user to take a picture of the passport and then have the app analyze it instead of capturing video frames. This has the advantage of better quality in the picture, and also you can filter the image in say... 10 different ways and see which one of the scans pass the success test and use those results....
I am going to try and find the time to contribute and help you with this.
There is now a GPUImage2 branch where I am using the GPUImage library. The code now looks a lot cleaner (pure swift) It still has a problem that I need to fix. It's only scanning the left part of the processed image.
The GPUImage2 branch is now stable and gives good results.
The GPUImage2 version is now merged to master and released as version 2.0.1