The PhotoAppLink library story

Email This Post Email This Post

Launching

Today is the day os the official launch of the PhotoAppLink library. The library is a joint effort of me and Hendrik Kueck from PocketPixels, maker of the ever top selling ColorSplash. We have a website if you want to know the latest about this. This post is to tell the story behind this.

The problem

Since the first version of my first iPhone camera app, Snap, I wanted my users to be able to share their annotated images with as many services as possible. I did the obvious: Twitter, Facebook, Tumblr and I still want to add more to this list.

But one thing was still not possible: how could I share the images with another app? How can I send an image from Snap to Instagram so that users can apply some filters and share? How could I send it to AppX so that users could add filters, frames and a lot more that AppX might offer?

And also the other way around. What if a user takes a picture with AppX and wants to add some text on top of it? AppX might not offer this, but Snap does. Wouldn’t it be nice if AppX could open Snap with an image, Snap could add notes to it and then send the result back to AppX? There is just no way of doing this. Or at least not until right now.

The proposal

What I wanted (you’ll understand the past tense in a moment) to propose was really quite simple, but quite ingenious (or so I thought).

The iOS API allows us to Implement Custom URL Schemes. I wanted every camera or image processing app to implement a custom URL scheme so that we can all exchange images with each other.

So I hashed up a way to Base64 encode an image and send it to another app using these custom URL schemes. It worked well in some tests so I wrote a library and started sharing it with some top devs in the photography section of the app store.

Some people didn’t even respond, but Hendrik Kueck from PocketPixels, maker of the ever top selling and very fun ColorSplash responded telling me he had a similar idea over a year ago (and I thought my idea was so original…) but he didn’t get a lot of people on board so he kinda forgot about it.

He sent me his code and I think my email made him regain his enthusiasm so we decided to iron out a few missing things in the library that would make adoption much easier and try to get more people on board.

So when I checked his library I saw that his idea, even tough it was using custom URL schemes, was to use a custom pasteboard to pass data around from one app to the other. WAY better than Base64 encoding everything. What a revelation that was.

So I threw away most of my code and ported my app to use his code in about an hour. It’s called PhotoAppLink (mine would be called iOSImageShare, even his name is better… damn….) and he even registered a domain for it.

How does it work?

There’s a Readme file with code and a step by step tutorial on how to implement this into your app but first let me explain how it works. It’s really very simple.

When you want to send an image to another app, we just create a custom pasteboard with a common name and paste the image NSData (jpeg encoded to a very high quality) to this pasteboard. We then open a custom url registered by another app.

The system then opens this other app that knows is being called to open a custom url. The app checks the shared pasteboard, gets the image from there and then… well, that’s up to the app. In the case of Snap, I’ll open the annotation screen so that the user can add notes. In ColoSplash it will open the app and prepare it for processing just as if you were getting an image from your Camera roll.

So, all very simple, right? Well, if you’re paying attention there’s one thing that’s missing here: how do I know what URL to open?

Who wants to play?

Share01

So, you decided to implement PhotoAppLink on your “soon to be the best” camera app but you feel lonely. You don’t really know to what other apps you can send your images to. Well, not to worry my friendly app, we got a solution for you.

We will host a plist on our photoapplink.com website called photoapplink.plist. This file will contain information about all compatible apps. If you implement PhotoAppLink in your app you just have to send us an email about it with all your info and we’ll add your app to this file.

Our library then simply downloads this file and uses UIApplication’s canOpenURL: to check if the app is installed. The library will also download all the compatible apps’ icons (and cache it) automatically on the background.

When your user wants to send a picture to another app you can use an UIViewController from the library that handles everything, from showing compatible apps to sending your image.

But if you don’t like the interface we built or if it doesn’t fit your app, no problem. The library can provide all the information about compatible apps so that you can build your own interface. Or just change the interface we provide to fit your app.

That’s it?

Moreapps

Well, not quite. If you’re still not convinced that implementing this in your app was a good idea I think this will make you change your mind.

