【问题标题】:how can i convert multi page and single page tiff from all compression types to group 4 compression with libtiff.net?如何使用 libtiff.net 将所有压缩类型的多页和单页 tiff 转换为第 4 组压缩?
【发布时间】:2014-02-26 05:05:41
【问题描述】:

我有数百个具有各种压缩的多页和单页 tiff,我想使用 libtiff.net 将它们转换为第 4 组,如果可能的话,使用 c# 中的 TiffCP。我尝试通过 Microsoft Visual Studio 和using Bitmiracle.TiffCP; 中的“添加引用”来做到这一点,但我不知道应该如何使用这个命名空间。

我该如何解决?

【问题讨论】:

  • 您好。如果您展示了您尝试过的内容,我们将不胜感激。它可以帮助用户回答问题并帮助找到您可能遇到的问题的解决方案
  • 我通过在 Microsoft Visual Studio 中“添加引用”和“使用 Bitmiracle.TiffCP;”来做到这一点,但我不知道如何使用 TiffCP 做到这一点

标签: c# libtiff.net


【解决方案1】:

TiffCP 是一个可执行文件,当您download 时,它与二进制文件一起打包。注意那个目录>> TiffCP.exe

这是我为示例所做的一个实现:

            System.Diagnostics.Process p = new System.Diagnostics.Process();
            p.StartInfo.UseShellExecute = false;
            p.StartInfo.RedirectStandardOutput = true;
            p.StartInfo.FileName = @"C:\PathToExe\TiffCP.exe";
            string path1 = @"C:\PathToImage\image.tiff";
            string path2 = @"C:\PathToImage\imagePage1.tiff";
            p.StartInfo.Arguments = "\"" + path1 + "\"" + ",0 \"" + path2 + "\"";
            p.Start();
            string t = p.StandardOutput.ReadToEnd();

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-02-23
    • 2015-11-05
    • 2013-01-26
    相关资源
    最近更新 更多