mail-archives/mono-bugs/2005-June/031247.html

143 строки
5.2 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<TITLE> [Mono-bugs] [Bug 75430][Nor] New - libgdiplus fails to convert
indexed image formats
</TITLE>
<LINK REL="Index" HREF="index.html" >
<LINK REL="made" HREF="mailto:mono-bugs%40lists.ximian.com?Subject=%5BMono-bugs%5D%20%5BBug%2075430%5D%5BNor%5D%20New%20-%20libgdiplus%20fails%20to%20convert%0A%09indexed%20image%20formats&In-Reply-To=bug-75430%40chernobyl.ximian.com">
<META NAME="robots" CONTENT="index,nofollow">
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
<LINK REL="Previous" HREF="031246.html">
</HEAD>
<BODY BGCOLOR="#ffffff">
<H1>[Mono-bugs] [Bug 75430][Nor] New - libgdiplus fails to convert
indexed image formats</H1>
<B>bugzilla-daemon at bugzilla.ximian.com</B>
<A HREF="mailto:mono-bugs%40lists.ximian.com?Subject=%5BMono-bugs%5D%20%5BBug%2075430%5D%5BNor%5D%20New%20-%20libgdiplus%20fails%20to%20convert%0A%09indexed%20image%20formats&In-Reply-To=bug-75430%40chernobyl.ximian.com"
TITLE="[Mono-bugs] [Bug 75430][Nor] New - libgdiplus fails to convert
indexed image formats">bugzilla-daemon at bugzilla.ximian.com
</A><BR>
<I>Thu Jun 30 21:11:14 EDT 2005</I>
<P><UL>
<LI>Previous message: <A HREF="031246.html">[Mono-bugs] [Bug 75239][Maj] Changed - DNS.GetHostName() and huge
number of threads
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#31247">[ date ]</a>
<a href="thread.html#31247">[ thread ]</a>
<a href="subject.html#31247">[ subject ]</a>
<a href="author.html#31247">[ author ]</a>
</LI>
</UL>
<HR>
<!--beginarticle-->
<PRE>Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by <A HREF="http://lists.ximian.com/mailman/listinfo/mono-bugs">notzcoolx at yahoo.es.</A>
<A HREF="http://bugzilla.ximian.com/show_bug.cgi?id=75430">http://bugzilla.ximian.com/show_bug.cgi?id=75430</A>
--- shadow/75430 2005-06-30 21:11:14.000000000 -0400
+++ shadow/75430.tmp.2858 2005-06-30 21:11:14.000000000 -0400
@@ -0,0 +1,74 @@
+Bug#: 75430
+Product: Mono: Class Libraries
+Version: 1.1
+OS:
+OS Details: Mac OS 10.4.1
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: Sys.Drawing.
+AssignedTo: <A HREF="http://lists.ximian.com/mailman/listinfo/mono-bugs">mono-bugs at ximian.com</A>
+ReportedBy: <A HREF="http://lists.ximian.com/mailman/listinfo/mono-bugs">notzcoolx at yahoo.es</A>
+QAContact: <A HREF="http://lists.ximian.com/mailman/listinfo/mono-bugs">mono-bugs at ximian.com</A>
+TargetMilestone: ---
+URL:
+Cc:
+Summary: libgdiplus fails to convert indexed image formats
+
+Description of Problem:
+In Mac OS X 10.4.1 with Mono 1.1.8.1 (from pkg of mono-project.com)
+libgdiplus fails when asked to convert from an indexed image to a 32b ARGB image.
+
+
+Steps to reproduce the problem:
+1. Compile this program:
+
+--- CUT ---
+using System;
+using System.Drawing;
+using System.Drawing.Imaging;
+
+class Texture
+{
+ public static void LoadTexture(string fileName) {
+ Bitmap bitmap = (Bitmap) Image.FromFile(fileName);
+
+ Rectangle rect = new Rectangle(0, 0, bitmap.Width, bitmap.Height);
+ BitmapData bitmapdata =
+ bitmap.LockBits(rect,
+ ImageLockMode.ReadOnly,
+ PixelFormat.Format32bppArgb);
+ /* Do somenthing */
+ bitmap.UnlockBits(bitmapdata);
+ bitmap.Dispose();
+ }
+
+ public static void Main(string[] args) {
+ LoadTexture(args[0]);
+ }
+}
+--- CUT ---
+
+2. Try it with 2 uncompressed bmp, one indexed and one 24bpp.
+
+Actual Results:
+The test should fail in Mac with the indexed image but do not fail in Windows (.Net or Mono
+1.1.8 (from installer)) or Linux (Mono 1.1.8 (compiled from Gentoo ebuild or SVN)).
+
+Expected Results:
+Both images get processed fine and the program exits without output or exception.
+
+
+How often does this happen?
+With all indexed images I've tried.
+
+
+Additional Information:
+The problem seems to be in libgdiplus/src/bitmap.c at gdip_bitmap_change_rect_pixel_format
+called from GdipBitmapLockBits function. I haven't been able to compile and debug libgdiplus
+from SVN but I think that the problem lies when that function call
+gdip_is_pixel_format_conversion_valid (but I don't know exactly).
+I remeber that some months ago (about six) I tried the program I extracted this test in Linux and
+also failed but since 1.1.6 or 1.1.7 it doesn't fail in Linux neither (it always worked in Windows
+with .Net or Mono).
</PRE>
<!--endarticle-->
<HR>
<P><UL>
<!--threads-->
<LI>Previous message: <A HREF="031246.html">[Mono-bugs] [Bug 75239][Maj] Changed - DNS.GetHostName() and huge
number of threads
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#31247">[ date ]</a>
<a href="thread.html#31247">[ thread ]</a>
<a href="subject.html#31247">[ subject ]</a>
<a href="author.html#31247">[ author ]</a>
</LI>
</UL>
<hr>
<a href="http://lists.ximian.com/mailman/listinfo/mono-bugs">More information about the mono-bugs
mailing list</a><br>
</body></html>