Home >
.NET Imaging SDK >
C# >
JPEG 2000 Codec
If this is your first time to use our DocImageSDK, we strongly suggest you reading How to Start first!
JPEG 2000 Codec technology developed by RasterEdge can be used for compressing and decompressing JPEG 2000 files, multiple functions are provided for users:
- Read & Write JPEG 2000 image and JPEG 2000 multipage document
- Detect JPEG 2000 image resolution, color, position and quality
- Set the coder options for faster compression / decompression
- More compression & decompression functions
Compress and Decompress JPEG 2000 Image in C#
This guide tells users how to use JPEG 2000 Codec with RasterEdge .NET Imaging SDK and JPEG 2000 Codec using Visual C# sample codes. (For VB.NET developers, please go to
JPEG 2000 Codec for VB.NET. Want to view Image and document in WinForms or Web applications,
JPEG 2000 Codec in WinForms and
Web Document Image JPEG 2000 Codec.)
- Open Microsoft Visual Studio 2005/2008/2010;
- Create a Visual C#.NET project;
- Activate .NET Imaging SDK license and copy created "RasterEdgeLicense.txt" to the new project folder, together with .NET Imaging SDK DLL(s);
- Add RasterEdge DocImageSDK & RasterEdge.Imaging.Jpeg2000.dll to this Visual C# project;
- Call RasterEdge DocImageSDK & JPEG 2000 Codec Namespace.
using System.IO;
using System.Drawing.Printing;
using RasterEdge.Imaging;
using RasterEdge.Imaging.Processing;
using RasterEdge.Imaging.Jpeg2000;
Encode Image Using JPEG 2000 Codec in C#
The following C# code shows how to setup .NET Imaging SDK to decode JP2 images.
Jp2Decoder jp2 = new Jp2Decoder();
RegisteredDecoders.Decoders.Add(jp2);
Get JPEG 2000 Image Information in C#
The following code shows how to get JPEG 2000 image information.
Jp2ImageInfo info = (Jp2ImageInfo)RegisteredDecoders.GetImageInfo("myimage.jp2");
Console.WriteLine(info.FileFormat); Reset JPEG 2000 Decoder in C#
The following code shows how to reset JPEG 2000 decoder properties.
JpegDecoder jpeg =
(JpegDecoder)RegisteredDecoders.GetDecoderFromType(typeof(JpegDecoder));
jpeg.ScaleFactor = JpegScaleFactor.Half;
More Tutorials!
Find more user guides with RasteEdge .NET Image SDK using Visual C# sample codings!
Want to install Imaging SDK in Winforms or Web applications, please go to
Use Imaging SDK in Winforms and
Web Document Image Viewer.
Recommend this to Google+