PDA

View Full Version : Finding the 10.x.y version of Mac OS X


Jake
2004.11.05, 05:56 PM
is there a cocoa command that can give me the release of Mac OS X the user is using? I need to have two render or three separate paths depending on the version of X, video vendor, and pixel pipelines.

arekkusu
2004.11.05, 06:01 PM
Here's an example of using Gestalt to check the OS version:

long osversion;
if ((Gestalt(gestaltSystemVersion, &osversion) != noErr) || (osversion < 0x1025)) {
// complain about pre-10.2.5 systems
}

Jake
2004.11.05, 06:26 PM
Thanks, works great!