When we present a list of compatible apps to the user we can check what apps the user has installed but we also now have a bunch of apps that the user does not know about. So, in our UIViewController we have a button for “More apps”. This button will present a list of all the compatible apps the user still doesn’t have in a nice table with a nice button to get the app.

This button will open the AppStore app so the user can get this app immediately! AND it uses a link with your Linkshare site ID so you even get a commission on the sale.

So, your app can get more revenue selling other apps AND your app can now be discovered by users of other PhoneAppLink compatible apps. How cool is this!!!!!

And, again, if you don’t like our interface, just change it or roll your own using the information gathered by the library.

Let’s play?

Convinced? Great. There’s a very quick tutorial on how to implement PhotoAppLink in your app. It will take you about an hour if you use the controls we provide there and there’s a test app you can use to test interaction with your app. The whole process should not take more than 4 hours, with testing!

Check it out and let’s start playing together!

Arthritis in neck chiropractic treatment arthritis in neck chiropractic treatment. Hemorrhoids shoppers hemorrhoids shoppers. Human growth hormone tablets human growth hormone tablets. Release of growth hormone release of growth hormone. Psoriasis shot treatment psoriasis shot treatment. Webcam with gay webcam with gay. Hoodia sesriem hoodia sesriem. Diets help fibroids diets help fibroids. Throat pain tinnitus throat pain tinnitus. Cam male 4 cam male 4. Excessive sweating homeopathy excessive sweating homeopathy. Man boobs reduce man boobs reduce. Dating websites for herpes dating websites for herpes. Macau dating site macau dating site. Perspiration odor removal wool perspiration odor removal wool. Tabletten gegen tinnitus tabletten gegen tinnitus. Ringing in ear treatment ringing in ear treatment. Chubby gay webcam chubby gay webcam. Webcam transex webcam transex. Easy songs for the piano easy songs for the piano. Candida albicans in stool treatment candida albicans in stool treatment. Treatment for thumb arthritis treatment for thumb arthritis. Stop makeup sweating off stop makeup sweating off. Online piano tutorials online piano tutorials. Psoriasis treatment india dr batra psoriasis treatment india dr batra. Chronic hair loss treatment chronic hair loss treatment. Maximum dosage metformin pcos maximum dosage metformin pcos. Products like duromine products like duromine. Vegan diets weight loss vegan diets weight loss. Yoga helps fibroids yoga helps fibroids. Transvestite webcam transvestite webcam. Magical slimming capsule magical slimming capsule. Natural medicine uterine fibroids natural medicine uterine fibroids. Straight men cam straight men cam. Acai 3000 free trial acai 3000 free trial. Natural remedy for ovarian cyst pain natural remedy for ovarian cyst pain. Natural remedy for bv natural remedy for bv. Homeopathic remedy for ovarian cyst homeopathic remedy for ovarian cyst


Keep tuned for more technical and non technical posts. You can subscribe by email, RSS or following me on twitter.


Email This Post Email This Post
  • Pingback: iPhone developers create solution to simplify multi-app photo-editing | Gadgetoxic - Toxify your tech life

  • AndreasLoew

    Hi,

    this is not meant as post… just wanted to contact you.
    Found your post on ray wenderlich’s blog. 
    Are you interested in a free version of TexturePacker and PhysicsEditor?

    Cheers
    Andreas

  • Marta Jablonska

    Hello,My name is Marta Jablonska and I am an assistant of Hakin9 Magazine editor – the only publication devoted to IT Security. In our magazine we publish most recent hacking and protection techniques and tools and latest trends in IT Security.Currently we are looking for authors who could provide us with some interesting articles or tutorials about hacking iOS. I’m wondering if you would like to write for us.I hope you are interested and want to hear more details.Please do not leave me without an answer.Hope to hear from you soon.
    My e-mail: marta.jablonska@software.com.plWarm Regards,Marta JablonskaP.S. Have a look at our website: http://hakin9.org/

  • Pingback: PhotoAppLink « Under The Bridge

  • Anonymous

    I have downloaded & will hopefully implement in my new photo app.
    Interested on how to test the website plist but assume that’s covered in the demo so will look when I reach that stage.

    cheers

    Ian aka sundialSoft