Layer Backed OpenGLViews freezing or not rendering correctly in Lion

Number:rdar://9948466 Date Originated:2011-08-12
Status:Open Resolved:
Product:Mac OS X Product Version:10.7
Classification:Crash/Data Loss Reproducible:Always
12-Aug-2011 07:01 PM Eric Wing:
'Screen Shot 2011-08-12 at 6.51.21 PM.png' and 'Mac mini.spx' were successfully uploaded

12-Aug-2011 07:01 PM Eric Wing:
I tried to enable layer backing on the OpenGL view from the developer example and it causes my computer to hang/freeze and I must hard reboot.

Steps to Reproduce:
Download the GLEssentials project from the Apple sample code online.
Go to the Nib and change the opengl view so it is Core Animation layer backed.
Build and run the example.
It hangs my computer and I must reboot. (Only tried on my Mac Mini...config attached)

Additionally, I tried the Layer Backed OpenGL View example from the Sample code. It is not rendering correctly. The picture should look like Earth, but it looks more like a wire-framed sphere, but it isn't wireframe. (There is a checkbox to enable wireframe which looks different.) Screenshot is also attached. 

Expected Results:
Should not freeze.

Actual Results:


I tested the Layer Backed OpenGL view example on both a Mac Mini and Macbook Air 11" (first gen). Both produced the same image.


I have a same problem. I also found out that when I turn on layer backing using [self setWantsLayer:YES], the OpenGL version changed back to old 2.1 although I requested version 3.2. It seems layer backed OpenGL requires hardware accelerated renderer but my system only can provide Apple software renderer for OpenGL 3.2. Strangely NSOpenGLPixelFormat still returns non-nil pixel format object although the requested renderer can not be found. This confuses the app by believing it found a valid OpenGL 3.2 renderer although in reality only the old OpenGL 2.1 is provided. I believe the app crashes since it tries to issue OpenGL 3.2 commands to OpenGL 2.1 renderer.

By yoshida.t.khi at Jan. 13, 2013, 8:53 a.m. (reply...)

Image link

Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!