You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Andrey Pavlenko (JIRA)" <ji...@apache.org> on 2007/08/31 10:18:32 UTC

[jira] Created: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

[classlib][awt] unable to draw a GIF image through Windows Remote Desktop
-------------------------------------------------------------------------

                 Key: HARMONY-4700
                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
         Environment: Win 2003 + remote desktop
            Reporter: Andrey Pavlenko


The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.

import java.awt.Frame;
import java.awt.Graphics;
import java.awt.Image;
import java.awt.MediaTracker;
import java.awt.Toolkit;

public class Test {

	public static void main(String[] args) throws Exception {
		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
		final Frame f = new Frame() {
			@Override
			public void paint(final Graphics g) {
				g.drawImage(gif, 40, 30, this);
				g.drawImage(jpg, 40, 90, this);
				g.drawImage(png, 40, 150, this);
			}
		};

		final MediaTracker tracker = new MediaTracker(f);

		tracker.addImage(gif, 1);
		tracker.addImage(jpg, 2);
		tracker.addImage(png, 3);
		tracker.waitForAll();

		f.setSize(200, 220);
		f.setVisible(true);
	}
}


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


[jira] Commented: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

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

Andrey Pavlenko commented on HARMONY-4700:
------------------------------------------

Igor, this patch fixes the issue. Thanks!

> [classlib][awt] unable to draw a GIF image through Windows Remote Desktop
> -------------------------------------------------------------------------
>
>                 Key: HARMONY-4700
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Win 2003 + remote desktop
>            Reporter: Andrey Pavlenko
>         Attachments: H-4700.patch, test.jar
>
>
> The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.
> import java.awt.Frame;
> import java.awt.Graphics;
> import java.awt.Image;
> import java.awt.MediaTracker;
> import java.awt.Toolkit;
> public class Test {
> 	public static void main(String[] args) throws Exception {
> 		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
> 		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
> 		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
> 		final Frame f = new Frame() {
> 			@Override
> 			public void paint(final Graphics g) {
> 				g.drawImage(gif, 40, 30, this);
> 				g.drawImage(jpg, 40, 90, this);
> 				g.drawImage(png, 40, 150, this);
> 			}
> 		};
> 		final MediaTracker tracker = new MediaTracker(f);
> 		tracker.addImage(gif, 1);
> 		tracker.addImage(jpg, 2);
> 		tracker.addImage(png, 3);
> 		tracker.waitForAll();
> 		f.setSize(200, 220);
> 		f.setVisible(true);
> 	}
> }

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


[jira] Closed: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

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

Alexey Petrenko closed HARMONY-4700.
------------------------------------


> [classlib][awt] unable to draw a GIF image through Windows Remote Desktop
> -------------------------------------------------------------------------
>
>                 Key: HARMONY-4700
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Win 2003 + remote desktop
>            Reporter: Andrey Pavlenko
>            Assignee: Alexey Petrenko
>         Attachments: H-4700.patch, test.jar
>
>
> The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.
> import java.awt.Frame;
> import java.awt.Graphics;
> import java.awt.Image;
> import java.awt.MediaTracker;
> import java.awt.Toolkit;
> public class Test {
> 	public static void main(String[] args) throws Exception {
> 		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
> 		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
> 		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
> 		final Frame f = new Frame() {
> 			@Override
> 			public void paint(final Graphics g) {
> 				g.drawImage(gif, 40, 30, this);
> 				g.drawImage(jpg, 40, 90, this);
> 				g.drawImage(png, 40, 150, this);
> 			}
> 		};
> 		final MediaTracker tracker = new MediaTracker(f);
> 		tracker.addImage(gif, 1);
> 		tracker.addImage(jpg, 2);
> 		tracker.addImage(png, 3);
> 		tracker.waitForAll();
> 		f.setSize(200, 220);
> 		f.setVisible(true);
> 	}
> }

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


[jira] Assigned: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

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

Alexey Petrenko reassigned HARMONY-4700:
----------------------------------------

    Assignee: Alexey Petrenko

