You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Dmitriy Matveev (JIRA)" <ji...@apache.org> on 2007/07/06 13:38:04 UTC

[jira] Created: (HARMONY-4381) [classlib][awt] Color profiles are not exists

[classlib][awt] Color profiles are not exists
---------------------------------------------

                 Key: HARMONY-4381
                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
            Reporter: Dmitriy Matveev


Exception when using getInstance() method of java.awt.color.ICC_Profile

Test below demonstrate this:

import java.awt.*;
import java.awt.color.ColorSpace;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import java.awt.image.ColorConvertOp;

public class ColorTest {
    public static void main(String[] args) {
        Frame f = new Frame("Test"){
            public void paint(Graphics g){
                Graphics2D g2d = (Graphics2D)g;
                RenderingHints hints = g2d.getRenderingHints();
                ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
                ColorConvertOp cco = new ColorConvertOp(cs, hints);
            }
        };
            
        f.setBounds(0, 0, 800, 600);
        f.setVisible(true);
        f.addWindowListener(new WindowAdapter() {
            public void windowClosing(WindowEvent ev) {               
                System.exit(0);
            }
        });        
    }
}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HARMONY-4381) [classlib][awt] Color profiles are not exists

Posted by "Andrey Pavlenko (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-4381?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12516289 ] 

Andrey Pavlenko commented on HARMONY-4381:
------------------------------------------

The patch has been applied as expected. Thx.

