Guide for VB.NET
Core Document Formats
Tiff Image Compress
Additional Features

VB.NET TIFF - Compress TIFF File in VB.NET

VB.NET APIs & Sample Codes for TIFF File Compression in .NET Project

VB.NET
Home > .NET Imaging SDK > VB.NET > Compress TIFF

"This online guide content is Out Dated!
    Please get the latest XDoc.Tiff C# Developer Guide here.
"

TIFF, different from other image formats, can be both lossless and lossy. In daily life application, TIFF is more often used as a lossless image format which uses no compression method. But a TIFF file without using any compressing method will always have a large file size, which may cause some problems in image storage and transmission. Under this condition, you may need to make the source TIFF file smaller by using proper image compression methods.
Related .net document control helps:
asp.net pdf editor component: EdgePDF: ASP.NET PDF Editor Web Control: Online view, annotate, redact, edit, process, convert PDF documents
asp.net mvc image viewer: ASP.NET Image Viewer Control(MVC & WebForms): view, annotate, redact, convert image files in html, JQuery
asp.net view powerpoint: ASP.NET PowerPoint Document Viewer Control (MVC & WebForms): view ppt, pptx files online in C# using ASP.NET
asp.net edit pdf image using c#: ASP.NET PDF Image Edit Control: online insert, edit PDF images in C#
asp.net pdf editor component: EdgePDF: ASP.NET PDF Editor Web Control: Online view, annotate, redact, edit, process, convert PDF documents
asp.net mvc image viewer: ASP.NET Image Viewer Control(MVC & WebForms): view, annotate, redact, convert image files in html, JQuery
asp.net view powerpoint: ASP.NET PowerPoint Document Viewer Control (MVC & WebForms): view ppt, pptx files online in C# using ASP.NET
This online VB.NET TIFF image compression tutorial page will be extended from following aspects.
  • What VB.NET APIs are offered for TIFF image compression?
  • What VB.NET demo code is used to compress TIFF document file?
  • How many image compression types are supported for TIFF document image format?
Compression APIs
This VB.NET TIFF image compression component mainly offers developers following three kinds of interfaces for TIFF compression.
  • When you are generating a TIFFPage object with one image source, you can choose which image compression type to use in Visual Basic .NET.
  • When you are creating a multi-page TIFFDocument with a collection of image objects, you can choose different image compression algorithms for different TIFF pages.
  • If you want to add an image into an existing TIFF document file, you can also select suitable compression type to compress the embeded image.
Private Sub New(img As REImage, compression As TIFFCompression)
End Sub
Private Sub New(imgs As List(Of REImage), compressions As List(Of TIFFCompression))
End Sub
Private Sub AddImage(img As REImage, positionX As Single, postionY As Single, compression As TIFFCompression) Implements TIFFPage.AddImage
End Sub
APIs Explanations: in above VB.NET TIFF compression APIs, we mention the concepts of TIFFPage and TIFFDocument. Considering this may be your first time interacting with RasterEdge TIFF reading & manipulating control SDK, we here specifically illustrate the meaning of above two programming concepts.
  • TIFFDocument: RasterEdge .NET TIFF processor component SDK uses this programming class to represent one in-memory TIFF document file. That means when you decode a TIFF file into your VB.NET class application, this class will generate a TIFFDocument object to represent it. And this VB.NET TIFF image compressing component add-on can create a TIFFDocument object by loading source TIFF file from web server or PC local file.
  • TIFFPage: this programming class exists as a method to display one page within a TIFFDocument object. And this .NET class is derived from super class REPage.
VB.NET Sample Code
From this section, you will find three separate VB.NET demo codes which will help you compress target TIFF file with above mentioned three different compression APIs. To make this VB.NET TIFF compression component add-on successfully work in your project, please make sure you have installed .NET Framework 2.0 or later versions and Microsoft Visual Studio 2005 or greater.
''' <summary>
''' Create TIFF page with specified compression
''' </summary>
''' <param name="img"></param>
''' <param name="compression"></param>
''' <returns></returns>
Public Function CreateTIFFPageWithCompression(img As REImage, compression As TIFFCompression) As TIFFPage
Return New TIFFPage(img, compression)
End Function

''' <summary>
''' Create a TIFF document with specified compression type for each page
''' </summary>
''' <param name="img"></param>
''' <param name="compressions"></param>
''' <returns></returns>
Public Function CreateTIFFDocumentWithCompression(imgs As List(Of REImage), compressions As List(Of TIFFCompression)) As TIFFDocument
Return New TIFFDocument(imgs, compressions)
End Function

''' <summary>
''' Specify image compression type when adding image to page
''' </summary>
''' <param name="img"></param>
''' <param name="page"></param>
''' <param name="compression"></param>
''' <returns></returns>
Public Function AddImageToTIFFPageWithCompression(img As REImage, page As TIFFPage, compression As TIFFCompression, x As Single, y As Single) As TIFFPage
page.AddImage(img, x, y, compression)
Return page
End Function
Apart from these VB.NET sample codes, we also offers a detailed programming tutorial on how to compress TIFF document image file using C# code.

TIFF Compression Types

This VB.NET TIFF compression library plug-in enables developers to compress TIFF file with one or more TIFF image compression types. And nowadays, TIFF document image file supports several compression algorithms, including CCITT Group 3 (Bitonal images), CCITT Group 4 (Bitonal images), LZW that is popular for color and grayscale images, PackBits and JPEG which is seldom used in TIFF image format. Among these common TIFF image compression types, LZW is more often used to compress TIFF image format.
Besides this VB.NET TIFF image compressing guide, RasterEdge TIFF processing library SDK also provides other user manuals for VB.NET TIFF processing applications. We have listed some of the TIFF file editing features and tutorials below:
More Tutorials!


Recommend this to Google+


RasterEdge.com is professional provider of ASP.NET MVC Document Viewer, ASP.NET PDF Viewer, MVC PDF Viewer document, content and imaging solutions, available for ASP.NET AJAX, Silverlight, Windows Forms as well as WPF. We are dedicated to provide powerful & profession imaging controls, PDF document, image to pdf files and components for capturing, viewing, processing, converting, compressing and stroing images, documents and more.

©2000-2017 Raster Edge.com