保存多帧TIFF [英] Saving a multi frame TIFF

查看:85
本文介绍了保存多帧TIFF的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我从C#应用程序中的Stream加载多帧TIFF,然后使用Image.Save方法保存它.但是,这只会将TIFF与第一帧一起保存-如何获取它来保存多帧tiff?

I load a multiframe TIFF from a Stream in my C# application, and then save it using the Image.Save method. However, this only saves the TIFF with the first frame - how can I get it to save a multiframe tiff?

推荐答案

由于您未提供任何详细信息,因此仅提供一些常规提示:

Since you don't provide any detailed information... just some general tips:

多帧TIFF是非常复杂的文件-例如,每个帧可以具有不同的编码...单个 Bitmap / Image 不能容纳所有带有该文件的所有相关信息(如编码和类似信息),一次只能提供一个.

Multi-Frame TIFF are very complex files - for example every frame can have a different encoding... a single Bitmap/Image can't hold all frames with all relevant information (like encoding and similar) of such a file, only one at a time.

对于加载,您需要设置参数,该参数告诉类要加载哪个帧,否则仅加载第一个...有关某些代码,请参见

For loading you need to set parameter which tells the class which frame to load, otherwise it just loads the first... for some code see here.

保存多帧TIFF时会出现类似的问题-在这里,您需要使用 EncoderParameters 并使用此处.

Similar problems arise when saving multi-frame TIFFs - here you need to work with EncoderParameters and use SaveAdd etc. - for some working code see here.

这篇关于保存多帧TIFF的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