iMiniB3D V0.4

BlitzMax Forums/MiniB3D Module/iMiniB3D V0.4

simonh(Posted 2010) [#1]
Download from here. See iminib3d.h for instructions.

You will need Xcode 3.2.2 and iPhone SDK 3.2 to run this version, which requires Snow Leopard.

This version supports iPad development.

The included examples are universal apps (they run on both iPhone and iPad), so you can run them on either device. It's easy to change them to iPhone or iPad only - you just need to change the target 'Targeted Device Family' setting.

To run them on an iPad, select 'iPhone Device 3.2' from the 'Active SDK' list.

Also, you will need to specify the iPad resolution (768,1024) with the Graphics command to fill the iPad screen - by default the Graphics command sets an iPhone sized resolution.

Finally, some bugs already reported here remain in this version - I just thought it best to release the latest version ASAP.


Panno(Posted 2010) [#2]
thx simon !


Robert Cummings(Posted 2010) [#3]
Ah I posted in the other topic regarding querying the orientation and screen size which you need for appstore compliance. Didn't see this :)


ima747(Posted 2010) [#4]
My hero!

3g's ship the 30th and this lands today, just enough time for me to poke out a test before my hardware shows up!

Thanks Simon!

[Update]
Got the 0.3 project I was last working on that was failing to compile due to something I did working in 0.4 with no errors or crashing in a matter of minutes, and testing on the iPad simulator to boot. Thanks again simon!


jhocking(Posted 2010) [#5]
I missed this update, my mind was busy with being trapped overseas by the volcano. Can't wait to test this.


Rob Pearmain(Posted 2010) [#6]
Hi Simon,

When compiling I get the following error:

Ld build/Debug-iphonesimulator/bird.app/bird normal i386
cd /Users/rob/Downloads/iminib3d
setenv MACOSX_DEPLOYMENT_TARGET 10.5
setenv PATH "/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++-4.2 -arch i386 -isysroot /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator3.2.sdk -L/Users/rob/Downloads/iminib3d/build/Debug-iphonesimulator -F/Users/rob/Downloads/iminib3d/build/Debug-iphonesimulator -filelist /Users/rob/Downloads/iminib3d/build/iminib3d.build/Debug-iphonesimulator/bird.build/Objects-normal/i386/bird.LinkFileList -mmacosx-version-min=10.5 -framework CoreFoundation -framework OpenGLES -framework QuartzCore -framework UIKit -framework CoreGraphics -framework Foundation -liminib3d -o /Users/rob/Downloads/iminib3d/build/Debug-iphonesimulator/bird.app/bird

ld: library not found for -liminib3d
collect2: ld returned 1 exit status
Command /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/g++-4.2 failed with exit code 1

Any ideas to what I am doing wrong? Thanks


Rob Pearmain(Posted 2010) [#7]
The basic error is:

ld: library not found for -liminib3d

I am guessing there is a separate library I need to download that I am missing?


jhocking(Posted 2010) [#8]
You need to build iminib3d before building your game. Right-click on the iminib3d target and choose Build. Incidentally, you need to do this both for device and simulator, since the compiled library is different in each setting.

More generally, look in iminib3d.h for these and other instructions explaining how to use it.


Rob Pearmain(Posted 2010) [#9]
Perfect, compiles and works great, thanks


Sledge(Posted 2010) [#10]
Great stuff. Regarding universal apps, the docs should probably reflect the fact that the application plist does not have the required NSMainNibFile~ipad entry by default... had me scratching my head for about a hour, faffing with viewports and whatnot, that!

Also, I found this page very useful for working out how to detect which device you're running on.


jhocking(Posted 2010) [#11]
So does anyone know what happens with the higher resolution on iPhone 4? Are apps at the old resolution in a letterboxed window like with the iPad, or does the newly branded iOS automatically resample to be fullscreen?


Dreamora(Posted 2010) [#12]
we will see, we don't know yet.


ima747(Posted 2010) [#13]
the ratio is the same so it should just up sample anything it can't re-render. e.g. text is rendered and smoothed on the fly so that should come out crisper on the new screen with no changes, however graphics obviously can't have pixels magically added so they will be whatever they are. They will only look pixelated in direct comparison to something that is native however.

Of course conjecture, but based off of what was said in the press conference yesterday regarding the text smoothing on the new screen.

It would also be a bad idea to throw away the huge catalog of existing native sized apps for a few extra pixels on the new screen. The iPad is a bit different since the aspect ratio is different in addition to the pixel count. Also the iPad has a different footprint and is based off of it's own revision of iPhone OS (3.2 does not run on iPhones/touches, and the 4.0 beta is not available for iPad...) so there are some more fundamental hardware and software things at work there.

Side note, I really wish the iPad had an option to disable the simulated iPhone keyboard when running iPhone apps and use the native iPad keyboard... but I assume they were affraid of the potential layout issues that could arrise... would just like it as an option for those apps that wouldn't have layout issues...


Robert Cummings(Posted 2010) [#14]
It will scale up by default anything thats not been compiled for ios 4.


Robert Cummings(Posted 2010) [#15]
"Also, you will need to specify the iPad resolution (768,1024) with the Graphics command to fill the iPad screen - by default the Graphics command sets an iPhone sized resolution."


Would I be remiss in thinking it will work fine on iphone 4? :)


Boiled Sweets(Posted 2010) [#16]
This looks like it could be fun!


jhocking(Posted 2010) [#17]
Does iminib3d .3 work in iPhone SDK 4? I can't remember if v.4 is required for the latest iPhone SDK.

I have a side-project that I haven't yet upgraded to the latest version of iminib3d and have to make some edits to. In the long run I'll be upgrading the project to the latest version, but in the short term I'd like to just make these couple of quick edits to send to someone the day after tomorrow.


JoeRetro(Posted 2010) [#18]
Not sure as I'm using v.4, but why not just download the latest and see for yourself?


jhocking(Posted 2010) [#19]
Because of, well, the second paragraph. I already have v.4 and am using it for most of my projects, I just have one project I still haven't upgraded that I kinda want to make some quick edits to. I'm wondering if I can make those edits or if this is a lost cause.

If you want an even longer story response, that project is still running fine on my phone, but distribution builds (ie. ad hoc tests I send to other people) are crashing on model loading.

EDIT: In case anyone else cares, v.3 works in the latest XCode but requires some tricky build settings to still access the 3.0 SDK.


Robert Cummings(Posted 2010) [#20]
still get the same rate of downloads a day of my game (which has turned a respectable profit now) using iOs 4. Amazing what a simplistic game can do if you keep driving it.


jhocking(Posted 2010) [#21]
Well that is encouraging. Because of various personal and job issues I haven't worked on my game in nearly 3 weeks so I really need the motivation to get back on the saddle. You know how it is; I'm past the fun work of implementing new features and now I'm looking at the grind of churning out dozens of levels.


ima747(Posted 2010) [#22]
ugh, so many stalled projects at the "grind" phase...

Got any tips for us on how to drive Robert? More sales is more motivation to get something better out sooner :0)


jhocking(Posted 2010) [#23]
just noticed a small issue in the v.4 SDK

In the "zombie" sample you commented out the lines that load the level. Presumably you just commented that out while testing something and forgot to uncomment.


Ian Thompson(Posted 2011) [#24]
Is (v0.4) this the latest version of iMiniB3D? There was some bugs that were mentioned in the top post, what are they, have they been fixed?

Many thanks,


ima747(Posted 2011) [#25]
Yes 0.4 is the current version. Search the forum for iminib3d for reported errors and fixes. I don't recall if they were worked into the official source or not.


Ian Thompson(Posted 2011) [#26]
OK thanks, just started to use it, a bit late for the party I know! :D

It's a great little lib.


Chroma(Posted 2011) [#27]
...typo

Last edited 2011