Page 3 of 3

Re: Odd issues when compiling on windows

Posted: 2007-12-03T13:50:00-07:00
by magick
Stand by. It may take a week before we get back to you.

Re: Odd issues when compiling on windows

Posted: 2007-12-03T13:51:05-07:00
by mkoppanen
Thank you!

Re: Odd issues when compiling on windows

Posted: 2007-12-03T18:41:39-07:00
by magick
We're using ImageMagick 6.3.7-2 and Visual Studio 7. We compiled statically as you suggested. The test.png created by your application is fully transparent as expected.

Re: Odd issues when compiling on windows

Posted: 2007-12-04T05:27:42-07:00
by mkoppanen
I am using Visual Studio 2005 (VC8) in Microsoft Windows Vista. I don't really understand how this is happening but Imagick users are reporting same issues when they use the PHP extension that is linked statically.

Am I missing some compile option or do I have some unwanted switch on?

I am linking against:

Code: Select all

CORE_RL_bzlib_.lib CORE_RL_coders_.lib CORE_RL_filters_.lib CORE_RL_jbig_.lib CORE_RL_jp2_.lib CORE_RL_jpeg_.lib CORE_RL_lcms_.lib CORE_RL_libxml_.lib CORE_RL_png_.lib CORE_RL_tiff_.lib CORE_RL_ttf_.lib CORE_RL_xlib_.lib CORE_RL_wand_.lib CORE_RL_wmf_.lib CORE_RL_zlib_.lib CORE_RL_magick_.lib  winmm.lib wsock32.lib
Here is identify output generated from windows and linux generated images. Both are using the same code:

Code: Select all

Image: test.png
  Format: PNG (Portable Network Graphics)
  Class: DirectClass
  Geometry: 100x100+0+0
  Type: Bilevel
  Endianess: Undefined
  Colorspace: Gray
  Depth: 1-bit
  Channel depth:
    Gray: 1-bit
  Channel statistics:
    Gray:
      Min: 0 (0)
      Max: 0 (0)
      Mean: 0 (0)
      Standard deviation: 0 (0)
  Histogram:
     10000: (    0,    0,    0) #000000000000 black
  Rendering intent: Undefined
  Resolution: 72x72
  Units: Undefined
  Filesize: 158b
  Interlace: None
  Background color: white
  Border color: rgb(223,223,223)
  Matte color: grey74
  Transparent color: black
  Page geometry: 100x100+0+0
  Dispose: Undefined
  Iterations: 0
  Compression: Zip
  Orientation: Undefined
  Signature: 9a413b131ecf0ccfb02a837ddb33766d8604cc00da7937b79bd363b53c8d7d86
  Tainted: False
  Version: ImageMagick 6.3.7 11/19/07 Q16 http://www.imagemagick.org

Code: Select all

Image: trans_lin.png
  Format: PNG (Portable Network Graphics)
  Class: DirectClass
  Geometry: 100x100+0+0
  Type: Bilevel
  Endianess: Undefined
  Colorspace: Gray
  Depth: 1-bit
  Channel depth:
    Gray: 1-bit
    Alpha: 1-bit
  Channel statistics:
    Gray:
      Min: 0 (0)
      Max: 0 (0)
      Mean: 0 (0)
      Standard deviation: 0 (0)
    Opacity:
      Min: 1 (1)
      Max: 1 (1)
      Mean: 1 (1)
      Standard deviation: 0 (0)
  Alpha: none    #0000000000000000
  Histogram:
     10000: (    0,    0,    0,65535) #0000000000000000 none
  Rendering intent: Undefined
  Resolution: 72x72
  Units: Undefined
  Filesize: 196b
  Interlace: None
  Background color: white
  Border color: rgb(223,223,223)
  Matte color: grey74
  Transparent color: none
  Page geometry: 100x100+0+0
  Dispose: Undefined
  Iterations: 0
  Compression: Zip
  Orientation: Undefined
  Signature: 1bbf880a633b603cb01c2efae45fadcbec6b01f42971339ad0498d0aae910766
  Tainted: False
  Version: ImageMagick 6.3.7 11/19/07 Q16 http://www.imagemagick.org
Anything fishy in here?

Re: Odd issues when compiling on windows

Posted: 2007-12-04T07:06:29-07:00
by mkoppanen
The following lines in test.png (the windows generated version) doesn't look right:

Code: Select all

Transparent color: black

Code: Select all

Histogram:
     10000: (    0,    0,    0) #000000000000 black


And another thing:

In the linux image I can see this:

Code: Select all

  Channel depth:
    Gray: 1-bit
    Alpha: 1-bit
Where the windows generated Image shows this:

Code: Select all

  Channel depth:
    Gray: 1-bit

The entry for alpha seems to be missing completely?

Re: Odd issues when compiling on windows

Posted: 2007-12-04T07:13:36-07:00
by magick
We get identical results for Windows and Linux (the alpha channel is present). In our tests we used an "installed" version of ImageMagick that is dependent on the Windows registry. Perhaps you are installing an "uninstalled" version which requires MAGICK_HOME to be defined for ImageMagick to find its configuration files. To investigate, set the environment variable MAGICK_DEBUG to 'configure' and run your test program. Take a look at where ImageMagick is looking for its configuration files.

Re: Odd issues when compiling on windows

Posted: 2007-12-04T07:30:37-07:00
by mkoppanen
Well, that was it! I've been struggling with this for ages.

Thank you very much!