Using OpenStreetMap on iPhone offline - iphone

I am working on an iPhone app. project and my group is trying to use the OpenStreetMap offline.
I have been Googling for tutorials but can't find any decent tutorials. Can any of you guys help me out and give me a link for good tutorial?
We need to be able to access the map offline. Right now I have downloaded the map image tiles for my city and put it into the database file and it runs on the iPhone simulator but I want to be able to "limit" the user view because you could scroll out of bounds and you can see the grey area where no tiles were downloaded.
Other features I need to know how to edit is adding a marker (for example, I want to include a bus stop on the map when you open the app on iPhone)
Any help would be appreciated guys
Thanks!

I build an app which also uses OpenStreetMap. I used route-me library for it. By default, if you do no configuration, it fetches its tiles from the internet and then caches the most recently retrieved tiles in a database in your documents directory.
The code is readable and not too big. I had to draw to layers instead of one, so i overrode some classes (TileSource and Tile) and got it working with two layers.
I don't think it would be hard to adjust the tilecache to keep its contents permanently offline and to limit it to a specific area. By the way, route-me also knows some db formats as tile source. But I've never used them.
The wiki documentation on the github site tells you how to include route-me in your own project. I used the external link that pointed to how to do it in Xcode 4.
https://github.com/route-me/route-me

Related

Augmented Reality : Recognize hand written number?

I am trying to find a solution for this AR app as the topic tells.
I want my app to recognize a hand-written number by the user.
The app will tell the user to write down for example number 24 on a paper and move the camera over the written number to see the 3d object.
This might be used for saving a Birthday, a wedding date .. etc
For accuracy, the app instructions will show the user a preview to tell please write the number 24 similar to this..
Although each hand writing will differ, but at least we do not get curly "2"-s or "4" with an open edge ..etc
So here we need AR to recognize the number, or be able to read the number according to approximation.
And the first question is: Is such a behavior doable or anyone familiar with a similar concept?
After searching similar apps, I found "Ink Hunter" apps for tatoo preview-s, although these apps use symbols not number, but we can think of a number as a symbol as well.
Also as this video: https://www.youtube.com/watch?v=9rXJcIE2Fcs shows, each user draws the symbol in a different way and still they get it working.
I am using Unity3d and Vuforia.
Vuforia offers free samples(unity3d packages) on the website, and there is one named "Text Recognition" , and here's the tutorial link: https://www.youtube.com/watch?v=W3MK6nC5FWE
But unfortunately couldn't make it work.
If someone has developed such a functionality using these sample projects from vuforia or have any ulternative method please I need you help :)
thanks in advance moghes
Here's a tutorial our team created on text recognition using the Hololens and Vuforia with Unity: https://www.youtube.com/watch?v=WdMeHgD4fMY. In the first portion of the video, we show how to get text recognition working with just Vuforia and Unity - no Hololens required. For your application, just change the text to numbers.
I believe the biggest challenge you will have is the "hand-written" component. From our research, Vuforia prefers computer-generated, predefined font types.

Best way to build a camera app on iPhone

I am thinking of building a camera application - with the ability to do image processing (adjust contrast, apply different image filters) while you are taking picture or after the pictures has taken.
The app will also have the ability of drag and drop icons.
At the end you are able to export the edited images either to the camera roll or app memory.
There is already many apps out there like this. (Line Camera) etc...
Just wondering what is the best way to build such app.
Can I build the app purely with Objective C ios sdk? or do i need to build it with C++/cocos2d, etc...
Thanks for your help!
Your question is very broad, so here is a broad answer...
Accessing the camera/photo library
First you'll need to access the camera using UIImagePickerController to either take a new photo or grab one from your photo library. You can read up on how to accomplish this here: Camera Programming Topics for iOS
Image Manipulation
AviarySDK has much of this already built for you. Very easy to set up and use in your apps. You can download their sample app for free in the app store if you want to see what it can do. Check it out here: http://aviary.com/
Alternatively, read up on Core Image if you'd like to avoid third-party libraries. See Core Image Programming Guide for more information.
There is absolutely no need for cocos2d which is a game engine.
You can accomplish everything you mentioned using only Objective-C.
If you want real-time effects you will need to dive into OpenGL. you can use GLKit if you target iOS 5 and above.

