There may come a time when you need to check your Mac’s version to make sure that your Mac has compatible hardware with certain applications and games, for instance the new release of Angry Birds on the Mac App Store requires OpenGL 2.0 which is not supported on GMA 950 graphics adapters which are used in certain Mac’s. Currently the unsupported Mac’s are as follow:

  • MacBook 1,1
  • MacBook 2,1
  • Mac Mini 1,1
  • Mac Mini 2,1
  • iMac MA710xx/A

In my honest opinion Rovio Mobile failed in a big way on their part by not doing enough testing and ensuring that Angry Birds would run on all devices. Even if they couldn’t get it to run on older Mac’s they should have added specific system requirements.

To check the version of your Mac just follow the quick tutorial below or scroll down for more detailed screen Shots:

  1. Click on the Apple in the upper left part of the screen
  2. Click on About This Mac
  3. Click on More Info…
  4. Under Hardware Overview look for the Model Identifier

Screen Shots:

Let me know if anyone needs any help figuring this out.

I’ve been following the cocos2d community for a while now and discovered that their latest release includes the ability to build your app for OS X. The folks over at cocos2d are trying to make it a simple process to port your iPhone / iPad app over to Mac OS X, probably in preparation of the newly anticipated Mac App Store that we should be seeing soon.

There doesn’t seem to be 100% full support for Mac OS X just yet but the basics are working. You might be asking yourself, how would I go about changing my project to build Mac OS X instead of iPhone? Honestly I haven’t found an easy way, so if someone wants to jump in and help me out I’d appreciate it but for the purposes of this tutorial I will be creating a new App.

Let’s review some of the steps we will need to perform to accomplish this task.

Begin by downloading the latest version of cocos2d here. When the download has completed, go ahead and extract this to a folder on your Mac.

  1. Start a New Cocoa Project
  2. Add Cocos2d Sources to Project
  3. Edit AppDelegate.h & .m files
  4. Import Frameworks
  5. Create a new Objective-C class
  6. Change Settings in Interface Builder for MainMenu.xib
  7. Import sample artwork files

I’d like to add in that I am not stating that this is the best or only way to setup a project with cocos2d to build on OS X and I may have taken some unnecessary steps and may have made a few mistakes. The following is what I did to get it to work for me. If anyone has any suggestions to make this a more accurate or better tutorial, please feel free to let me know.

Start a New Cocoa Project:

First we’ll need to open up Xcode and then start a new project. This time though, instead of starting with one of the pre-defined cocos2d templates we will be using the Cocoa Application template that you should find under Mac OS X -> Application. Please see the screen shot below:

Once you have created a new project you should see the Xcode interface come up. For the purpose of this tutorial I have named my App Demo Mac Port. Your screen should look similar to the screen shot below.

In the next step you will be adding the cocos2d sources to your project, so be sure you’ve downloaded the latest release of cocos2d to be sure you have the version that supports Mac OS X.

Add Cocos2d Source to your Project:

For this step you will need the cocos2d files, if you haven’t downloaded cocos2d yet you can download the latest version here. Once downloaded, go ahead and extract to somewhere on your hard drive.

After you have extracted Cocos2d you will need to navigate to the location on your hard drive where you extracted Cocos2d then open up the cocos2d-iphone-0.99.5-beta3 folder and locate the cocos2d folder. See the screen shot below:

We will need to add this folder to our project. I usually just drag it from the Finder window into the project. Drag the cocos2d folder into your project right under your App name on the very top. A dialog window similar to the screen shot below will pop up.

Click on Add and this will add the required Cocos2d sources to our project. Your Xcode Project interface should look similar to the screen shot below.

The next section will guide you through modifying the AppDelegate.h and .m files.

Modify AppDelegate.h & .m Files:

In this section you will need to modify the AppDelegate.h & .m files to work with Cocos2d. I will not be explaining the code her but I will list the code so you can see what these files should look like.


#import "cocos2d.h"
@class CCSprite;
@interface AppController : NSObject
	UIWindow *window;
