Skip to content

Instantly share code, notes, and snippets.

@soffes
Created February 28, 2009 22:28
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save soffes/72132 to your computer and use it in GitHub Desktop.
Save soffes/72132 to your computer and use it in GitHub Desktop.

Created by Steven Degutis

www.degutis.org

How To Use

  1. Add PhotoTaker.Framework to your Cocoa project by dragging it into your Frameworks group, adding a Copy Files build phase to your Target, and dragging the Framework from the group to that Copy Files phase.
  2. Create an instance of SDPhotoTakerSheetController
  3. Create an object that conforms to SDPhotoSheetDelegate. It must contain one and only one method - (void) capturePhotoSheetController:(SDPhotoTakerSheetController*)sheetController didAcceptPhoto:(NSImage*)image
  4. Use - (void) beginCaptureSheetWithWindow:(NSWindow*)mainWindow delegate:(id<SDPhotoSheetDelegate>)newDelegate
  5. Now celebrate, have a drink, you did well, and you're all done.

Giving Credit

If you use this code, I would appreciate it if you added me to the credits, with a link to my website. Preferred format is

Photo Taker created by Steven Degutis - www.degutis.org

Services

You can also find my video tutorials and other resources on how to learn programming for the Mac and iPhone, at www.TeachMeCocoa.com

I am available for contracting work, check out my site at hire.degutis.org.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment