interesting 32bit nw.js v0.19.2 crashing issue

Discussion and feedback on Construct 2

Post » Tue Jan 17, 2017 3:43 am

@Ashley Tested and to confirm:

Turning off preload sound lets the 32-bit version of the game boot up perfectly. But crashes after 2 to 3 hours of gameplay.

Turning on preload sound makes the 32-bit version crash as soon as it starts up.

64-bit builds work either way.
B
34
S
8
G
1
Posts: 39
Reputation: 2,322

Post » Tue Jan 17, 2017 1:24 pm

Thanks, that confirms it's to do with audio memory management. I must point out turning the "preload sounds" option means you are explicitly telling C2 to load and decompress all sounds in to memory on startup, which if you use a lot of sounds, can be a very great deal. But the fact it doesn't release any and still ultimately crashes is a problem. I'll try and get audio unloading in the next build...
Scirra Founder
B
400
S
237
G
89
Posts: 24,549
Reputation: 195,525

Post » Tue Jan 17, 2017 1:29 pm

Ashley wrote:Thanks, that confirms it's to do with audio memory management. I must point out turning the "preload sounds" option means you are explicitly telling C2 to load and decompress all sounds in to memory on startup, which if you use a lot of sounds, can be a very great deal. But the fact it doesn't release any and still ultimately crashes is a problem. I'll try and get audio unloading in the next build...

We're about to release our version of the unloading audio feature, this could maybe make things easier on your end.
However nothing stops you from doing everything by yourself, looking forward to it either way.
ImageImageImage
B
64
S
24
G
78
Posts: 666
Reputation: 45,070

Post » Tue Jan 17, 2017 3:27 pm

Well here it is @StaticCloud, I hope it fits your needs.
experimental-audioplus-plugin-unloading-audio_t186455
ImageImageImage
B
64
S
24
G
78
Posts: 666
Reputation: 45,070

Post » Tue Jan 17, 2017 8:29 pm

Ashley wrote:I'll try and get audio unloading in the next build...

It would be awesome to see it as an official feature. @TheRealDannyyy thank you for your hard work as well.
B
135
S
33
G
17
Posts: 1,560
Reputation: 20,734

Post » Wed Jan 18, 2017 3:10 am

@TheRealDannyyy Thank you for this, very helpful! Hopefully, will find it`s way into an official update too.

Out of interest how does memory management / garbage collection of video work? - is it like image files with automatic garbage collection on layout change or more like audio? Could we further save ram use by unloading video from ram after viewing?
B
34
S
8
G
1
Posts: 39
Reputation: 2,322

Post » Wed Jan 18, 2017 5:24 am

glerikud wrote:
Ashley wrote:I'll try and get audio unloading in the next build...

It would be awesome to see it as an official feature. @TheRealDannyyy thank you for your hard work as well.

Thanks to BackendFreak, I'm just the "publisher" for this one.


StaticCloud wrote:@TheRealDannyyy Thank you for this, very helpful! Hopefully, will find it`s way into an official update too.

Out of interest how does memory management / garbage collection of video work? - is it like image files with automatic garbage collection on layout change or more like audio? Could we further save ram use by unloading video from ram after viewing?

I've honestly never used the video plugin and I'm using C2 for a couple of years now.
I think memory management for videos is handled by the "destroy" action?

Judging by THIS changelog I assume that destroying the video, unloads the memory used for the playback.
The best way to make sure that it is, is by doing measurements on your end and see if memory usage goes down when destroying the object or changing the layout.
ImageImageImage
B
64
S
24
G
78
Posts: 666
Reputation: 45,070

Previous

Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 6 guests