Community
Participate
Working Groups
Created attachment 279259 [details] code The input file is a png with transparent background. The transparent area turns into black if I invoke getImageData on the image first. I am running on OSX in Dark Theme, Eclipse 2019-06. The problem is not found in 2019-03.
Created attachment 279260 [details] png
Is this a regression in 4.12?
It only happens in 4.12 not in 4.11 or earlier versions. In my example, I am invoking getImageData() before the paint. In reality, I am calling getImageData in a much later time. The problem shows up on the next repaint, whenever that is.
Sravan, can you please investigate?
I don't have access to Mac today. I will look into this tomorrow
This is a regression in 4.12. I have a fair idea on where the problem could be. I will work towards fixing the problem
Created attachment 279307 [details] screenshot of problem seen in eclipse I also see this in the Eclipse IDE.
The problem is this file https://git.eclipse.org/c/platform/eclipse.platform.swt.git/tree/bundles/org.eclipse.swt/Eclipse%20SWT/cocoa/org/eclipse/swt/internal/graphics/ImageUtil.java Here we create a new image rep for required size but this code is not able to handle images with alpha/transparency. This is resulting in black colour where it should have been transparent. @Till, Can you please suggest how we can improve this method to handle alpha?
(In reply to Sravan Kumar Lakkimsetti from comment #8) > @Till, > Can you please suggest how we can improve this method to handle alpha? Create a rep with hasAlpha=true (and samplesPerPixel=4) if any of the existing reps has alpha. It looks like NSAlphaFirstBitmapFormat | OS.NSAlphaNonpremultipliedBitmapFormat doesn't work (at least on macOS 10.14) with hasAlpha=true, so I'd try with a value of 0 instead.
(In reply to Till Brychcy from comment #9) > (In reply to Sravan Kumar Lakkimsetti from comment #8) > > @Till, > > Can you please suggest how we can improve this method to handle alpha? > > Create a rep with hasAlpha=true (and samplesPerPixel=4) if any of the > existing reps has alpha. > > It looks like NSAlphaFirstBitmapFormat | > OS.NSAlphaNonpremultipliedBitmapFormat doesn't work (at least on macOS > 10.14) with hasAlpha=true, so I'd try with a value of 0 instead. Thanks Till. It worked. I will put in a patch shortly
New Gerrit change created: https://git.eclipse.org/r/146338
Gerrit change https://git.eclipse.org/r/146338 was merged to [master]. Commit: http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/?id=94e3dd2e453b92538d63a927db1cf02005f959e8
(In reply to Eclipse Genie from comment #12) > Gerrit change https://git.eclipse.org/r/146338 was merged to [master]. > Commit: > http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/ > ?id=94e3dd2e453b92538d63a927db1cf02005f959e8 This partially fixes the problem. There is still problem in the image copy and this can be seen in this example https://bugs.eclipse.org/bugs/attachment.cgi?id=195741 from bug 310387
(In reply to Eclipse Genie from comment #12) > Gerrit change https://git.eclipse.org/r/146338 was merged to [master]. > Commit: > http://git.eclipse.org/c/platform/eclipse.platform.swt.git/commit/ > ?id=94e3dd2e453b92538d63a927db1cf02005f959e8 The problem described here has been fixed by the above commit.
*** Bug 549780 has been marked as a duplicate of this bug. ***
It looks like this bug is still not fixed in 2019-09. Please see details in this report. https://bugs.eclipse.org/bugs/show_bug.cgi?id=551605
(In reply to Wim Jongman from comment #16) > It looks like this bug is still not fixed in 2019-09. Please see details in > this report. > > https://bugs.eclipse.org/bugs/show_bug.cgi?id=551605 This problem is more related to bug 310387. Is it possible for you test the patch attached to Bug 310387? Thanks Sravan
Could someone provide some instructions on what I need to do in order to download and apply this patch. I'm running MacOs Mojave and Eclipse 2019 09 Sorry - not done any kind of patching on Eclipse before Dave
(In reply to Dave Garratt from comment #18) > Could someone provide some instructions on what I need to do in order to > download and apply this patch. > > I'm running MacOs Mojave and Eclipse 2019 09 > > Sorry - not done any kind of patching on Eclipse before > > Dave Created a new SDK build with the path. It can be downloaded from here I (In reply to Dave Garratt from comment #18) > Could someone provide some instructions on what I need to do in order to > download and apply this patch. > > I'm running MacOs Mojave and Eclipse 2019 09 > > Sorry - not done any kind of patching on Eclipse before > > Dave I will try to create a new SDK build for you test. We are having trouble in our build infrastructure today. Hopefully by tomorrow I will be able to create build for you
(In reply to Dave Garratt from comment #18) > Could someone provide some instructions on what I need to do in order to > download and apply this patch. > > I'm running MacOs Mojave and Eclipse 2019 09 > > Sorry - not done any kind of patching on Eclipse before > > Dave Dave, a patch was submitted today. Tomorrow there should be a new "I"-build available here [1]. It starts with I2019... Download that version, install WB into it and see if that fixes it. You can also download the one from yesterday and see if that fixes things. [1] https://download.eclipse.org/eclipse/downloads/
Created attachment 280278 [details] Image of problem I have downloaded and tested last nights version. Some improvements to the components on the palette but some issues remain. I have attached an image. I will have a look at todays update later when it appears on the website, Dave
Fix is included in https://download.eclipse.org/eclipse/downloads/drops4/I20191016-1800/. Could please verify this build? Also please report if you see any issues in the colors used in the platform
Created attachment 280304 [details] Results of test - see image attached. I can see what's changed :-) Better than black but perhaps not what you were aiming for.
Created attachment 280305 [details] Additional screen dump
(In reply to Dave Garratt from comment #24) > Created attachment 280305 [details] > Additional screen dump Thanks for sticking with us Dave.
This problem appears only in 10.14 and above. Apple changed the behavior around transparency in 10.14. This problem got uncovered when I did the hidpi support. I will continue my investigation and (if you don't mind) provide updates in bug 310387 as that bug describes the problem more appropriately
Is it helpful or relevant that Eclipse 2019 03 with Window Builder Pro does not have the problem.
*** This bug has been marked as a duplicate of bug 310387 ***