> [classlib][awt] unable to draw a GIF image through Windows Remote Desktop
> -------------------------------------------------------------------------
>
>                 Key: HARMONY-4700
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Win 2003 + remote desktop
>            Reporter: Andrey Pavlenko
>            Assignee: Alexey Petrenko
>         Attachments: H-4700.patch, test.jar
>
>
> The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.
> import java.awt.Frame;
> import java.awt.Graphics;
> import java.awt.Image;
> import java.awt.MediaTracker;
> import java.awt.Toolkit;
> public class Test {
> 	public static void main(String[] args) throws Exception {
> 		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
> 		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
> 		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
> 		final Frame f = new Frame() {
> 			@Override
> 			public void paint(final Graphics g) {
> 				g.drawImage(gif, 40, 30, this);
> 				g.drawImage(jpg, 40, 90, this);
> 				g.drawImage(png, 40, 150, this);
> 			}
> 		};
> 		final MediaTracker tracker = new MediaTracker(f);
> 		tracker.addImage(gif, 1);
> 		tracker.addImage(jpg, 2);
> 		tracker.addImage(png, 3);
> 		tracker.waitForAll();
> 		f.setSize(200, 220);
> 		f.setVisible(true);
> 	}
> }

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


[jira] Resolved: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

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

Alexey Petrenko resolved HARMONY-4700.
--------------------------------------

    Resolution: Fixed

The patch has been applied.
Please verify

> [classlib][awt] unable to draw a GIF image through Windows Remote Desktop
> -------------------------------------------------------------------------
>
>                 Key: HARMONY-4700
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Win 2003 + remote desktop
>            Reporter: Andrey Pavlenko
>            Assignee: Alexey Petrenko
>         Attachments: H-4700.patch, test.jar
>
>
> The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.
> import java.awt.Frame;
> import java.awt.Graphics;
> import java.awt.Image;
> import java.awt.MediaTracker;
> import java.awt.Toolkit;
> public class Test {
> 	public static void main(String[] args) throws Exception {
> 		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
> 		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
> 		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
> 		final Frame f = new Frame() {
> 			@Override
> 			public void paint(final Graphics g) {
> 				g.drawImage(gif, 40, 30, this);
> 				g.drawImage(jpg, 40, 90, this);
> 				g.drawImage(png, 40, 150, this);
> 			}
> 		};
> 		final MediaTracker tracker = new MediaTracker(f);
> 		tracker.addImage(gif, 1);
> 		tracker.addImage(jpg, 2);
> 		tracker.addImage(png, 3);
> 		tracker.waitForAll();
> 		f.setSize(200, 220);
> 		f.setVisible(true);
> 	}
> }

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


[jira] Updated: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

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

Andrey Pavlenko updated HARMONY-4700:
-------------------------------------

    Attachment: test.jar

To reproduce the issue connect to a remote Win2003 system and run the attached jar.

> [classlib][awt] unable to draw a GIF image through Windows Remote Desktop
> -------------------------------------------------------------------------
>
>                 Key: HARMONY-4700
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Win 2003 + remote desktop
>            Reporter: Andrey Pavlenko
>         Attachments: test.jar
>
>
> The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.
> import java.awt.Frame;
> import java.awt.Graphics;
> import java.awt.Image;
> import java.awt.MediaTracker;
> import java.awt.Toolkit;
> public class Test {
> 	public static void main(String[] args) throws Exception {
> 		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
> 		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
> 		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
> 		final Frame f = new Frame() {
> 			@Override
> 			public void paint(final Graphics g) {
> 				g.drawImage(gif, 40, 30, this);
> 				g.drawImage(jpg, 40, 90, this);
> 				g.drawImage(png, 40, 150, this);
> 			}
> 		};
> 		final MediaTracker tracker = new MediaTracker(f);
> 		tracker.addImage(gif, 1);
> 		tracker.addImage(jpg, 2);
> 		tracker.addImage(png, 3);
> 		tracker.waitForAll();
> 		f.setSize(200, 220);
> 		f.setVisible(true);
> 	}
> }

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


[jira] Commented: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

Posted by "Igor V. Stolyarov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-4700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12524479 ] 

Igor V. Stolyarov commented on HARMONY-4700:
--------------------------------------------

This issue reproduced not only Remote Desktop, but and locally too, if set 16 bit Desktop Resolution. Cause of issue is  in AlphaBlend function, which can't blitting not 32 depth src Bitmap.

