in

Archived Data Techniques Forums

Convert ImageCollection to Bitmap

Last post 03-25-2009 8:49 AM by support. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 03-23-2009 8:16 PM

    Convert ImageCollection to Bitmap

    Hi all,  I'm using the viewer to show images that the user gets from a scanner, when the process finish i have a ImageCollection in the viewer with N ImImage classes, my problem is that we have another component that needs this images but the parameter this component need is a Bitmap, so my question is there is a way to convert the ImageCollection to a Bitmap?, right now I'm saving the ImageCollection to a Stream and then creating a Bitmap with this Stream but I'm wondering if there is an easier way.

    Thanks

    Juan Zamudio

  • 03-24-2009 9:04 AM In reply to

    Re: Convert ImageCollection to Bitmap

    Hello,

     You can get a Bitmap object for each ImImage in the collection by using the ImImage class's .GetBitmapImage method.

     

     

    Sean
    Data Techniques Online Support
  • 03-24-2009 11:43 AM In reply to

    Re: Convert ImageCollection to Bitmap

    Yes i know that, but i need a multiframe tif, so i wanted to create a Bitmap with all the images in the collection as frames, i guess i was jut being lazy and wanted a method like ImageCollection.ToBitmap()

     

    Thanks for your help.

     

    Juan Zamudio

  • 03-25-2009 8:49 AM In reply to

    Re: Convert ImageCollection to Bitmap

    Hi,

    The .Net Bitmap object represents only one page of a file not multiple pages. You can use the foreach operator to iterate thru the ImImage objs in the collection  and call the GetBitmap on them.

    Sean
    Data Techniques Online Support
Page 1 of 1 (4 items)
Copyright 2009 Data Techniques, Inc. All Rights Reserved.