Voices That Matter

Archive for June, 2009

iPhone Developer Tips Stats:
Past 30 days - Pageviews: 88,766 Visitors: 61,679
Thank you everyone! Let's shoot for 100,000 by May. Pass it on...



Silent Mode Switch and Playing Sounds

In a previous tip, Playing Short Sounds, I wrote an example to show how you can play a short sound, up to 30 seconds, by calling one of the C-based functions in the Audio Session Services library.
There is one aspect of this that can be troublesome – by default, playing an Audio Session sound [...]

Audio

iPhone SDK 3 and Deprecated Method Warnings

A side-effect of developing code on platforms that continue to evolve, is dealing with methods that become deprecated from one release to another. If you’ve spent anytime at all with Java, you are all too familiar with this concept. With the release of the iPhone SDK version 3.0, a number of methods have been become [...]

Cocoa

Snoop Dogg App on the iPhone – iFizzle

I recently completed an iPhone application for Snoop Dogg. Check this out: Snoop did a demo of the application on the Tonight Show with Conan O’Brien.

If you interested to learn more about the app, or have an idea for something similar you would like developed, drop me a note. You can also visit 3 [...]

Announcements

Playing Sounds/Audio – Audio Session Services

If you need to play short sounds, less than 30 seconds, Audio Session Services are your friend. Here is a snippet of code to play a wav file:

SystemSoundID soundID;
NSString *path = [[NSBundle mainBundle]
pathForResource:@"RapidFire" ofType:@"wav"];
 
AudioServicesCreateSystemSoundID((CFURLRef)[NSURL fileURLWithPath:path],&soundID);
AudioServicesPlaySystemSound (soundID);

Audio

Xcode, Folders and the File System – Part 2

In Part 1 of Xcode, Folders and the File System I walked through a short example on how to import folders into Xcode such that resources within a project have a folder structure that matches the file system.
In this post I will show you two ways to access the imported resources, one by specifying a [...]

Xcode

Xcode, Folders and the File System – Part 1

Xcode provides a built in mechanism for organzing content within a project (control-click or right click -> Add -> New Group). For example, in the image below, I’ve created a number of groups for separating the primary functionality of an application into model classes and views.

Although this is nice, for the most part the [...]

Xcode

UIColor Macros

Below are two macros I paste inside every new iPhone project. Besides saving a few keystrokes, they work well when using the color picker application. Let’s look at the macros first:

#define RGB(r, g, b)
[UIColor colorWithRed:r/255.0 green:g/255.0 blue:b/255.0 alpha:1]
#define RGBA(r, g, b, a)
[UIColor colorWithRed:r/255.0 [...]

Cocoa

Finding the Xcode Project File in a Folder

This barely qualifies as a tip worthy of publishing, however, it’s something I use regularly so I figured it’s worthwhile passing on.
I’ve been working with some monster projects as it relates to content. What that translates to is really long lists of files inside of Finder. Since I bounce between a handful of projects over [...]

Xcode