How to C#: Imaging
Using Imaging SDK for C#.NET
Winforms Controls
Image Load
Image Access and Modify
Effect: Special
Effect: Special
Home ›› XImage.Raster ›› C# Raster: Special Effects

How to C#: Special Effects

Overview for Special Effects

Related .net document control helps: pdf page: ASP.NET PDF Pages Edit Control: add, remove, sort, replace PDF pages online using C# text file viewer: ASP.NET Text file viewer in MVC, WebForms: Open, view, annotate, convert txt files in C# ASP.NET document viewer: EdgeDoc:ASP.NET Document Viewer C# Control: Open, view, annotate, redact, convert documents online in C#, VB.NET, AS... image viewer: ASP.NET Image Viewer Control(MVC & WebForms): view, annotate, redact, convert image files in html, JQuery document viewer c#: ASP.NET Document Viewer using C#: Open, View, Annotate, Redact, Convert document files in ASP.NET using C#, HTML5, JQuer... tiff viewer: ASP.NET Tiff Viewer: view, annotate multipage Tiff images in ASP.NET MVC, WebForms using C# Control mvc document viewer: ASP.NET MVC Document Viewer: view, annotate, redact files on ASP.NET MVC web projects


By using the XImage.Raster SDK, you can get and modify special effects of image by assigning to processor. The related properties are as follows.


Add specific type(NosiType enumeration) noise to the image.


Lighten or darken the edge of the image to simulate a 3D button effect.


Detect a wide range of edges in the image.


Stimulate a charcoal sketch.


If the pixel value is below zero, then set it to zero, if the pixel value above quantum range(e.g. 65535 or 255), then set it to quantum range.


Get the specific sub-region of the original image


Distort the image with a variety of distort methods, such as Perspective ,Bilinear, barrel and so on.


Compare two images.


Decipher the image with specified pass phrase.


Highlight the image edge.


A digital filter will be applied to the noisy image to improve it’s quality.


Set the image to current background color, the background color can be set by:ImageProcess.BackgroundColor = Color.Red.


Encipher the image with specified pass phrase.


Stereo image. you should have two images: left.png and right.png.

Firstly, call SepareteImageChannel(ChannelType.Red) to get a grayscale image which extract form the left.png image's red channel. Then call SepareteImageChannel(ChannelType.Blue) to get a grayscale image which extract form the right.png image's blue channel. Next, call this method. At last, View the result with red-blue glasses.


Surround the image with a three-dimensional border.


Use with CannyEdgeImage method to identify lines in the image.


Implode image pixel with the specified percentage.


An edge preserving filter will be applied to the image to reduce the noise.


Level the pixel between the black point and white point.


Double the image size.


Half the image size.


Get the darkest pixel value and map 2% of it to all the pixels, get the brightest pixel value and map 1% of it to all the pixels.


A filter will be applied to the image to simulate a oil painting effect.


Simulates a pencil sketch


Use the peak elimination filter to reduce the image noise.


Rotate image pixel with the specified angle.


Repeatedly tiles the image(texture) on the original image background.


Shift the image pixel along a sin wave to simulate a wave effect.

Steps to Modify Image Special Effects

Load an image with RasterImage object.

Create an image processor with ImageProcess object.

Call the responding method of ImageProcess object to complete the task flopping image.

Save the modified image to an image file on the disk.

In order to acheive the work, please refer to the following steps.

Install XImage.Raster in C# Project

Add necessary references to your C#.NET project. Right-click the project and select "Add Reference..." to locate and add the following DLLs as project references;




Use corresponding namespaces;

  using RasterEdge.XImage.Raster;

Note: When you get the error "Could not load file or assembly 'RasterEdge.Imaging.Basic' or any other assembly or one of its dependencies. An attempt to load a program with an incorrect format", please check your configure as follows:


       If you are using x64 libraries/dlls, Right click the project -> Properties -> Build -> Platform target: x64.


       If using x86, the platform target should be x86.

Modify Image Special Effects

Sample Code (Image Effect3D):

RasterImage leftImage = new RasterImage(@"F:\Source1.png");
RasterImage rightImage = new RasterImage(@"F:\Source2.png");
ImageProcess processLeft = new ImageProcess(leftImage);
ImageProcess processRight = new ImageProcess(rightImage);
//get red channel of the image and returned it as a grayscale image
//get blue channel of the image and returned it as a grayscale image