PhotoController a .NET assembly that processes image in ASP.NET and Windows.Forms. The component itself is writen in C#, and it is able to work with C#, VB.NET, C++ or other languages in .NET environment. It reads all .NET supported Image types (Bmp, Emf, Exif, GIF, Jpeg, TIF, Wmf, Icon, etc.); it can perform compression on Jpeg, GIF, and TIF directly to a file or an Image object. All methods return System.Drawing.Image object that you can operate on it easily in your application.
PhotoController is currently having two versions: 2.x and 1.2. Version 1.2 works only for Visual Studio.NET 2003 and .NET framework 1.x. There are many significant differences between version 1.2 and version 2.x. The latest version works with Visual Studio.NET 2005 and 2008, and it is much more flexible and robust. It's recommended to use version 2.x; furthermore, version 1.2 has stopped development. ImageComponent.NET will only focus on upgrading version 2.x.
Arbirary Transformation
The component can apply arbitrary transformation: rotation, resize, scale, and change the canvas size. Image rotation is always tricky. As we know, when rotating an image, if the canvas size is unchanged, then you might lose part of the image portaion. PhotoController, however, will automatically adjust the canvas size to make sure your rotated image can be fully displayed. Resize and Scale are different. Resize enables to change the original picture's width and height to any new value, either increase or decrease. Scale lets you pass a size of a container( ie. a rectangle), then you could get a resized picture to fit in the container. In PhotoController, you can also easily change the canvas size and specify where the original image will locate; all the calculation will be finished by the component.
Color Adjustment
PhotoController provides a series of color adjustment filters that you can play with.
| InvertColorFilter |
GrayScaleFilter |
GreyFilter |
| SepiaFilter |
LightnessFilter |
DarknessFilter |
| ContrastFilter |
BlackWhiteFilter |
HSLAdjustFilter |
| SolarizeFilter |
GammaFilter |
AutoColorEnhanceFilter |
The following figure is a colorful rose picture that was taken from my backyard, and below that there are three figures after color adjustment:
(1) Invert
(2) Sepia adjustment
(3) HSL adjustment
Image Filters
The component supports various image processing filter effects. You can easily use each of them by initializing the class and specify its properties, then pass to the Filter method.
| SmoothFilter |
GaussianBlurFilter |
DeepBlurFilter |
| LinearBlurFilter |
RadialBlurFilter |
ZoomBlurFilter |
| BombWaveFilter |
BookFoldFilter |
AdditionCompositeFilter |
| DifferenceCompositeFilter |
ColorBlendFilter |
MultiplyCompositeFilter |
| LightenCompositeFilter |
DarkenCompositeFilter |
ScreenCompositeFilter |
| ExclusiveCompositeFilter |
SimilarityRemovalFilter |
DiffuseFilter |
| DitherFilter |
NoiseFilter |
EdgeDetectSobelFilter |
| EdgeDetectPrewittFilter |
EdgeDetectKirshFilter |
EdgeDetectFreiChenFilter |
| EdgeDetectRobertsFilter |
EdgeDetectDiferenceFilter |
EmbossFilter |
| EngraveFilter |
GlassBorderFilter |
MarbleFilter |
| MosaicFilter |
RadialBlurFilter |
ZoomBlurFilter |
| OilFilter |
RainbowFilter |
RedEyeFilter |
| ShakeFilter |
SharpenFilte |
MeanRemovalFilter |
| ShearFilter |
SphereFilter |
SpreadFilter |
| TwirlFilter |
WaterFilter |
WaterRippleFilter |
| WindFilter |
|
|
The following figures demonstrate three filters, which are:
(1) Mosaic
(2) Oil
(3) Water Ripple
Image Feather
Feather is an operation that obscurs the edge of a specified area of the image to give a fancy look. In PhotoController, you can specify any area as you like (rectangle, ellipse, polygon, closed curves, and so on), even more, you can customize an area by using GraphicsPath. By Feathering the image, the image portion within the defined area will be still clear, but everything outside the area will be obscurred gradually. You can use either a specific color or another image for the outside area. If you use a lower value to obscur the edge, you can achieve some speical effect (hint: like a frame). The following three figures demonstrate the result of feather:
(1) Feather a rectangle area by color Yellow
(2) Feather a rectangle area by color Green
(3) Feather a rectangle area by another image
Read the tutorial immediately to learn how to feather an image with PhotoController by using C#/VB.NET.
Writing Borders
PhotoController supports to write borders to all four edges of the image. You can use many built-in border effects to frame your image. There are three samples of them:
It's recommended to download our free open source demo application PhotoGear to experience all functionalities, and you can learn more by reading the code implementation.
[Back to Top]