El Capitan (10.11) and PNG transparency with Canvas.Transparent=False

I have a canvas that displays a PNG with transparency. On 10.6 thru 10.10 it works fine. On 10.11 (and 10.11.1 beta) the transparency is not working correctly - some ares of the image seem to be masked with black instead of transparent.

Anyone else seeing this?

I’m using Xojo 2014 R2.1

Have not seen that issue at all but the oldest Xojo version I’m on is 2015 r2.4.

Possibly it’s an issue with the image file itself, do you have a sample we could try out?

Look, I have several images in PNG with transparency and all are working perfectly, I’m with 2015 R2.4

Is your PNG a 24-Bit or 8-Bit PNG?

Does it have a mask or are you using Xojo’s image transparency property?

For creating PNG files, we create a source image in Photoshop, export as 24-Bit PNG, then use our ICNSmini to create a 8-bit PNG from it with optimized transparency. So far I’ve not noticed any issues with El Capitan and PNG images, that said we are facing some weird crashes with some customer installations of El Capitan, which of course do not occur on our installations of El Capitan.

ICNSmini is FREE on the App Store.
https://itunes.apple.com/us/app/icnsmini-shrink-png-icns-iconsets/id1035260885?ls=1&mt=8

[quote=221215:@Michael Diehr]On 10.11 (and 10.11.1 beta) the transparency is not working correctly - some ares of the image seem to be masked with black instead of transparent.

Anyone else seeing this?

I’m using Xojo 2014 R2.1[/quote]

I don’t have issues with png on canvas, but I do see black fragments when I’m painting on a canvas, since El Cap. See this thread:
https://forum.xojo.com/26359-clutter-since-el-capitan-is-installed/p1#p217777

I also use extensively PNG images (with and without transparancy) in canvas and not seen any issues here.

[quote=221215:@Michael Diehr]I have a canvas that displays a PNG with transparency. On 10.6 thru 10.10 it works fine. On 10.11 (and 10.11.1 beta) the transparency is not working correctly - some ares of the image seem to be masked with black instead of transparent.

Anyone else seeing this?

I’m using Xojo 2014 R2.1[/quote]

I have seen that kind of thing under Windows but never under Mac OS X. Could be the way the picture is built. Would you be able to post it for closer examination ?

Sam, just got message that ‘ICNSmini not available in US app store’

FYI

[quote=221359:@Tony Marino]Sam, just got message that ‘ICNSmini not available in US app store’

FYI[/quote]

That seems to be a bug with the app preview page in the browser. It’s trying to open the (iOS) App Store instead of the Mac App Store. If you click the “View In Mac App Store” button on that page it launches the Mac App Store correctly.

I’ve isolated it to the combination of Canvas.Transparent = False with a PNG image with alpha channel. I’ve uploaded a demo project here if you wish to test yourself: <https://xojo.com/issue/41225>

In this particular case, I actually wanted the Canvas to be transparent, so it’s an easy fix for me, but there may be other cases where this isn’t true, and/or it might represent some other deeper bug.

Setting Transparent to False means that the Paint event must fill all of its area with something opaque. This is an optimization that helps reduce the amount of drawing required.

Is that the same as the NSView.opaque setting?

Are you using a mask with your png file (that is, the same pict in b/w colour) ?
On recent Xojo versions, I was forced to add this feature to my picts to prevent a black border around it when clicked.

Yes.

So, you are saying that the behavior change from 10.10 to 10.11 is not a bug?

Correct.