OpenGL 3 and Lion question...

Discussion in 'Mac Programming' started by chrono1081, May 21, 2011.

  1. macrumors 604

    chrono1081

    Joined:
    Jan 26, 2008
    Location:
    Isla Nublar
    #1
    Hi guys,

    I know Lion is NDA but I just has a simple question. Does OpenGL 3 currently work on it? I've been learning OpenGL (but a deprecated version) and I'd really like to start learning 3 or higher. I can sacrifice my Macbook Air and run Lion on it to begin learning OpenGL 3 but I'd rather not without first knowing for sure if I can program in it or not.
     
  2. macrumors 65816

    jiminaus

    Joined:
    Dec 16, 2010
    Location:
    Sydney
    #2
    We cannot disclose even this.

    However the answer is in the Mac OS X Technology Overview of the Lion Developer Library. Specifically look in Media Layer > Media Layer Frameworks > OpenGL within that overview guide.

    I hope that doesn't contravine my NDA.
     
  3. macrumors 603

    Joined:
    Sep 19, 2003
    #3
    MacRumors reported a while ago that it supports 3.2.
     
  4. thread starter macrumors 604

    chrono1081

    Joined:
    Jan 26, 2008
    Location:
    Isla Nublar
    #4
    Thanks! I found the document. I may just put it on my air today...I'm still debating since I use my air for a good amount of work too.

    I somehow missed that lol.
     
  5. macrumors Pentium

    KnightWRX

    Joined:
    Jan 28, 2009
    Location:
    Quebec, Canada
    #5
    I'm not under NDA since I'm not part of the Mac Dev program. A simple Google search turned up the code to get a OpenGL 3.2 context on Lion :

    Code:
    #include <OpenGL/OpenGL.h>
    #include <OpenGL/gl3.h>
    #include <stdio.h>
    
    int main(int argc, char **argv)
    {
         CGLContextObj ctx;
         CGLPixelFormatObj pix;
         GLint npix;
         CGLPixelFormatAttribute attribs[] = {
                   kCGLPFAOpenGLProfile, kCGLOGLPVersion_3_2_Core,
                   0
         };
    
    CGLChoosePixelFormat(attribs, &pix, &npix);
         CGLCreateContext(pix, NULL, &ctx);
         CGLSetCurrentContext(ctx);
    
    printf("%s %s\n", glGetString(GL_RENDERER), glGetString(GL_VERSION));
    
    return 0;
    }
    This was posted to some Macrumors discussion a while back.
     
  6. macrumors 65816

    jiminaus

    Joined:
    Dec 16, 2010
    Location:
    Sydney
    #6
    Lion and the Lion developer documentation are only available via the Mac dev program. That makes it Apple Confidential Information according to clause 2.2 of the Mac dev program agreement (10/20/2010). A disclosure (or discussion) by third-parties in contravention to the agreement don't lessen the force of the agreement. Or am I wrong?
     
  7. macrumors 603

    Cromulent

    Joined:
    Oct 2, 2006
    Location:
    The Land of Hope and Glory
    #7
    Yes.

    Because by definition it is not an agreement unless both parties have entered into it. Therefore if you are not a member of the Mac Dev program you are not subject to the NDA.
     
  8. macrumors Pentium

    KnightWRX

    Joined:
    Jan 28, 2009
    Location:
    Quebec, Canada
    #8
    I have never agreed to that so yes you're wrong.
     
  9. thread starter macrumors 604

    chrono1081

    Joined:
    Jan 26, 2008
    Location:
    Isla Nublar
    #9
    Thank you everyone for the replies :)

    I'm still on the fence, I'd love to start learning OpenGL but I'm not sure about giving up one of my machines to a beta os since both my laptop and desktop need to run Unity, Maya, Photoshop, ZBrush, XCode, VMWare, Corona SDK, and Corel Painter. Then again I can always make a disk image and revert back if need be :D
     
  10. macrumors 6502a

    Joined:
    May 10, 2009
    Location:
    Des Moines, WA
    #10
    External USB/FireWire drives are cheap ..., install to one and boot from it leaving your internal drive untouched.
     
  11. macrumors 65816

    jiminaus

    Joined:
    Dec 16, 2010
    Location:
    Sydney
    #11
    I see now. It's not that it's not under the NDA clause of the Mac Dev agreement. It is. It's that you're not part of the Mac Dev program. So you are free to talk, while I am not.
     
  12. macrumors 603

    MorphingDragon

    Joined:
    Mar 27, 2009
    Location:
    The World Inbetween
    #12
    It shouldn't as its a publicly available document provided by the contractor.
     
  13. macrumors 6502a

    Joined:
    Sep 30, 2001
    #13
    I can see some advantage to learning OpenGL 3 on Lion (since you have a full OpenGL 3 implementation available which will simply disallow deprecated functions from being used) but do remember that Mac OS X 10.6 does have most of OpenGL 3 available as extensions.
     

Share This Page