Overload | Description |
---|---|
StartFeedLoad(Int32,CodecsLoadByteOrder) | Initializes a file-load process in which you control the input stream. |
StartFeedLoad(Int32,CodecsLoadByteOrder,Int32,Int32) | Initializes a file-load process in which you control the input stream with specific number of pages. |
Visual Basic | Copy Code |
---|---|
RasterCodecs.FeedLoad |
C# | Copy Code |
---|---|
RasterCodecs.FeedLoad |
You must call the FeedLoad method to supply buffered data, and you must call StopFeedLoad when the loading is complete.
This file-load process is useful when receiving transmitted images, such as those on the Internet. It works the same way as the Load method, except that your code supplies the image data. The file-load process works as follows:
You call the StartFeedLoad method to initialize the file-load process. You create a buffer, and each time you fill it with information, you call the FeedLoad method, which sends the data to the file-load process just as if the data were being read from a file on disk. Whenever it has enough data to do so, the file-load process behaves the same as in the Load method. It allocates and begins loading the image. It calls your LoadImage event handler, if one is specified, whenever it has enough data in its input buffer.
The file-load process updates information in the RasterImage when it has received enough information to do so. The file-load process will make the first call to your event handler whenever this information is available.
At any time after calling StartFeedLoad, you can call CancelFeedLoad to gracefully abort the feed load operation. This allows you to end the feed load process without throwing an exception. To end the file-load process, you call the StopFeedLoad method, which cleans up the process, and returns the loaded RasterImage, if successful. If you call this method before supplying the complete file, it will successfully clean up the process, but will throw an exception. You should catch the exception if the load is canceled purposely.
CodecsLoadByteOrder.Gray is only valid for 12 and 16-bit grayscale images. Support for 12 and 16-bit grayscale images is only available in the Document/Medical Imaging editions.
This method cannot be used in combination with StartRedirecting.
Target Platforms: Microsoft .NET Framework 2.0, Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family