Hi Community,
i'm running into a problem by using Irrlicht on iOS 7 while using the speech (siri) input feature of UITextField. The App crashes directly.
It seems to be the same issue Cocos2d had. http://www.cocos2d-x.org/issues/2920
Is it possible to solve this problem in irrlicht too?
Thanks.
Crash while using iOS 7's speech input
-
- Developer
- Posts: 25
- Joined: Tue Jan 21, 2014 9:15 pm
- Location: Goch, NRW, Germany
- Contact:
Crash while using iOS 7's speech input
Best regards,
Daniel Bocksteger
German iOS Developer born in '95.
Daniel Bocksteger
German iOS Developer born in '95.
Re: Crash while using iOS 7's speech input
It looks like this problem isn't related to Irrlicht (we don't use UITextField in Irrlicht), but to your code and how you manage UITextField. Check this fix:
https://github.com/boyu0/cocos2d-x/comm ... 577e3120f1
https://github.com/boyu0/cocos2d-x/comm ... 577e3120f1
Library helping with network requests, tasks management, logger etc in desktop and mobile apps: https://github.com/GrupaPracuj/hermes
-
- Developer
- Posts: 25
- Joined: Tue Jan 21, 2014 9:15 pm
- Location: Goch, NRW, Germany
- Contact:
Re: Crash while using iOS 7's speech input
This fix isn't really adoptable to normal iOS Code. this is a C++/Objective-C mix.
Hoped that anyone here was in struggle with this problem too...
Hoped that anyone here was in struggle with this problem too...
Best regards,
Daniel Bocksteger
German iOS Developer born in '95.
Daniel Bocksteger
German iOS Developer born in '95.
Re: Crash while using iOS 7's speech input
Why not? This is Objective-C++, however important changes are related to Objective-C.
Library helping with network requests, tasks management, logger etc in desktop and mobile apps: https://github.com/GrupaPracuj/hermes
-
- Developer
- Posts: 25
- Joined: Tue Jan 21, 2014 9:15 pm
- Location: Goch, NRW, Germany
- Contact:
Re: Crash while using iOS 7's speech input
My problem is, that this isn't the normal implementation of UITextField. I can't find the piece of code which has to be adopted to our app.
Tried to get in contact with the developer and waiting for an response now.
Tried to get in contact with the developer and waiting for an response now.
Best regards,
Daniel Bocksteger
German iOS Developer born in '95.
Daniel Bocksteger
German iOS Developer born in '95.
-
- Developer
- Posts: 25
- Joined: Tue Jan 21, 2014 9:15 pm
- Location: Goch, NRW, Germany
- Contact:
Re: Crash while using iOS 7's speech input
After some try&error sessions i got a working hack...
Now the App isn't crashing when users starts the voice recognition. I set the isRunnung property to NO while user-input and YES when the user finished.
Problem:
After finishing the editing-mode the irrlicht scene is completly "blue"...
Code: Select all
- (void)updateDisplay {
@try {
while(isActive)
{
@autoreleasepool
{
while(CFRunLoopRunInMode(kCFRunLoopDefaultMode, 0.002, TRUE) == kCFRunLoopRunHandledSource);
}
if(isActive) {
if (isRunning) {
if(!device->run())
break;
@try {
if (device != nil && driver->endScene()){// && driver->beginScene()) {
[self beginScene];
// Wird auf dem Main-Thread ausgeführt, da es sonst zu Komplikationen zwischen den Threads kommt.
[self performSelectorOnMainThread:@selector(drawAll) withObject:nil waitUntilDone:YES];
// Wird ausgeführt wenn drawAll() durch gelaufen ist !!! ------------------------^
[self performSelectorOnMainThread:@selector(endScene) withObject:nil waitUntilDone:YES];
//device->yield();
}
else{
driver->endScene();
}
}
@catch (NSException *exception) {
SPAlertView *alert = [WWSExceptionManager showException:exception.description andLocation:[NSString stringWithFormat:@"%s", __PRETTY_FUNCTION__]];
[alert show];
}
}
}
else
{
driver->endScene();
//device->drop();
}
}
}
@catch (NSException *exception) {
SPAlertView *alert = [WWSExceptionManager showException:exception.description andLocation:[NSString stringWithFormat:@"%s", __PRETTY_FUNCTION__]];
[alert show];
}
}
Problem:
After finishing the editing-mode the irrlicht scene is completly "blue"...
Best regards,
Daniel Bocksteger
German iOS Developer born in '95.
Daniel Bocksteger
German iOS Developer born in '95.
-
- Developer
- Posts: 25
- Joined: Tue Jan 21, 2014 9:15 pm
- Location: Goch, NRW, Germany
- Contact:
Re: Crash while using iOS 7's speech input
Is it Possible to pause the Irrlicht-Device and the render loop without pausing the complete App/iPad?
When we use yield() or sleep() the hole iPad sleeps.
Thanks.
When we use yield() or sleep() the hole iPad sleeps.
Thanks.
Best regards,
Daniel Bocksteger
German iOS Developer born in '95.
Daniel Bocksteger
German iOS Developer born in '95.