My latest plugin, GBC Object Pool, is now in the marketplace.
The GBC Object Pool plugin allows the CoronaSDK developer to easily and quickly implement object pooling within your application. Using two lines of code, you can create an object pool. GBC Object Pool optimizes the management of pooling, allowing for object reuse and eliminates garbage collection inherently found with traditional create/destroy functions.
The plugin provides several examples of pooling. If there are any questions or requests, please let me know. I plan on writing more examples, blogs, and perhaps some videos on the use of this plugin.
Thanks John. I’m hoping this will along with other changes improve the responsiveness of my game on slower windows machines, particularly those with IDE drives.
Are the performance bonuses less obvious on mac and iOS because slowest apple devices maintain a level of processing and graphics power much higher than low-end Windows and Android devices?
I would be interested in seeing a video for sure. No rush, I purchased the plugin but I probably won’t implement it for while.
Hi, and thanks for your purchase Sharp100… I appreciate it.
I ran some performance metrics on Windows and Android and I blog about it here. I can also give it a try on iOS and OSX, and I can publish those results. As for videos, I can give that a shot as well… I’ve been thinking about it a bit.
The results in the test I performed show that object pooling in general (and the GBC Object Pool plugin to be specific) is faster than the typical create/destroy methods used without pooling. Pooling eliminates the overhead of allocating memory and garbage collection during the create/destroy cycle. You can see that pooling results in more consistent performance as well. The wide dispersion on times using create/destroy as shown in the charts may cause an issue when a user is playing your game… they might notice stutters or delays.
I have a sample app with source code that shows object pooling in action (located here), and it’s free to download. The first scene is a performance test, and you will see that the type of object you want to pool will impact performance. For example, creating/destroying a simple white square shape will probably not show significant performance gains using pooling (in other words, Corona is pretty good at doing that).
Where pooling (and my plugin) really improves performance is in creating pools of images, optional physics properties, and/or complex objects.
Hope this helps. If anyone has questions, please let me know.
Yes, that’s very helpful and I have an app with lots of physics bodies that lags on Android devices. This should definitely help! Your language cabinet looks cool too. I look forward to trying that plugin as well.
Don’t know if you saw my e-mail yet, having another issue with the autoexpand feature whereby more than the specified number of objects are created, which exponentially increases each time the pool runs dry.
An update to GBC Object Pool is now in the Marketplace. This update enables a way to pass a table of parameters to your create and reset functions, which helps reduce the amount of code needed to manage your pools. You can read about it in more detail here:
Thanks John. I’m hoping this will along with other changes improve the responsiveness of my game on slower windows machines, particularly those with IDE drives.
Are the performance bonuses less obvious on mac and iOS because slowest apple devices maintain a level of processing and graphics power much higher than low-end Windows and Android devices?
I would be interested in seeing a video for sure. No rush, I purchased the plugin but I probably won’t implement it for while.
Hi, and thanks for your purchase Sharp100… I appreciate it.
I ran some performance metrics on Windows and Android and I blog about it here. I can also give it a try on iOS and OSX, and I can publish those results. As for videos, I can give that a shot as well… I’ve been thinking about it a bit.
The results in the test I performed show that object pooling in general (and the GBC Object Pool plugin to be specific) is faster than the typical create/destroy methods used without pooling. Pooling eliminates the overhead of allocating memory and garbage collection during the create/destroy cycle. You can see that pooling results in more consistent performance as well. The wide dispersion on times using create/destroy as shown in the charts may cause an issue when a user is playing your game… they might notice stutters or delays.
I have a sample app with source code that shows object pooling in action (located here), and it’s free to download. The first scene is a performance test, and you will see that the type of object you want to pool will impact performance. For example, creating/destroying a simple white square shape will probably not show significant performance gains using pooling (in other words, Corona is pretty good at doing that).
Where pooling (and my plugin) really improves performance is in creating pools of images, optional physics properties, and/or complex objects.
Hope this helps. If anyone has questions, please let me know.
Yes, that’s very helpful and I have an app with lots of physics bodies that lags on Android devices. This should definitely help! Your language cabinet looks cool too. I look forward to trying that plugin as well.
Don’t know if you saw my e-mail yet, having another issue with the autoexpand feature whereby more than the specified number of objects are created, which exponentially increases each time the pool runs dry.