Another data point:<div><br></div><div>For grins,I decided to try building my CALayer code into some other demo that works under 10.6. I chose Ron Garret's scribble demo (attached as xxx.lisp).</div><div><br></div><div>
I simply inserted the call to #/setWantsLayer at line 84. This causes Ron's demo to behave similarly to mine, in that the view is no longer rendered. All you get is a blank window. Comment out that line, and it works as expected. My demo is structured similarly to Ron's and at the corresponding point, I have the same call. </div>
<div><br></div><div>I do see that the mouse events are honored, and the drawRect delegate is called, but nothing appears on the screen.</div><div><br></div><div>I have no idea what that means yet.</div><div><br></div><div>
Neil</div><div><br><br><div class="gmail_quote">On Wed, Aug 25, 2010 at 3:07 PM, Neil Baylis <span dir="ltr"><<a href="mailto:neil.baylis@gmail.com">neil.baylis@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
OK, well I'm pulling my hair over this thing now.
<div><br></div><div>Which leads to my question: Has anyone managed to get anything displayed in a CALayer with Snow Leopard? </div><div><br></div><div>The file is contrib/baylis/ca-demo.lisp, and as has been already noted, it works under 10.5,but not under 10.6.</div>
<div><br></div><div>I have the following data points:</div><div><br></div><div>1. According to Apple, it's now (as of 10.6) possible to assign an NSImage directly to the content of a CALayer. I tried this, and it made no difference. This probably eliminates everything associated with TIFFRepresentation, CGImageSource... etc.</div>
<div><br></div><div>2. I commented out the line that sets the layer content (i.e. (#/setContents: layer ir) ). Instead, I set the layer background to a solid color. Still nothing displayed. This indicates the problem is probably nothing to do with the layer content at all. Rather, it seems as though the layer is never being rendered.</div>
<div><br></div><div>3. Mouse and keyboard events are being processed correctly.</div><div><br></div><div>The missing piece seems to be that for some reason, the CALayer is never rendered. </div><div><br></div><div>I'm running out of ideas. It's not a very complex bit of code after all. </div>
<div><br></div><font color="#888888"><div>Neil</div>
</font></blockquote></div><br><br clear="all"><br>-- <br><a href="http://www.pixpopuli.com">http://www.pixpopuli.com</a><br>
</div>