www.jpct.net

jPCT-AE - a 3d engine for Android => Support => Topic started by: nnyerges on September 28, 2014, 02:17:16 am

Title: jPCT-AE HELLO WORLD 3D Engine doesn't close
Post by: nnyerges on September 28, 2014, 02:17:16 am
Hi
Is there any method to close/dispose/kill/ or what ever to stop de 3d engine from running after application close?

1. Open Hello-World example on your device
2. Move the cube and note the las position
3. Close the application by pressing back
4. Open it again and the cube its in the same position. The application never close?
Maybe i miss something
Chears...
Title: Re: jPCT-AE HELLO WORLD 3D Engine doesn't close
Post by: EgonOlsen on September 28, 2014, 10:40:32 am
That's not a bug. It's the way which Android is supposed to work. If you really want to close the app (albeit there's almost never a real reason to do so...), you can add a call to System.exit(0) to the onStop() method for example. But as said: Why would you want to?
Title: Re: jPCT-AE HELLO WORLD 3D Engine doesn't close
Post by: nnyerges on September 29, 2014, 07:33:46 pm
Thank's..Sorry, you are right, its not a bug. I just understand the use of the "copy(master)" on the HelloWorld-AE example. About not closing an application, just a simple question: ... is not consuming more memory on the device?. Why I should leave HelloWorld-AE paused in the background?

Edited:

By the way, calling System.exit(0); on the onStop() method, !solves! the emulator's Fatal signal 11 (SIGSEGV) error
Title: Re: jPCT-AE HELLO WORLD 3D Engine doesn't close
Post by: EgonOlsen on September 29, 2014, 08:16:04 pm
Android will dispose the app by itself if the system needs the memory back. In most cases, there's no need to interfere with this. Which signal 11 error, btw?
Title: Re: jPCT-AE HELLO WORLD 3D Engine doesn't close
Post by: nnyerges on October 01, 2014, 05:03:02 pm
Egon, I have only one month learning to program android and your forum is helping me a lot. Thank you for the information.

About de error, please read post http://www.jpct.net/forum2/index.php/topic,3987.msg29027.html#msg29027

Chears,
Nicolás