> [classlib][awt] unable to draw a GIF image through Windows Remote Desktop
> -------------------------------------------------------------------------
>
>                 Key: HARMONY-4700
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Win 2003 + remote desktop
>            Reporter: Andrey Pavlenko
>         Attachments: test.jar
>
>
> The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.
> import java.awt.Frame;
> import java.awt.Graphics;
> import java.awt.Image;
> import java.awt.MediaTracker;
> import java.awt.Toolkit;
> public class Test {
> 	public static void main(String[] args) throws Exception {
> 		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
> 		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
> 		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
> 		final Frame f = new Frame() {
> 			@Override
> 			public void paint(final Graphics g) {
> 				g.drawImage(gif, 40, 30, this);
> 				g.drawImage(jpg, 40, 90, this);
> 				g.drawImage(png, 40, 150, this);
> 			}
> 		};
> 		final MediaTracker tracker = new MediaTracker(f);
> 		tracker.addImage(gif, 1);
> 		tracker.addImage(jpg, 2);
> 		tracker.addImage(png, 3);
> 		tracker.waitForAll();
> 		f.setSize(200, 220);
> 		f.setVisible(true);
> 	}
> }

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


[jira] Commented: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

Posted by "Igor V. Stolyarov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-4700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12524678 ] 

Igor V. Stolyarov commented on HARMONY-4700:
--------------------------------------------

Works for me.
Thank you Alexey.

> [classlib][awt] unable to draw a GIF image through Windows Remote Desktop
> -------------------------------------------------------------------------
>
>                 Key: HARMONY-4700
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Win 2003 + remote desktop
>            Reporter: Andrey Pavlenko
>            Assignee: Alexey Petrenko
>         Attachments: H-4700.patch, test.jar
>
>
> The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.
> import java.awt.Frame;
> import java.awt.Graphics;
> import java.awt.Image;
> import java.awt.MediaTracker;
> import java.awt.Toolkit;
> public class Test {
> 	public static void main(String[] args) throws Exception {
> 		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
> 		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
> 		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
> 		final Frame f = new Frame() {
> 			@Override
> 			public void paint(final Graphics g) {
> 				g.drawImage(gif, 40, 30, this);
> 				g.drawImage(jpg, 40, 90, this);
> 				g.drawImage(png, 40, 150, this);
> 			}
> 		};
> 		final MediaTracker tracker = new MediaTracker(f);
> 		tracker.addImage(gif, 1);
> 		tracker.addImage(jpg, 2);
> 		tracker.addImage(png, 3);
> 		tracker.waitForAll();
> 		f.setSize(200, 220);
> 		f.setVisible(true);
> 	}
> }

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


[jira] Updated: (HARMONY-4700) [classlib][awt] unable to draw a GIF image through Windows Remote Desktop

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

Igor V. Stolyarov updated HARMONY-4700:
---------------------------------------

    Attachment: H-4700.patch

Fix attached.

> [classlib][awt] unable to draw a GIF image through Windows Remote Desktop
> -------------------------------------------------------------------------
>
>                 Key: HARMONY-4700
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4700
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>         Environment: Win 2003 + remote desktop
>            Reporter: Andrey Pavlenko
>         Attachments: H-4700.patch, test.jar
>
>
> The following test demonstrates that drawing of GIF images through remote desktop does not work. JPEG and PNG images works fine.
> import java.awt.Frame;
> import java.awt.Graphics;
> import java.awt.Image;
> import java.awt.MediaTracker;
> import java.awt.Toolkit;
> public class Test {
> 	public static void main(String[] args) throws Exception {
> 		final Image gif = Toolkit.getDefaultToolkit().createImage("test.gif");
> 		final Image jpg = Toolkit.getDefaultToolkit().createImage("test.jpg");
> 		final Image png = Toolkit.getDefaultToolkit().createImage("test.png");
> 		final Frame f = new Frame() {
> 			@Override
> 			public void paint(final Graphics g) {
> 				g.drawImage(gif, 40, 30, this);
> 				g.drawImage(jpg, 40, 90, this);
> 				g.drawImage(png, 40, 150, this);
> 			}
> 		};
> 		final MediaTracker tracker = new MediaTracker(f);
> 		tracker.addImage(gif, 1);
> 		tracker.addImage(jpg, 2);
> 		tracker.addImage(png, 3);
> 		tracker.waitForAll();
> 		f.setSize(200, 220);
> 		f.setVisible(true);
> 	}
> }

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