question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

JPEG image identified as RGB instead of CMYK

See original GitHub issue

After reading this SO answer i assume TM supports the detection of color space model fr JPEG images conform spec.

However, this image returns RGB using

int type = bufferedImage.getColorModel().getColorSpace();

However, ImageMagick 6.9.7-4 reports

identify -verbose Vitocell_100-W_00019.jpg | grep Colorspace
Colorspace: CMYK

So does exiftool 10.80:

exiftool Vitocell_100-W_00019.jpg | grep "Color Space Data"
Color Space Data                : CMYK

So maybe this is a bug?

Using openjdk version “11.0.7” 2020-04-14 LTS; OpenJDK Runtime Environment Corretto-11.0.7.10.1 (build 11.0.7+10-LTS)

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
rmullercommented, Jun 9, 2020

Thanks, even more clear now!

Thank you very much for all this information. Before pushing a PR, I need to invest more time in this subject / API. Maybe my notes can be a starting point for a FAQ.

1reaction
rmullercommented, Jun 9, 2020

All clear now. And indeed, this works! BTW I use JDK11 and behavior is still as you described 😦

In this thread you gave me a lot of (excellent) info that I cannot find anywhere (besides the metadata / javax_imageio_1.0 stuff). Is this indeed not documented? Or do i miss something?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Is JPEG photo same as RGB JPG file? - Super User
An actual RGB encoded JPEG file is not very common. ... CMYK images are usually converted to YCbCrK intermediate before compression, ...
Read more >
RGB vs CMYK: What's the Difference? - 99Designs
Both RGB and CMYK are modes for mixing color in graphic design. As a quick reference, the RGB color mode is best for...
Read more >
Re: I have to save as CMYK for print, but the colo... - 3962276
RGB and CMYK will probably not be exactly the same color. JPEG is a lossy compressed format, does not save layers or transparency...
Read more >
Get Color Mode (CMYK or RGB) of an JPEG Image ? - MSDN
According to Wikipedia jpg files are in YCbCr format, but some use RGB. Ron Whittle - If the post is helpful or answers...
Read more >
Know your files: A quick guide to JPG, PNG, RGB, CMYK and ...
Anything dealing with the web should always be in RGB and files for printing should be in CMYK, although some printing companies will...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found