Hi, ImageMagick for Windows seems to be missing display routines, as the supplied display utility is X based... or did I miss a key point of their documentation?
Win32::GUI seems to be able to do something with Bitmaps, but it is not particularly clear just what, or how. ImageMagick can do lots of nice conversions of whatever graphic format to BMP format, if that is what Win32::GUI::Bitmap needs. I'd like to conquer the functionality of loading a file with ImageMagick, and then using Win32::GUI to display it. Loading the file seems to be straightforward: use Image::Magick; $image = Image::Magick -> new; $errstr = $image -> Read ( $filename ); How can I get from there, to a window that displays the data? Do I have to $errstr = $image -> Write ( 'xxx.bmp' ); as it appears that the Win32::GUI::Bitmap call requires a filename? use Win32::GUI; $bitmap = new Win32::GUI::Bitmap ( 'xxx.bmp' ); or is there a way to avoid the intermediate file? Using the TBD Create method? Or maybe Win32::GUI::BitmapInline? Although this seems to create its own intermediate file. And then, having somehow or another a $bitmap reference, how do I display it in a window? I see one possibility of $main_window -> AddLabel ( -name => bitmap, -bitmap => $bitmap ); Are there any pros or cons of using Labels vs Buttons vs ??? And do you need to specify the exact size of the bitmap as the size of the label? Or do you need to leave room for borders, and other stuff? Some of this will probably become clear as I start to experiment. If there are any scaling capabilities, it'd be nice to know about them, I didn't find any the first pass through. On the other hand, I fear that none of that will allow me to add scroll bars to the bitmap, so that I can display a portion of a bigger than screen image. I fear I'll have to dive into Win32::GUI::DC to do some of this... I've been avoiding that so far... but this seems oriented to line art, rather than bitmap art... Any advice, guidance, or sample code that I could look at for this, before I bang a hole in a wall with my head, and then find out it was the wrong wall!!! would be welcomed. Mostly I'm dealing with monochrome bitmaps, if that simplifies things, but they can get quite large, and scaling and scrolling are requirements to get the job done. -- Glenn ===== Due to the current economic situation, the light at the end of the tunnel will be turned off until further notice.