Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

openFrameworks App and XCode tricks

These slides explain how you can add a custom icon to you application you create with XCode. It also shows you how to create a custom executable from an openFrameworks project.

  • Login to see the comments

openFrameworks App and XCode tricks

  1. 1. openFrameworks XCode tricks
  2. 2. Add icon to app First download img2icns from
  3. 3. Add icon to app1. Design your icon in i.e. Photoshop2. Export it to png3. Drag and drop it onto img2icns4. Then click on the “Icns” button, select OF application directory and save the icon into i.e. the project directory.
  4. 4. Add icon to app1. Open XCode 4.0x2. From the menu select: View > Navigators > Project3. Click on the project icon with the name “emptyExample”
  5. 5. Add icon to app4. Click on the ”emptyExample” target and select the “Summary” pane.
  6. 6. Add icon to app5. Drag and drop the icon you exported with img2icns from finder, intoyour project. When you drop the icon, this window pops up. I used thesesettings. The dropped icon will show up in your project panel.
  7. 7. Add icon to app6. Now, drag and drop the icon from your project panelinto the “App icon” area of the “Summary pane”
  8. 8. Add icon to appWhen you dropped the icon, a question mark appears. I think, you seethis question mark because you still need to add a build phase, so letscontinue...
  9. 9. Add icon to app7. Click on the “Build Phases” pane and “Add Build Phase”. Select “CopyBundle Resources”
  10. 10. Add icon to app8. Now, finally, drag and drop the .icns file from your project panel ontothe “Copy files” group which just showed up in your “Build Phases” pane.This will copy the icon to your application bundle.
  11. 11. Add icon to appWhen you click on “Summary” again, you’ll see the iconshowing up where you previously saw the question mark.
  12. 12. Add icon to appYou only need to recompile your application and the icon will be copiedinto the application bundle. You’ll seea nice icon for the application now.
  13. 13. What’s in a nameI’m using a “Run script” to copy the compiled application to a customapplication bundle so I can use my own application names. There mustbe an easier way, but this is a simple and quick solution which works.Note: make sure you first add your icon!
  14. 14. What’s in a name1. Select the “Build Phases” pane, click on “Add Build Phase” and select“Add Run script”
  15. 15. What’s in a name2. Copy and paste this script into the contentsof the “Run script” group you just added. Here we create an applicationwith the name “”. Rename this to you whatever you want. if [ ! -d ] ; then mkdir -p $TARGET_BUILD_DIR/${appname} fi cp -r $TARGET_BUILD_DIR/$ $TARGET_BUILD_DIR/${appname}
  16. 16. What’s in a name2. The “Run Script” will look like this:
  17. 17. What’s in a name3. Recompile and that’s it! Note that this will make a copy of yourapplication.
  18. 18.