@interface Demo_Mac_PortAppDelegate : NSObject  {
    NSWindow *window_;
	MacGLView *glView_;
@property (assign) IBOutlet NSWindow *window;
@property (assign) IBOutlet MacGLView *glView;
#endif // Mac


// Actions Demo
// a cocos2d example
// http://www.cocos2d-iphone.org
// local import
#import "cocos2d.h"
#import "Demo_Mac_PortAppDelegate.h"
#import "DemoScene.h"
#pragma mark AppController - iOS
@implementation AppController
- (void) applicationDidFinishLaunching:(UIApplication*)application
	// 1. Initializes an EAGLView with 0-bit depth format, and RGB565 render buffer
	// 2. EAGLView multiple touches: disabled
	// 3. creates a UIWindow, and assign it to the "window" var (it must already be declared)
	// 4. Parents EAGLView to the newly created window
	// 5. Creates Display Link Director
	// 5a. If it fails, it will use an NSTimer director
	// 6. It will try to run at 60 FPS
	// 7. Display FPS: NO
	// 8. Device orientation: Portrait
	// 9. Connects the director to the EAGLView
	// Obtain the shared director in order to...
	CCDirector *director = [CCDirector sharedDirector];
	// Sets landscape mode
	[director setDeviceOrientation:kCCDeviceOrientationLandscapeLeft];
	// Turn on display FPS
	[director setDisplayFPS:YES];
	// Enables High Res mode (Retina Display) on iPhone 4 and maintains low res on all other devices
	if ([UIScreen instancesRespondToSelector:@selector(scale)])
		[director setContentScaleFactor:[[UIScreen mainScreen] scale]];
	// Default texture format for PNG/BMP/TIFF/JPEG/GIF images
	// It can be RGBA8888, RGBA4444, RGB5_A1, RGB565
	// You can change anytime.
	[CCTexture2D setDefaultAlphaPixelFormat:kCCTexture2DPixelFormat_RGBA8888];
	CCScene *scene = [CCScene node];
	[scene addChild: [nextAction() node]];
	[director runWithScene: scene];
// getting a call, pause the game
-(void) applicationWillResignActive:(UIApplication *)application
	[[CCDirector sharedDirector] pause];
// call got rejected
-(void) applicationDidBecomeActive:(UIApplication *)application
	[[CCDirector sharedDirector] resume];
// application will be killed
- (void)applicationWillTerminate:(UIApplication *)application
// sent to background
-(void) applicationDidEnterBackground:(UIApplication*)application
	[[CCDirector sharedDirector] stopAnimation];
// sent to foreground
-(void) applicationWillEnterForeground:(UIApplication*)application
	[[CCDirector sharedDirector] startAnimation];
// purge memory
- (void)applicationDidReceiveMemoryWarning:(UIApplication *)application
	[[CCDirector sharedDirector] purgeCachedData];
- (void) dealloc
	[window release];
	[super dealloc];
// next delta time will be zero
-(void) applicationSignificantTimeChange:(UIApplication *)application
	[[CCDirector sharedDirector] setNextDeltaTimeZero:YES];
#pragma mark AppController - Mac
@implementation Demo_Mac_PortAppDelegate
@synthesize window=window_, glView=glView_;
- (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
	CCDirector *director = [CCDirector sharedDirector];
	[director setDisplayFPS:YES];
	[director setOpenGLView:glView_];
	// Enable "moving" mouse event. Default no.
	[window_ setAcceptsMouseMovedEvents:NO];
	[[CCDirector sharedDirector] runWithScene: [DemoScene scene]];

Within the applicationDidFinishLaunching method you will notice the [[CCDirector sharedDirector] runWithScene:[DemoScene scene]]; line.  This line specifies the Scene we want our project to start with. In the next section I will list some more code for a new Objective-C class.

Create a New Objective-C Class:

At this point we will need to create a new Objective-C class. Right click on the Classes group within your Xcode Project interface and click on Add -> New File. You will be presented with a dialog similar to the following.

Click on Next and you’ll be presented with the next dialog.

I’ve named my class, DemoScene.m be sure the check mark to create DemoScene.h file is checked. Click on finish, you should now see your new class files in your Xcode project interface. Below you will find the code you should put into these 2 files. If you are familiar with Cocos2d, then the code below should look familiar to you.


//  DemoScene.h
//  Demo Mac Port
//  Created by Chris Fletcher on 10/24/10.
//  Copyright 2010 __MyCompanyName__. All rights reserved.
#import "cocos2d.h"
@interface DemoSceneLayer : CCLayer {
	CCDirector *Director;
@interface DemoScene : CCScene {
	DemoSceneLayer *_layer;
@property (nonatomic, retain) DemoSceneLayer *layer;


//  DemoScene.m
//  Demo Mac Port
//  Created by Chris Fletcher on 10/24/10.
//  Copyright 2010 __MyCompanyName__. All rights reserved.
#import "DemoScene.h"
@implementation DemoScene
@synthesize layer = _layer;
+ (id)scene {
	CCScene *scene = [CCScene node];
	DemoSceneLayer *layer = [DemoSceneLayer node];
	[scene addChild:layer];
	return scene;
- (id) init {
	if ((self = [super init])) {
		self.layer = [DemoSceneLayer node];
		[self addChild:_layer];
	return self;
@implementation DemoSceneLayer
- (id)init {
	if ((self = [super init])) {
		CGSize winSize = [CCDirector sharedDirector].winSize;
		CCSprite *starBG = [CCSprite spriteWithFile:@"starbg.png" rect:CGRectMake(0, 0, 960, 640)];
		starBG.position = ccp(winSize.width/2, winSize.height/2);
		[self addChild:starBG];
	return self;
-(void) dealloc {
	[super dealloc];

As you can see from the code above, we are simple creating an Interface and Implementation for a layer and a scene and then adding a CCSprite to the layer. This is very simple Cocos2d functionality but should be enough code to get you started.

We can’t Build & Run the project just yet. We have a few things left to do, mainly importing some frameworks & images and then making some changes in Interface Builder. The next section will cover the frameworks we will need to import.

Importing Additional Frameworks:

In this section of the tutorial I will cover which frameworks we will need to add to our project and how to add them. The frameworks we will add are as follows:

  • QuartzCore.framework
  • OpenGL.framework
  • ApplicationServices.framework
  • libz.dylib

To add a framework to our project, right click on Frameworks and then  Add -> Existing Frameworks. You will be presented with a dialog similar to the following screen shot.

Find the QuartzCore.framework and click Add, then right click on Frameworks and then Add -> Existing Frameworks and find the OpenGL.framework and click Add. Repeat these steps for the ApplicationServices.framework and the libz.dylib.

When you are done adding all of the frameworks your Xcode Project interface should look similar to the screen shot below:

At this time all we have left to do is is import some images and then make some Interface Builder changes. This is turning out to be a pretty lengthy tutorial but I promise we are almost at the end. In the next section I will quickly cover the images that need to be added.

Add Images To Our Project:

The code in the DemoScene.m file uses a CCprite that uses an image named starBG.png. You can download this image from the link below:


  Star Background (1.3 MiB, 1,656 hits)

The Cocos2d source requires that an image called fps_images.png exists in our resources folder to render the FPS image that you are used to seeing on the bottom left hand corner. You can find this file in the Cocos2d/Resources/fonts folder within the extracted folder from the cocos2d sources.

When you have both files located, drag them into the Resources folder of your Xcode project.

At this point we have done all that is required within our Xcode Project, the only thing left to do is to make some changes and additions to our MainMenu.xib file within interface builder.

MainMenu.xib & Interface Builder:

Go ahead and locate your MainMenu.xib file inside of your Xcode Project interface. It should be located inside of your Resources folder. Double Click on MainMenux.xib, this should launch interface builder.

After Interface Builder has launched, the first thing I like to do is resize the window to what the size of my application will be. For simplicity I will set the size of my window to 960×640 since I already have all of my images created at that resolution to support the iPhone 4.

After you have resized your window to 960×640, it should look similar to the following screen shot.

While we have focus on the window lets make a quick change. You will need to change a setting in the Window Attributes. At the bottom find the check mark for One Shot and uncheck this box. See the screen shot below:

After changing the size of the window and unchecking the One Shot mode we need to add an OpenGL View to our window. In your Library scroll down until you see OpenGL View. Select this and drag it onto your Window. You should now see something similar to the screen shot below:

Go ahead and resize the OpenGL View to the size of the window. Your resulting window should look similar to the screen shot below:

Now that we have our window and our OpenGL view resized to 960 x 640 we will need to make some changes to the OpenGL View. First, you’ll want to change the Class to MacGLView. With the OpenGL View selected go to the Identity tab and change the class name to MacGLView. See the screen shot below:

Next, click on the Attributes tab and make the changes as in the provided screen shot below:

After you have finished making the changes above, we will need to make one final change. We need to create a link to the glView outlet in our AppDelegate to the OpenGL View, so drag a connection from glView to OpenGL View. You can reference the screen shot below:

Now we are done with Interface Builder so go ahead and save and then exit Interface Builder and go back to your Xcode Project. At this point we have everything setup to properly run a cocos2d app on Mac OS X. You should see your app start up and it should look similar to the following screen shot.

Congratulations, you now have the basic building blocks to create / port your app for Mac OS X. I’ve tried to be as thorough  as possible when creating this tutorial and I am hoping that I didn’t miss anything. You can download a working project which includes everything from this tutorial below.


  Demo Mac Port (6.9 MiB, 1,892 hits)

Was this tutorial useful? Have you used this tutorial to create a Mac App using Cocos2d? I’d like to hear stories

So… you’ve installed the latest SDK and XCode from Apple’s developer site only to find out that the only base SDK’s you are left to develop with are 3.2 and 4.0. What about if you have an iPhone 2G as your only development device? The iPhone 2G only goes up to iOS 3.1.3 and if you are stuck with the lowest base SDK of 3.2, you will not be able to push your apps to your iPhone.

This is exactly what happened to me. I downloaded the beta SDK for the 4.0 iOS when it came out. Little did I know that when you install that, it removes all SDK’s prior to 3.2.

Luckily for us, Apple is kind enough to keep previous versions of Xcode and their SDK’s available for download. Here is a list of available downloads.

You have to be logged into the Apple developer site http://developer.apple.com to download the above listed SDK’s. I downloaded the 3.1.3 Snow Leopard SDK since I already have 3.2 and 4.0 and 3.1.3 includes all of the above mentioned SDK’s as well as 2.0 and 2.1.

Once you’ve downloaded the SDK of your choice it should be in the form of a DMG, go ahead and mount that and open up the resulting volume. You should get something that looks like the image below.

iPhone SDK Volume

iPhone SDK Volume

At this point you will need to open up the Packages folder rather then running the installer because all we want are the SDK’s. When you open up the Packages folder scroll down a bit until you see the SDK’s. You should see something similar to the screen shot below.

Packages Folder

Packages Folder

You’ll see that there are device SDK’s and simulator SDK’s. You don’t have to install the simulator SDK’s if you don’t want to because all we are really after here is to be able to push our apps to an iPhone with an iOS earlier then 3.2. Double click on one of the iPhone SDK’s and you will be presented with an installer screen like the one below.

iPhone SDK Installer Screen

iPhone SDK Installer Screen

Click on Continue and and you will get to the next screen similar to the one in the screen shot below

iPhone SDK Installer Screen

iPhone SDK Installer Screen

On this screen you need to click on the drive you want to install the SDK to. In most cases it will be your primary Hard Drive. If you have your Developer tools installed on a different drive then you should select that one instead. Next you need to click on Choose Folder and you will be presented with a Choose Folder dialog similar to the screen shot below.

Choose Folder Dialog

Choose Folder Dialog

If you are like me and installed Xcode in the default location then you should have a developer folder in the root of your Hard Drive. Click on the Developer folder and then click choose. You will see a screen similar to the one below.

iPhone SDK Installer Screen

iPhone SDK Installer Screen

You can verify on this screen that you’ve selected the proper folder. It should have a blue circle around the Hard Drive and if you’ve picked the Developer folder it should say the following on the bottom “You have chosen to install this software in the folder Developer on the disk Macintosh HD. Click Continue and you will be presented with a screen similar to the below screen shot.

iPhone SDK Installer Screen

iPhone SDK Installer Screen

This is just a confirmation screen, from here you just need to click on Install. You may be prompted with a password screen. Enter your password to continue with the installation. You should see a screen similar to the one below.

iPhone SDK Installer Progress Screen

iPhone SDK Installer Progress Screen

Depending on the SDK you are installing this part can take up to 5 minutes to complete. When the installation is done you will be presented with a screen similar to the one below.

iPhone SDK Install Complete

iPhone SDK Install Complete

Click on close. At this time your installation of the SDK is complete. You can verify that the SDK installed successfully by launching Xcode. Once Xcode is launched open an existing project or start a new one and go to Project -> Project Settings. You should see a screen similar to the below screen shot.

Xcode Project Settings - General

Xcode Project Settings - General

Click on the drop down towards the bottom where you can choose your base SDK and if all went well you should see a screen similar to the below depending on which SDK you installed.

iPhone SDK's

iPhone SDK's

Pick your SDK of choice and enjoy. Hopefully this tutorial has helped someone with their project. I spent many hours the other night researching how I could install older version SDK’s and once I found an easy method I thought I would share it with the rest of the world. If for some reason you don’t see your SDK listed here then it may have been installed in the wrong folder. If you can’t get it working feel free to ask me for help. I’m always willing to help out a fellow developer.

Well, I’m at it again, after developing the ISOx360 and Wii Tools, I thought about what else might be a useful tool for all of the fellow Mac OS X users out there. One thing that came to mind was that most of the HD content that can be found on the internet is usually in MKV format.

I wont cover the MKV format in-depth, just know that it is a container and not a codec, similar to how an AVI can be encoded as a divx or an xvid, an MKV file can use many different codecs. Most commonly MKV files contain the H.264 / X.264 codec for Video and the DTS / AC3 codec for audio.

The other thing you need to know about MKV files and HD content is that a typical 720P MKV file using an H.264 codec has a max bit-rate of about 9000, currently the AppleTV can only support 720P content with a Video bit-rate of up to 5000. If this limitation didn’t exist we could easily transcode the file to an MP4 / M4V container, but because of the Video limitation, we need to re-encode the file at a lower bit-rate. Don’t worry about quality, I haven’t seen any noticeable decrease in quality when re-encoding.

So, enough with the tech talk, you’re probably wondering, the title of the post is Convert MKV to MP4 on a Mac, so I’ll get on with it. The application that I’ve developed makes this an easy 1 step process. You load the MKV file, choose a save location for the new MP4 file, pick a few options and click convert. When its done, you can copy the MP4 file to your AppleTV / iTunes and enjoy great quality HD content.

Note: My application will also remove subtitles and convert any DTS audio track to AC3 so that you can keep all the surround sound. The thing is, to enjoy the surround sound, you’ll have to use the optical output on your AppleTV and have a receiver that can correctly decode the audio, along with a nice set of surround sound speakers.

You can download a trial of the application below, it will work exactly 10 times before it is rendered useless at which point you will have to purchase it, but don’t worry I kept the price cheap, only $14.95.

Download :

  Click to Download the MKV2AppleTV Trial (9.4 MiB, 1,961 hits)

Click to Purchase an MKV2AppleTV License

At the request of one of my readers, I am making a short tutorial on how to burn activate.iso on Mac OS X. This is a fairly simple process, however I will cover it in as much detail as possible.

Tools Needed:

The activate.iso file ( Download )
Disk Utility (  Applications -> Utilities -> Disk Utility )
A Blank Dual Layer DVD

The Tutorial:

Download the activate.iso file from the above list of tools. Once downloaded, you need to extract it, since it will be in a compressed zip format.

Open Disk Utility ( Applications -> Utilities -> Disk Utility ) – you should see a screen similar to the below

Disk Utility

Disk Utility

Click on Burn, you will see a browse window similar to the image below, browse to the location where you downloaded and extracted the activate.iso file. Highlight activate.iso, then click on Burn.

Disk Utility - Browse

Disk Utility - Browse

After clicking on Burn, the browse dialog will disappear and you will see a new window, similar to the following image. At this point you will need to insert your disk. When Disk Utility recognizes that a blank dual layer disk has been inserted, it will enable the Burn button. All you need to do now is click Burn.

Disk Utility - Burn

Disk Utility - Burn

After the burn has completed you will most likely need to reboot your Mac to remove the disk since for me anyway OS X did not recognize that there was a disk in the drive after the burn completed and therefore did not let me eject the disk while I was in the operating system. So what you need to do is reboot your Mac and eject the disk using the eject button before your Mac boots back up completely.

So that’s it for the tutorial, nothing special, just use good old Disk Utility to burn and you’re all set.

I recently acquired a white G3 eMac with a 17 inch screen and thought it would be perfect to put into my daughters room. Unfortunately the eMacs didn’t come with built in airports, so no wireless. I looked around online for wireless cards that would work with a Mac and found that they are quite expensive.

Instead of purchasing a wireless adapter online, I went to Wal-Mart and bought a Belkin Wireless USB adapter. After getting home and opening the box, I noticed that there are no Mac drivers on the included CD, furthermore after searching Belkin’s website returned no results for any available Mac drivers for this particular adapter.

After some more searching on google, I found a few sites with drivers for this card for a Mac, but only to find out that there are multiple versions of this particular card. You can use the version matrix below to determine your version.

Version 1 – FCC ID = K7SF5D7050
Version 2 – FCC ID = K7SF5D7050A
Version 3 – FCC ID = K7SF5D7050B
Version 4 – FCC ID = RAXWN4501H
Version 5 – FCC ID = K7SF5D7050E

This article will cover installing Version 4 of the F5D7050 adapter. Although, I will also be listing available drivers for Versions 1, 2, and 3. The Version 4 driver may also work for the Version 5 adapter, although this has not been tested, and if anyone tries and succeeds, I would appreciate a comment to let everyone know.

F5D7050 Version 1 & 2 Mac Driver
F5D7050 Version 3 Mac Driver
F5D7050 Version 4 Mac Driver

Each of these drivers is installed in much the same way, there is an install file that you run and then restart the Mac when the install has completed. After the Mac restarts you have to click on System Preferences and click on Network. You’ll receive a pop-up dialog alerting you that a new network device has been detected. Apply the change and then start the wireless utility if it hasn’t been started already. Scan for wireless networks, when your network has been found, connect to it.

That’s all there is to it. The install is very simple and straight forward. If anyone has any input / advice, feel free to post for others to read.

This was giving me a problem some days ago so I thought I’d write up a quick tutorial on how to shrink dmg files on a mac. Why would you want to do this ? Well lets say you are creating an application and you want to package it in a DMG so you open up Disk Utility and create a blank image. Well you can only choose certain sizes. Most of us would choose a 40MB image so we have plenty of initial space to work with.

As far as I know there are 2 methods for shrinking the dmg down to the size of its contents, they are listed below.

Method – 1:

  • Right Click on the DMG
  • Click Compress

This will generate a zip file down to the actual size of the content of the DMG since free space has 100% compression ratio.

Method – 2:

This method involves the use of the Terminal App which can be found under Applications -> Utilities -> Terminal

  • Launch Terminal
  • Type the following hdiutil resize -size 10M /Path/To/DMG/DMG_Name.dmg

Code Breakdown:

  • hdiutil – A utility that comes preinstalled with Mac OS X, that manipulates disk images, etc…
  • -size – An argument passed to hdiutil, indicating that you want to change the size of an image.
  • 10M – means I am changing the dmg size to 10 Megabytes, insert your own value here.
  • The rest should be self explanitory

So there you have it, 2 methods to resize your dmg in Mac OS X. Thanks for reading.

If anyone would benefit from having a little GUI App that resizes DMG’s let me know, if I receive enough requests, I might make one and post it here.