creating iphone app for existing site. need advice about the data I'm downloading

I'm building an iPhone app for existing site (a local news site)
Main page with articles headers, when click on them you move to the article page. Simple.
This is the first time I'm building such type of app.
I have 3 general questions, just to make sure :
For the iphone, Do we need to
re-create the website article's
pictures for the iphone ? or there
is some programming tool that on the
fly make the files looks better on
the iphone ? or maybe, there is some
technique that creates one artice
picture that looks right both for
the server and the iphone ?
Usually, Do you need to create
special data channels from the
iPhone webservice ? or programmers
just use the existing rss channels
of the webserver ?
If someone know nice artice about
this stuff, It will help a lot. just
see what other are doing.
thanks.
You can see the intent Media apps, these apps are working like what you want your app to.
1) You're better off creating mobile versions of the images. You can do image processing on the iPhone, but you'll have to have the original and that makes the whole thing pointless (ie. you have to download the whole thing.) Generate a mobile thumbnail when those are uploaded on the server.
2) RSS will do. There's a very good tutorial at cocoadevblog.com about approaching such a task (I guess this covers 75% of the work you have to do)
3) Check 2) ;-)
if your download image is bigger the the thumbnail you are trying to display,
then the problem is in your code that change the image size. check carefully what are you doing to the image after downloading it.
I would recommend to create square thumbnails of your pictures at the server level. This will allow you to easily position in the iPhone screen, plus you will not need to download the whole image from the server.
nnahum

Where to find iPhone system buttons and icons graphics?

I'm trying to find a way to use the original Apple system buttons and icons in a web site.
Is there a way to get these original graphics in png format?
There are not-so-nice ways to obtain them of course. Two I was thinking of:
Save them from this link, then convert to png.
Take screen captures on the iPhone itself, and cut the icons from the saved images.
Is anyone aware of a nicer way to obtain the original graphics? Does anyone know where they are stored on the Mac?
Thanks :-)
Ariel
You can download this UIKIT ARTWORK EXTRACTOR project from github and try run it on any simulator , it will extract the all icons of the current SDK and save it to your desktop with all icons.
Source : https://github.com/0xced/UIKit-Artwork-Extractor
Apple HIG Issue: https://github.com/0xced/UIKit-Artwork-Extractor/issues/11
As per the above issue, The extracted appropriate icons can be used in your iphone apps but using it in other platform may cause any copyright issue.
The icons are scatter throughout the system applications they are a part of. There is no central location they can be harvested from. Some of the icon apps might be useful for harvesting them once you find them.
If your interested in UI elements, the Interface Builder bundles have most of them inside.
I know that Graffeltopia has numerous Omnigraffel stencils with Mac system graphics in them.
I think copyright wise, your okay as long as (1) you put a notice that that Apple has the copyright on the images and (2) you don't create the impression you are in anyway Apple Computer and (3) you don't use them to create close simulations of the Apple user interface in any medium.
Otherwise, it follows under fair use. For example, if your doing and article on the Apple UI you can definitely use the graphics in examples.

Displaying Photos on iPhone

I'm working on an iPhone app and I need to be able to display images to users. I have already gotten the code that takes the photo and stores it into the filesystem working well. Now I just need to figure out how to display the image.
I've looked at the Three20 project I've read about on a few of the posts here, but it seems a bit cumbersome and like an extra dependency to import link and combine all of the Three20 library into my little app.
Are there any other ways or a more streamlined library that will let me display photos to my users?
Thanks!
B.
Throw a UIImageView on the screen? Or ask a more specific question if that is not what you want.