> [classlib][awt] Color profiles are not exists
> ---------------------------------------------
>
>                 Key: HARMONY-4381
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Dmitriy Matveev
>            Assignee: Alexey Petrenko
>         Attachments: HARMONY-4381-build.patch, HARMONY-4381-profiles.zip
>
>
> Exception when using getInstance() method of java.awt.color.ICC_Profile
> Test below demonstrate this:
> import java.awt.*;
> import java.awt.color.ColorSpace;
> import java.awt.event.WindowAdapter;
> import java.awt.event.WindowEvent;
> import java.awt.image.ColorConvertOp;
> public class ColorTest {
>     public static void main(String[] args) {
>         Frame f = new Frame("Test"){
>             public void paint(Graphics g){
>                 Graphics2D g2d = (Graphics2D)g;
>                 RenderingHints hints = g2d.getRenderingHints();
>                 ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
>                 ColorConvertOp cco = new ColorConvertOp(cs, hints);
>             }
>         };
>             
>         f.setBounds(0, 0, 800, 600);
>         f.setVisible(true);
>         f.addWindowListener(new WindowAdapter() {
>             public void windowClosing(WindowEvent ev) {               
>                 System.exit(0);
>             }
>         });        
>     }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (HARMONY-4381) [classlib][awt] Color profiles are not exists

Posted by "Andrey Pavlenko (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4381?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Andrey Pavlenko updated HARMONY-4381:
-------------------------------------

    Attachment: HARMONY-4381-build.patch
                HARMONY-4381-profiles.zip

I've created 4 of 5 required color profiles using the lcms library (http://sourceforge.net/projects/lcms): CIEXYZ,  GRAY,  LINEAR_RGB,  sRGB. The missing profile is PYCC.
BTW, some JREs do not contain the PYCC profile because of its size (~260kb on RI). If one needs this profile he could put it as PYCC.pf file to classpath, or specify the "java.iccprofile.path" system property pointing to the directory with this file.


> [classlib][awt] Color profiles are not exists
> ---------------------------------------------
>
>                 Key: HARMONY-4381
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Dmitriy Matveev
>         Attachments: HARMONY-4381-build.patch, HARMONY-4381-profiles.zip
>
>
> Exception when using getInstance() method of java.awt.color.ICC_Profile
> Test below demonstrate this:
> import java.awt.*;
> import java.awt.color.ColorSpace;
> import java.awt.event.WindowAdapter;
> import java.awt.event.WindowEvent;
> import java.awt.image.ColorConvertOp;
> public class ColorTest {
>     public static void main(String[] args) {
>         Frame f = new Frame("Test"){
>             public void paint(Graphics g){
>                 Graphics2D g2d = (Graphics2D)g;
>                 RenderingHints hints = g2d.getRenderingHints();
>                 ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
>                 ColorConvertOp cco = new ColorConvertOp(cs, hints);
>             }
>         };
>             
>         f.setBounds(0, 0, 800, 600);
>         f.setVisible(true);
>         f.addWindowListener(new WindowAdapter() {
>             public void windowClosing(WindowEvent ev) {               
>                 System.exit(0);
>             }
>         });        
>     }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (HARMONY-4381) [classlib][awt] Color profiles are not exists

Posted by "Alexey Petrenko (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4381?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexey Petrenko resolved HARMONY-4381.
--------------------------------------

    Resolution: Fixed

The patch has been applied.
Please verify.

> [classlib][awt] Color profiles are not exists
> ---------------------------------------------
>
>                 Key: HARMONY-4381
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Dmitriy Matveev
>            Assignee: Alexey Petrenko
>         Attachments: HARMONY-4381-build.patch, HARMONY-4381-profiles.zip
>
>
> Exception when using getInstance() method of java.awt.color.ICC_Profile
> Test below demonstrate this:
> import java.awt.*;
> import java.awt.color.ColorSpace;
> import java.awt.event.WindowAdapter;
> import java.awt.event.WindowEvent;
> import java.awt.image.ColorConvertOp;
> public class ColorTest {
>     public static void main(String[] args) {
>         Frame f = new Frame("Test"){
>             public void paint(Graphics g){
>                 Graphics2D g2d = (Graphics2D)g;
>                 RenderingHints hints = g2d.getRenderingHints();
>                 ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
>                 ColorConvertOp cco = new ColorConvertOp(cs, hints);
>             }
>         };
>             
>         f.setBounds(0, 0, 800, 600);
>         f.setVisible(true);
>         f.addWindowListener(new WindowAdapter() {
>             public void windowClosing(WindowEvent ev) {               
>                 System.exit(0);
>             }
>         });        
>     }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (HARMONY-4381) [classlib][awt] Color profiles are not exists

Posted by "Alexey Petrenko (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4381?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexey Petrenko reassigned HARMONY-4381:
----------------------------------------

    Assignee: Alexey Petrenko

> [classlib][awt] Color profiles are not exists
> ---------------------------------------------
>
>                 Key: HARMONY-4381
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Dmitriy Matveev
>            Assignee: Alexey Petrenko
>         Attachments: HARMONY-4381-build.patch, HARMONY-4381-profiles.zip
>
>
> Exception when using getInstance() method of java.awt.color.ICC_Profile
> Test below demonstrate this:
> import java.awt.*;
> import java.awt.color.ColorSpace;
> import java.awt.event.WindowAdapter;
> import java.awt.event.WindowEvent;
> import java.awt.image.ColorConvertOp;
> public class ColorTest {
>     public static void main(String[] args) {
>         Frame f = new Frame("Test"){
>             public void paint(Graphics g){
>                 Graphics2D g2d = (Graphics2D)g;
>                 RenderingHints hints = g2d.getRenderingHints();
>                 ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
>                 ColorConvertOp cco = new ColorConvertOp(cs, hints);
>             }
>         };
>             
>         f.setBounds(0, 0, 800, 600);
>         f.setVisible(true);
>         f.addWindowListener(new WindowAdapter() {
>             public void windowClosing(WindowEvent ev) {               
>                 System.exit(0);
>             }
>         });        
>     }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (HARMONY-4381) [classlib][awt] Color profiles are not exists

Posted by "Dmitriy Matveev (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-4381?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12511059 ] 

Dmitriy Matveev commented on HARMONY-4381:
------------------------------------------

Exception below:

java.lang.IllegalArgumentException: Can't open color profile
	at java.awt.color.ICC_Profile.getInstance(ICC_Profile.java:731)
	at java.awt.color.ICC_ProfileStub.loadProfile(ICC_ProfileStub.java:162)
	at java.awt.color.ICC_ColorSpace.getProfile(ICC_ColorSpace.java:96)
	at java.awt.image.ColorConvertOp.<init>(ColorConvertOp.java:285)
	at JavaTest.ColorTest$1.paint(ColorTest.java:16)
	at java.awt.Component.processPaintEvent(Component.java:3692)
	at java.awt.Component.dispatchEvent(Component.java:3519)
	at java.awt.EventQueueCore.dispatchEventImpl(EventQueueCore.java:149)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:144)
	at java.awt.EventDispatchThread.runModalLoop(EventDispatchThread.java:74)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:48)

To view the exception "// t.printStackTrace();" line in void runModalLoop(ModalContext context) method of EventDispatchThread need to be uncommented.

> [classlib][awt] Color profiles are not exists
> ---------------------------------------------
>
>                 Key: HARMONY-4381
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Dmitriy Matveev
>
> Exception when using getInstance() method of java.awt.color.ICC_Profile
> Test below demonstrate this:
> import java.awt.*;
> import java.awt.color.ColorSpace;
> import java.awt.event.WindowAdapter;
> import java.awt.event.WindowEvent;
> import java.awt.image.ColorConvertOp;
> public class ColorTest {
>     public static void main(String[] args) {
>         Frame f = new Frame("Test"){
>             public void paint(Graphics g){
>                 Graphics2D g2d = (Graphics2D)g;
>                 RenderingHints hints = g2d.getRenderingHints();
>                 ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
>                 ColorConvertOp cco = new ColorConvertOp(cs, hints);
>             }
>         };
>             
>         f.setBounds(0, 0, 800, 600);
>         f.setVisible(true);
>         f.addWindowListener(new WindowAdapter() {
>             public void windowClosing(WindowEvent ev) {               
>                 System.exit(0);
>             }
>         });        
>     }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (HARMONY-4381) [classlib][awt] Color profiles are not exists

Posted by "Alexei Zakharov (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4381?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexei Zakharov reassigned HARMONY-4381:
----------------------------------------

    Assignee: Alexei Zakharov  (was: Alexey Petrenko)

> [classlib][awt] Color profiles are not exists
> ---------------------------------------------
>
>                 Key: HARMONY-4381
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Dmitriy Matveev
>            Assignee: Alexei Zakharov
>         Attachments: HARMONY-4381-build.patch, HARMONY-4381-profiles.zip
>
>
> Exception when using getInstance() method of java.awt.color.ICC_Profile
> Test below demonstrate this:
> import java.awt.*;
> import java.awt.color.ColorSpace;
> import java.awt.event.WindowAdapter;
> import java.awt.event.WindowEvent;
> import java.awt.image.ColorConvertOp;
> public class ColorTest {
>     public static void main(String[] args) {
>         Frame f = new Frame("Test"){
>             public void paint(Graphics g){
>                 Graphics2D g2d = (Graphics2D)g;
>                 RenderingHints hints = g2d.getRenderingHints();
>                 ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
>                 ColorConvertOp cco = new ColorConvertOp(cs, hints);
>             }
>         };
>             
>         f.setBounds(0, 0, 800, 600);
>         f.setVisible(true);
>         f.addWindowListener(new WindowAdapter() {
>             public void windowClosing(WindowEvent ev) {               
>                 System.exit(0);
>             }
>         });        
>     }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (HARMONY-4381) [classlib][awt] Color profiles are not exists

Posted by "Alexei Zakharov (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4381?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexei Zakharov reassigned HARMONY-4381:
----------------------------------------

    Assignee: Alexey Petrenko  (was: Alexei Zakharov)

Oops, sorry, wrong button...

> [classlib][awt] Color profiles are not exists
> ---------------------------------------------
>
>                 Key: HARMONY-4381
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Dmitriy Matveev
>            Assignee: Alexey Petrenko
>         Attachments: HARMONY-4381-build.patch, HARMONY-4381-profiles.zip
>
>
> Exception when using getInstance() method of java.awt.color.ICC_Profile
> Test below demonstrate this:
> import java.awt.*;
> import java.awt.color.ColorSpace;
> import java.awt.event.WindowAdapter;
> import java.awt.event.WindowEvent;
> import java.awt.image.ColorConvertOp;
> public class ColorTest {
>     public static void main(String[] args) {
>         Frame f = new Frame("Test"){
>             public void paint(Graphics g){
>                 Graphics2D g2d = (Graphics2D)g;
>                 RenderingHints hints = g2d.getRenderingHints();
>                 ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
>                 ColorConvertOp cco = new ColorConvertOp(cs, hints);
>             }
>         };
>             
>         f.setBounds(0, 0, 800, 600);
>         f.setVisible(true);
>         f.addWindowListener(new WindowAdapter() {
>             public void windowClosing(WindowEvent ev) {               
>                 System.exit(0);
>             }
>         });        
>     }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (HARMONY-4381) [classlib][awt] Color profiles are not exists

Posted by "Dmitriy Matveev (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4381?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dmitriy Matveev closed HARMONY-4381.
------------------------------------


> [classlib][awt] Color profiles are not exists
> ---------------------------------------------
>
>                 Key: HARMONY-4381
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4381
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Dmitriy Matveev
>            Assignee: Alexey Petrenko
>         Attachments: HARMONY-4381-build.patch, HARMONY-4381-profiles.zip
>
>
> Exception when using getInstance() method of java.awt.color.ICC_Profile
> Test below demonstrate this:
> import java.awt.*;
> import java.awt.color.ColorSpace;
> import java.awt.event.WindowAdapter;
> import java.awt.event.WindowEvent;
> import java.awt.image.ColorConvertOp;
> public class ColorTest {
>     public static void main(String[] args) {
>         Frame f = new Frame("Test"){
>             public void paint(Graphics g){
>                 Graphics2D g2d = (Graphics2D)g;
>                 RenderingHints hints = g2d.getRenderingHints();
>                 ColorSpace cs = ColorSpace.getInstance(ColorSpace.CS_GRAY);
>                 ColorConvertOp cco = new ColorConvertOp(cs, hints);
>             }
>         };
>             
>         f.setBounds(0, 0, 800, 600);
>         f.setVisible(true);
>         f.addWindowListener(new WindowAdapter() {
>             public void windowClosing(WindowEvent ev) {               
>                 System.exit(0);
>             }
>         });        
>     }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.