GithubHelp home page GithubHelp logo

Comments (8)

haraldk avatar haraldk commented on May 25, 2024

Hi Andreas,

Thanks for reporting (and good analysis too)!

This is a known issue (kind of)... The same issue is present if you use an OpenJDK build, rather than an Oracle build of Java 6 or 7, which also uses LCMS rather than KCMS. I think there are a few more tests that fails too, using LCMS (if these pass using JDK 8, cool!).

I haven't filed a bug for it, as I haven't seen the need to support OpenJDK. But if LCMS is the default for JDK 8, it seems we have to take action...

I wasn't aware that you could change color management system using command line, is this a new JDK 8 feature?

For short term, building with KCMS seems like the only option, but then you probably should use that flag at run-time too.

Harald K

from twelvemonkeys.

ankon avatar ankon commented on May 25, 2024

From what I can see JDK8 (Open~ and Oracle ~) both use LCMS by default now (https://bugs.openjdk.java.net/browse/JDK-8011622).

As to switching: it seems that switching should have been possible before, by using -Dsun.java2d.cmm=sun.java2d.cmm.lcms.LCMS, but this didn't work in my brief testing with JDK 7u45. This is purely based on reading the commit for the bug itself, I haven't found official "documentation" about this feature.

from twelvemonkeys.

ankon avatar ankon commented on May 25, 2024

if these pass using JDK 8, cool!

Running with

JAVA_HOME=/usr/jdk8 mvn clean install -Dsun.java2d.cmm=sun.java2d.cmm.kcms.KcmsServiceProvider

shows three failures:

Failed tests:   testReadSubsamplingBounds1027(com.twelvemonkeys.imageio.plugins.jpeg.JPEGImageReaderTest): expected:<16711421> but was:<16711677>
  testReadSubsamplingBounds1026(com.twelvemonkeys.imageio.plugins.jpeg.JPEGImageReaderTest): expected:<16711421> but was:<16711677>
  testReadSubsamplingBounds1024(com.twelvemonkeys.imageio.plugins.jpeg.JPEGImageReaderTest): expected:<16711421> but was:<16711677>

These however I also get with JDK 7u45, so they don't seem to be JDK8-specific.

from twelvemonkeys.

haraldk avatar haraldk commented on May 25, 2024

Hmmm..

If you have some time to look into this, one think you could test is if the special handling of the broken profile really is needed with LCMS? While the Java implementation in some cases is incompatible with the KCMS one, LCMS seems more lenient about issues like the one that is tested for in the failing test. We might not need it at all.

If the special handling isn't needed, all we need is a way to detect CMS at runtime and skip the hotfix in case of LCMS.

...plus some serious CI-setup on Travis, to make sure we build and test on multiple JDKs/CMSs... :-P

Harald K

from twelvemonkeys.

haraldk avatar haraldk commented on May 25, 2024

Re: testReadSubsamplingBounds...

Oh great... I added those tests yesterday (see #39 and #40), and they passed on my setup... I'll have to add some fuzzyness to the assertions I guess...

Please file new issues for these findings if they fail on normal Oracle 7 JDK.

Harald K

from twelvemonkeys.

ankon avatar ankon commented on May 25, 2024

Will have a look into whether the work-around is needed later today or tomorrow. At the moment JDK8 isn't released, I just noticed the issue in some local test builds (my default JDK is usually a fresh JDK 8 snapshot build to detect such issues before our customers do :D)

from twelvemonkeys.

haraldk avatar haraldk commented on May 25, 2024

Fixed in f588d65.

Harald K

from twelvemonkeys.

haraldk avatar haraldk commented on May 25, 2024

And better yet, in 94ed531. :-)

Harald K

from twelvemonkeys.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.