Size of Ogre3d iPhone applications
-
- Gnoblar
- Posts: 7
- Joined: Tue Feb 09, 2010 7:07 pm
Size of Ogre3d iPhone applications
Congratulations for the iPhone port!
What's the size of a Simple ogre3d application (release) in KBytes?
For example a scene with a cube?
What's the size of a Simple ogre3d application (release) in KBytes?
For example a scene with a cube?
-
- OGRE Retired Team Member
- Posts: 4270
- Joined: Sun Feb 25, 2007 4:56 am
- Location: Bloomington, MN
- x 126
Re: Size of Ogre3d iPhone applications
You know, I haven't tried a basic app recently. But I know that at one time I was able to get the SampleBrowser under 15MB including resources.
-
- Gnoblar
- Posts: 7
- Joined: Tue Feb 09, 2010 7:07 pm
Re: Size of Ogre3d iPhone applications
I think 15MB for 3d iphone game applications are a good size.
I saw this "top 10" list, from 2008:
http://www.appleinsider.com/articles/08 ... games.html
There are many games from +-30 to +-50 MB...
I saw this "top 10" list, from 2008:
http://www.appleinsider.com/articles/08 ... games.html
There are many games from +-30 to +-50 MB...
-
- Ogre Magi
- Posts: 1260
- Joined: Mon Aug 07, 2006 6:16 am
- Location: Colorado Springs, CO USA
Re: Size of Ogre3d iPhone applications
Awhile ago I thought somebody was talking about striping some of the supported image formats (since all we really need is PVR and MAYBE png). That seems like that would save a fair bit of space no?
Anyone have any other ideas for stuff we could strip out? I agree 15-30meg is no big deal for "real" 3d ganes, but It would be REALLY nice to have a 'minimalistic' build option for simple apps.
Anyone have any other ideas for stuff we could strip out? I agree 15-30meg is no big deal for "real" 3d ganes, but It would be REALLY nice to have a 'minimalistic' build option for simple apps.
-
- Gnoblar
- Posts: 2
- Joined: Wed Mar 31, 2010 10:04 pm
Re: Size of Ogre3d iPhone applications
hi everyone!
first i want to say thank you for your work on ogre and the port.
i'm currently researching different 3d engines for the iphone and one of my concerns is the build size of my apps.
i've followed the basic steps to build for the iphone (wiki) which results in a 71.2 MB (release) / 70.9 MB (min size release) sample browser. The package contains 49.7 MB for resources and a 21.4 / 21.2 MB sized executable.
So, i compared the file size of the static libs (i guess i don't need all of them within my apps), and the libOgreMainStatic.a has a file size of 28.7 / 27.7 MB (compared to irrlicht, which has 10.6MB).
When i read that you were able to get the SampleBrowser under 15MB (including resources), i started thinking that i'm doing something terrible wrong . Are there any tricks to reduce the build size? Normally, i wouldn't mind 30MB, but you know, the over air download limit is currently 20MB, so 15MB for the SampleBrowser could open that door for some apps.
first i want to say thank you for your work on ogre and the port.
i'm currently researching different 3d engines for the iphone and one of my concerns is the build size of my apps.
i've followed the basic steps to build for the iphone (wiki) which results in a 71.2 MB (release) / 70.9 MB (min size release) sample browser. The package contains 49.7 MB for resources and a 21.4 / 21.2 MB sized executable.
So, i compared the file size of the static libs (i guess i don't need all of them within my apps), and the libOgreMainStatic.a has a file size of 28.7 / 27.7 MB (compared to irrlicht, which has 10.6MB).
When i read that you were able to get the SampleBrowser under 15MB (including resources), i started thinking that i'm doing something terrible wrong . Are there any tricks to reduce the build size? Normally, i wouldn't mind 30MB, but you know, the over air download limit is currently 20MB, so 15MB for the SampleBrowser could open that door for some apps.
-
- OGRE Retired Team Member
- Posts: 4270
- Joined: Sun Feb 25, 2007 4:56 am
- Location: Bloomington, MN
- x 126
Re: Size of Ogre3d iPhone applications
There were several things that I did. The trick was to limit the number of file formats supported in FreeImage along with stripping out anything unnecessary. Use PVR textures. Keep in mind that despite the libraries being that size, a lot of it might be stripped out when you link. It all depends on what features you use.
-
- Ogre Magi
- Posts: 1235
- Joined: Fri Oct 26, 2007 12:36 am
- Location: Mountain View, CA
- x 10
Re: Size of Ogre3d iPhone applications
Hmm, did you include the stripped down version of freeimage in the iPhone dependencies package?masterfalcon wrote:The trick was to limit the number of file formats supported in FreeImage along with stripping out anything unnecessary.
-
- OGRE Retired Team Member
- Posts: 4270
- Joined: Sun Feb 25, 2007 4:56 am
- Location: Bloomington, MN
- x 126
Re: Size of Ogre3d iPhone applications
I don't think so, but I could make it available.
-
- Silver Sponsor
- Posts: 2703
- Joined: Mon Aug 29, 2005 3:24 pm
- Location: Kuala Lumpur, Malaysia
- x 51
Re: Size of Ogre3d iPhone applications
Well if you want to know in more precise manner which libraries/functions bloat the size, you can check this utility here: http://codesuppository.blogspot.com/201 ... files.html. And there are another 2-3 good links posted by the visitors.
A willow deeply scarred, somebody's broken heart
And a washed-out dream
They follow the pattern of the wind, ya' see
Cause they got no place to be
That's why I'm starting with me
And a washed-out dream
They follow the pattern of the wind, ya' see
Cause they got no place to be
That's why I'm starting with me
-
- OGRE Retired Team Member
- Posts: 4270
- Joined: Sun Feb 25, 2007 4:56 am
- Location: Bloomington, MN
- x 126
Re: Size of Ogre3d iPhone applications
Only problem with that is that you can't make iPhone apps with Visual Studio.
-
- Gnoblar
- Posts: 15
- Joined: Sat Jan 08, 2011 12:33 am
Re: Size of Ogre3d iPhone applications
We're currently investigating our large executable size as well.
We have a very simple game - a couple of large quads and 6 skinned characters. We're not doing anything fancy.
However, our executable size (*not* including resources) in Release is 17.5 MB. I haven't tried linking against MinSizeRel yet but the library files barely changed in size so I don't expect much of a decrease there.
I suspect that dead-code stripping either isn't working properly (I think I've made the necessary changes to both the Ogre project and mine to enable it), or the linker is just unable to strip very much because it thinks most of the code may end up getting used at runtime.
Has anyone else found the magic bullet to reduce the footprint of Ogre?
Thanks,
Brian
We have a very simple game - a couple of large quads and 6 skinned characters. We're not doing anything fancy.
However, our executable size (*not* including resources) in Release is 17.5 MB. I haven't tried linking against MinSizeRel yet but the library files barely changed in size so I don't expect much of a decrease there.
I suspect that dead-code stripping either isn't working properly (I think I've made the necessary changes to both the Ogre project and mine to enable it), or the linker is just unable to strip very much because it thinks most of the code may end up getting used at runtime.
Has anyone else found the magic bullet to reduce the footprint of Ogre?
Thanks,
Brian
-
- Ogre Magi
- Posts: 1120
- Joined: Wed Nov 15, 2006 7:41 pm
- Location: Finland
- x 5
Re: Size of Ogre3d iPhone applications
I don't code for iPhone but I think stripping FreeImage out completely is a sensible option to take unless you really know that you specifically must use it. I think this is the quickest and easiest way to bring the size down at least on PC.
Personally I just chose one image file format (DDS) and actually with this choice on the PC there is no need for image libraries to go with OGRE at all for just getting your textures displayed on your models.
Personally I just chose one image file format (DDS) and actually with this choice on the PC there is no need for image libraries to go with OGRE at all for just getting your textures displayed on your models.
-
- Gnoblar
- Posts: 1
- Joined: Fri Feb 04, 2011 11:41 am
Re: Size of Ogre3d iPhone applications
Here are few tips I used to reduce the size of my application:
* as suggested by reptor I strip libFreeImage to the strict minimum (I just keeped PNG)
* I remove ogre plugins I didn't require (I keeped none, just the GLES renderer)
* I remove from ogre code code related to stuff I didn't use. A lot of code can't be stripped by default because most managers are loaded during initialisation. OgreRoot.cpp is a good place to start to remove unused components. For instance I remove the FontManager and therefore dependencies upon FreeType
* I disable multithreading and therefore multithreading libraries (actually I was more due to some issues with it)
* I compile for armV7 only, with -Os and -DNDEBUG
By this way I managed to reduce my application from ~40MB to ~12MB
* as suggested by reptor I strip libFreeImage to the strict minimum (I just keeped PNG)
* I remove ogre plugins I didn't require (I keeped none, just the GLES renderer)
* I remove from ogre code code related to stuff I didn't use. A lot of code can't be stripped by default because most managers are loaded during initialisation. OgreRoot.cpp is a good place to start to remove unused components. For instance I remove the FontManager and therefore dependencies upon FreeType
* I disable multithreading and therefore multithreading libraries (actually I was more due to some issues with it)
* I compile for armV7 only, with -Os and -DNDEBUG
By this way I managed to reduce my application from ~40MB to ~12MB
-
- Gnoblar
- Posts: 15
- Joined: Sat Jan 08, 2011 12:33 am
Re: Size of Ogre3d iPhone applications
Thanks for the tips! I'll give them a go.
Brian
Brian
-
- Gnoblar
- Posts: 1
- Joined: Wed Feb 09, 2011 8:50 am
Re: Size of Ogre3d iPhone applications
I prefer GIF to PNG for libFreeImage