【问题标题】:VB.NET Tool for Image Printing - Quality Ajustments用于图像打印的 VB.NET 工具 - 质量调整
【发布时间】:2012-05-25 16:27:34
【问题描述】:

我正在开发一种使用佳能 selpy cp800 轻松进行图片打印的工具。使用以下方法打印图像:

Private Sub BtnPrintClick(sender As Object, e As System.EventArgs) Handles ptnPrint.Click
    If PrintDialog1.ShowDialog() = DialogResult.OK Then
        pdPrintImage.Print()
    End If
End Sub

Private Sub PdPrintImagePrintPage(sender As Object, e As System.Drawing.Printing.PrintPageEventArgs) Handles pdPrintImage.PrintPage
    e.Graphics.DrawImage(_dPictures(_sPictures(_iActiveImage)).Picture, e.Graphics.VisibleClipBounds)
End Sub

_dPictures(_sPictures(_iActiveImage)).Picture --> image 类型的对象

我没有对这张图片做任何事情。它仅使用 Image.FromFile() 方法加载。

在下图中,您可以看到我的问题。这是使用此方法打印的图像的扫描(顶部)和使用 windows 图片查看器打印的相同图像的扫描。你看,你看到的第一张图像背景和阴影中的色调错误。

有人想解决这个问题吗?

【问题讨论】:

  • 看起来有点深度问题..或抖动..

标签: vb.net printing image


【解决方案1】:

如果不是 Boo 提到的位深度问题,设置其中一个或两个可能会有所帮助

e.Graphics.InterpolationMode = Drawing2D.InterpolationMode.HighQualityBicubic
e.Graphics.SmoothingMode = Drawing2D.SmoothingMode.HighQuality

在进行 .DrawImage 之前。

【讨论】:

    【解决方案2】:

    我达到的最佳质量如下: 1)我使用组件 iTextsharp 将图片放入 pdf 中。 2)打印pdf

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2016-07-29
      • 2010-11-12
      • 1970-01-01
      • 1970-01-01
      • 2012-06-20
      • 2010-11-29
      • 2014-02-17
      相关资源
      最近更新 更多