writeDirectory
创建新的 IFD 并将其设置为当前 IFD
说明
示例
将 IFD 添加到 TIFF 文件中
创建一个新的 TIFF 文件并向其中添加两个新的 IFD。
为新文件创建一个 Tiff
对象。
t = Tiff('myfile.tif','w');
向文件中添加一个新的 IFD 并显示当前目录数。您可以使用这个新的 IFD 向 TIFF 文件中添加图像数据和标记。
writeDirectory(t); currentDirectory(t)
ans = 1
再向文件中添加一个 IFD 并显示当前目录数。您可以使用此 IFD 向同一个 TIFF 文件中保存另一个图像。
writeDirectory(t); currentDirectory(t)
ans = 2
关闭 Tiff
对象。
close(t);
提示
创建只包含一个图像的 TIFF 文件时,不需要使用此函数。
算法
参考
此函数对应于 LibTIFF C API 中的 TIFFWriteDirectory
函数。要使用此函数,您必须熟悉 TIFF 规范和技术说明。请访问 LibTIFF - TIFF 库和实用工具查看此文档。
版本历史记录
在 R2009b 中推出
MATLAB 命令
您点击的链接对应于以下 MATLAB 命令:
请在 MATLAB 命令行窗口中直接输入以执行命令。Web 浏览器不支持 MATLAB 命令。
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)