I was working off the beta code. I inserted the changes that you suggested below. I also needed to update the QCARControl.h and .mm classes with the version from the latest TextReco. The scanning view comes up, but now no words are found. Can you let me know if other changes were made between the beta version of textReco and the ios-2.5.1 version.
Attached is my log file:
2013-07-02 12:24:29.083 PronounceWords[555:907] QCARControl initQCAR
2013-07-02 12:24:29.263 PronounceWords[555:5b0f] INFO/AR(555) 2013-07-02 12:24:29: QCAR SDK version 2.5.7
2013-07-02 12:24:29.373 PronounceWords[555:907] viewFrame is {{0, 20}, {320, 460}}
2013-07-02 12:24:29.955 PronounceWords[555:5b0f] INFO: successfully initialised QCAR
2013-07-02 12:24:29.962 PronounceWords[555:907] QCARControl loadAndActivateTextTrackerWordList
2013-07-02 12:24:29.966 PronounceWords[555:907] QCARControl initTracker type 2
2013-07-02 12:24:29.995 PronounceWords[555:907] INFO: successfully initialised the tracker
2013-07-02 12:24:30.530 PronounceWords[555:907] QCARControl resumeQCAR
2013-07-02 12:24:30.660 PronounceWords[555:907] QCARControl startCameraForViewWidth:andHeight:
2013-07-02 12:24:30.686 PronounceWords[555:907] DEBUG/AR(555) UIView has CAEAGLLayer class
2013-07-02 12:24:30.688 PronounceWords[555:907] DEBUG/AR(555) UIView responds to selector renderFrameQCAR
2013-07-02 12:24:33.155 PronounceWords[555:907] *** -[AVCaptureVideoDataOutput setVideoSettings:] - videoSettings dictionary contains one or more unsupported (ignored) keys: (
Width,
AVVideoScalingModeKey,
Height
)
2013-07-02 12:24:33.169 PronounceWords[555:907] QCARControl camera started
2013-07-02 12:24:33.170 PronounceWords[555:907] Configuring video background (640.000000w x 920.000000h)
2013-07-02 12:24:33.176 PronounceWords[555:907] @>@ ROI center = [320, 105], S = [576, 147]
2013-07-02 12:24:33.181 PronounceWords[555:907] @>@ Setting loupe to center = [54, 180], S = [76, 300]
2013-07-02 12:24:33.183 PronounceWords[555:907] Configure Video Background: Video (480, 360), Screen (640.000000, 920.000000), mSize (690, 920)
2013-07-02 12:24:33.185 PronounceWords[555:907] Configure Video Background: Viewport x -25, y 0, width 690, height 920
2013-07-02 12:29:20.202 PronounceWords[555:82cf] QCARControl stopCamera
2013-07-02 12:29:20.497 PronounceWords[555:82cf] QCARControl stopTracker type 2
2013-07-02 12:29:20.512 PronounceWords[555:82cf] INFO: successfully stopped tracker
2013-07-02 12:29:20.516 PronounceWords[555:82cf] QCARControl deinitTracker type 2
2013-07-02 12:29:20.563 PronounceWords[555:82cf] QCARControl pauseQCAR
2013-07-02 12:29:20.579 PronounceWords[555:907] CoreData: sql: SELECT 0, t0.Z_PK, t0.Z_OPT, t0.ZWORD, t0.ZUNDERSTANDING, t0.ZWHATTYPE FROM ZLIST t0 JOIN ZPURPOSE t1 ON t0.ZWHATTYPE = t1.Z_PK WHERE t1.ZTYPE = ? ORDER BY t0.ZWORD COLLATE NSCollateLocaleSensitiveNoCase
2013-07-02 12:29:20.604 PronounceWords[555:907] CoreData: annotation: sql connection fetch time: 0.0179s
2013-07-02 12:29:20.608 PronounceWords[555:907] CoreData: annotation: total fetch execution time: 0.0289s for 94 rows.
2013-07-02 12:29:20.707 PronounceWords[555:82cf] QCARControl deinitQCAR
2013-07-02 12:29:22.989 PronounceWords[555:907] CoreData: sql: SELECT 0, t0.Z_PK, t0.Z_OPT, t0.ZWORD, t0.ZUNDERSTANDING, t0.ZWHATTYPE FROM ZLIST t0 JOIN ZPURPOSE t1 ON t0.ZWHATTYPE = t1.Z_PK WHERE t1.ZTYPE = ? ORDER BY t0.ZWORD COLLATE NSCollateLocaleSensitiveNoCase
2013-07-02 12:29:23.002 PronounceWords[555:907] CoreData: annotation: sql connection fetch time: 0.0090s
2013-07-02 12:29:23.004 PronounceWords[555:907] CoreData: annotation: total fetch execution time: 0.0153s for 94 rows.
2013-07-02 12:29:25.730 PronounceWords[555:907] QCARControl initQCAR
2013-07-02 12:29:25.740 PronounceWords[555:5c1f] INFO/AR(555) 2013-07-02 12:29:25: QCAR SDK version 2.5.7
2013-07-02 12:29:26.011 PronounceWords[555:907] viewFrame is {{0, 20}, {320, 460}}
2013-07-02 12:29:26.250 PronounceWords[555:5c1f] INFO: successfully initialised QCAR
2013-07-02 12:29:26.258 PronounceWords[555:907] QCARControl loadAndActivateTextTrackerWordList
2013-07-02 12:29:26.260 PronounceWords[555:907] QCARControl initTracker type 2
2013-07-02 12:29:26.277 PronounceWords[555:907] INFO: successfully initialised the tracker
2013-07-02 12:29:26.782 PronounceWords[555:907] QCARControl resumeQCAR
2013-07-02 12:29:26.906 PronounceWords[555:907] QCARControl startCameraForViewWidth:andHeight:
2013-07-02 12:29:26.921 PronounceWords[555:907] DEBUG/AR(555) UIView has CAEAGLLayer class
2013-07-02 12:29:26.923 PronounceWords[555:907] DEBUG/AR(555) UIView responds to selector renderFrameQCAR
2013-07-02 12:29:29.267 PronounceWords[555:907] *** -[AVCaptureVideoDataOutput setVideoSettings:] - videoSettings dictionary contains one or more unsupported (ignored) keys: (
Width,
AVVideoScalingModeKey,
Height
)
2013-07-02 12:29:29.281 PronounceWords[555:907] QCARControl camera started
2013-07-02 12:29:29.283 PronounceWords[555:907] Configuring video background (640.000000w x 920.000000h)
2013-07-02 12:29:29.285 PronounceWords[555:907] @>@ ROI center = [320, 105], S = [576, 147]
2013-07-02 12:29:29.291 PronounceWords[555:907] @>@ Setting loupe to center = [54, 180], S = [76, 300]
2013-07-02 12:29:29.296 PronounceWords[555:907] Configure Video Background: Video (480, 360), Screen (640.000000, 920.000000), mSize (690, 920)
2013-07-02 12:29:29.298 PronounceWords[555:907] Configure Video Background: Viewport x -25, y 0, width 690, height 920
When finshed, we run a method that duplicates the shutdown procedure in TextReco as follows:
Could you please check, because when I compare to the TextReco sample, the code is different (and shown below)
Furthermore it appears you may not be stopping the Text Tracker before you deinit() it.
HTH
N
- (void)applicationWillResignActive:(UIApplication *)application
{
// Remove any presented view controller that may be on display
[self rootViewControllerDismissPresentedViewController];
// Stop the camera
QCARControl* control = [QCARControl getInstance];
[control stopCamera];
qcarCameraIsActive = NO;
// Stop and deinitialise the tracker
(void)[control stopTracker:QCAR::Tracker::TEXT_TRACKER];
[control deinitTracker:QCAR::Tracker::TEXT_TRACKER];
// Pause and deinitialise QCAR
[control pauseQCAR];
[control deinitQCAR];
// Be a good OpenGL ES citizen: now that QCAR is paused and the render
// thread is not executing, inform the root view controller that the
// EAGLView should finish any OpenGL ES commands
[eaglViewController finishOpenGLESCommands];
}