promet / PRAugmentedReality

iOS Augmented Reality Framework
http://praugmentedreality.com/
MIT License
606 stars 162 forks source link

Out of Bounds Exception #21

Closed ezhes closed 11 years ago

ezhes commented 11 years ago

Hello! I seem to be stuck. I'm trying to manually load code into the AR view, but with this code I crash with *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSPlaceholderArray initWithObjects:count:]: attempt to insert nil object from objects[0]' *** I have my .m file over here: http://pastebin.com/58GjwaJU . If you see anything that I'm doing wrong, please do tell.

glesage commented 11 years ago

You just need to alloc & init your objectOne because it gets autoreleased to early (ts only passed by reference and the reference is lost count is lost somehow unless you alloc/init.

NSMutableDictionary *objectOne = [[NSMutableDictionary alloc] init];

(:

ezhes commented 11 years ago

@glesage So the camera opens up now, except even the the lat / long cooridinates are within view, they aren't on the view. Am I doing something wrong with the data setup?

glesage commented 11 years ago

Uhm they should be on the view, I'm seeing it here when I use your data... make sure you turn all around to see where it is...

ezhes commented 11 years ago

So sorry. I had my location set as London. No wonder it was out of range.

Sent from my iPhone

On Jun 25, 2013, at 11:15 AM, Geoffroy notifications@github.com wrote:

Uhm they should be on the view, I'm seeing it here when I use your data... make sure you turn all around to see where it is...

— Reply to this email directly or view it on GitHub.

glesage commented 11 years ago

yea np