RasterImage Class |
Namespace: Aspose.PSD
The RasterImage type exposes the following members.
Name | Description | |
---|---|---|
![]() | RasterImage |
Initializes a new instance of the RasterImage class.
|
![]() | RasterImage(IColorPalette) |
Initializes a new instance of the RasterImage class.
|
Name | Description | |
---|---|---|
![]() | AutoAdjustPalette |
Gets or sets a value indicating whether automatic adjust palette.
(Inherited from Image.) |
![]() | BackgroundColor |
Gets or sets a value for the background color.
(Inherited from Image.) |
![]() | BitsPerPixel |
Gets the image bits per pixel count.
(Inherited from Image.) |
![]() | Bounds |
Gets the image bounds.
(Inherited from Image.) |
![]() | BufferSizeHint |
Gets or sets the buffer size hint which is defined max allowed size for all internal buffers.
(Inherited from Image.) |
![]() | Container |
Gets the Image container.
(Inherited from Image.) |
![]() | DataLoader |
Gets or sets the data loader.
|
![]() | DataStreamContainer |
Gets the object's data stream.
(Inherited from DataStreamSupporter.) |
![]() | Disposed |
Gets a value indicating whether this instance is disposed.
(Inherited from DisposableObject.) |
![]() | FileFormat |
Gets a value of file format
(Inherited from Image.) |
![]() | HasAlpha |
Gets a value indicating whether this instance has alpha.
|
![]() | HasBackgroundColor |
Gets or sets a value indicating whether image has background color.
(Inherited from Image.) |
![]() | HasTransparentColor |
Gets a value indicating whether image has transparent color.
|
![]() | Height |
Gets the image height.
(Inherited from Image.) |
![]() | HorizontalResolution |
Gets or sets the horizontal resolution, in pixels per inch, of this RasterImage.
|
![]() | ImageOpacity |
Gets opacity of this image.
|
![]() | InterruptMonitor |
Gets or sets the interrupt monitor.
(Inherited from Image.) |
![]() | IsCached |
Gets a value indicating whether object's data is cached currently and no data reading is required.
(Inherited from DataStreamSupporter.) |
![]() | IsRawDataAvailable |
Gets a value indicating whether raw data loading is available.
|
![]() | Palette |
Gets or sets the color palette. The color palette is not used when pixels are represented directly.
(Inherited from Image.) |
![]() | PremultiplyComponents |
Gets or sets a value indicating whether the image components must be premultiplied.
|
![]() | RawCustomColorConverter |
Gets or sets the custom color converter
|
![]() | RawDataFormat |
Gets the raw data format.
|
![]() | RawDataSettings |
Gets the current raw data settings. Note when using these settings the data loads without conversion.
|
![]() | RawFallbackIndex |
Gets or sets the fallback index to use when palette index is out of bounds
|
![]() | RawIndexedColorConverter |
Gets or sets the indexed color converter
|
![]() | RawLineSize |
Gets the raw line size in bytes.
|
![]() | Size |
Gets the image size.
(Inherited from Image.) |
![]() | TransparentColor |
Gets the image transparent color.
|
![]() | UpdateXmpData |
Gets or sets a value indicating whether to update the XMP metadata.
|
![]() | UseRawData |
Gets or sets a value indicating whether to use raw data loading when the raw data loading is available.
|
![]() | VerticalResolution |
Gets or sets the vertical resolution, in pixels per inch, of this RasterImage.
|
![]() | Width |
Gets the image width.
(Inherited from Image.) |
![]() | XmpData |
Gets or sets the XMP metadata.
|
Name | Description | |
---|---|---|
![]() | AdjustBrightness |
Adjust of a brightness for image.
|
![]() | AdjustContrast |
Image contrasting
|
![]() | AdjustGamma(Single) |
Gamma-correction of an image.
|
![]() | AdjustGamma(Single, Single, Single) |
Gamma-correction of an image.
|
![]() | BinarizeBradley(Double) |
Binarization of an image using Bradley's adaptive thresholding algorithm using the integral image thresholding
|
![]() | BinarizeBradley(Double, Int32) |
Binarization of an image using Bradley's adaptive thresholding algorithm using the integral image thresholding
|
![]() | BinarizeFixed |
Binarization of an image with predefined threshold
|
![]() | BinarizeOtsu |
Binarization of an image with Otsu thresholding
|
![]() | CacheData |
Caches the data and ensures no additional data loading will be performed from the underlying DataStreamContainer.
(Inherited from DataStreamSupporter.) |
![]() | CanSave |
Determines whether image can be saved to the specified file format represented by the passed save options.
(Inherited from Image.) |
![]() ![]() | Crop(Rectangle) |
Crops the specified rectangle.
|
![]() | Crop(Int32, Int32, Int32, Int32) |
Crop image with shifts.
|
![]() | Dispose |
Disposes the current instance.
(Inherited from DisposableObject.) |
![]() | Dither(DitheringMethod, Int32) |
Performs dithering on the current image.
|
![]() | Dither(DitheringMethod, Int32, IColorPalette) |
Performs dithering on the current image.
|
![]() | DoAfterSave |
Does the after save.
(Inherited from DataStreamSupporter.) |
![]() | DoUseRecursion |
Gets value indicating whether use recursion for synchronization.
(Overrides ImageDoUseRecursion(ImageImageOperation).) |
![]() | Equals | (Inherited from Object.) |
![]() | Filter |
Filters the specified rectangle.
|
![]() | Finalize | (Inherited from DisposableObject.) |
![]() | GetArgb32Pixel |
Gets an image 32-bit ARGB pixel.
|
![]() | GetCanNotSaveMessage |
Gets the can not save message.
(Inherited from Image.) |
![]() | GetDefaultArgb32Pixels |
Gets the default 32-bit ARGB pixels array.
|
![]() | GetDefaultOptions |
Gets the default options.
(Inherited from Image.) |
![]() | GetDefaultPixels |
Gets the default pixels array using partial pixel loader.
|
![]() | GetDefaultRawData(Rectangle, RawDataSettings) |
Gets the default raw data array.
|
![]() | GetDefaultRawData(Rectangle, IPartialRawDataLoader, RawDataSettings) |
Gets the default raw data array using partial pixel loader.
|
![]() | GetFitRectangle(Rectangle) |
Gets rectangle which fits the current image.
(Inherited from Image.) |
![]() | GetFitRectangle(Rectangle, Int32) |
Gets rectangle which fits the current bitmap taking into account the pixels passed. The passed pixels array count should be equal to the fitting rectangle size.
(Inherited from Image.) |
![]() | GetHashCode | (Inherited from Object.) |
![]() | GetImage2Export |
Gets the image to export.
(Inherited from Image.) |
![]() | GetModifyDate |
Gets the date and time the resource image was last modified.
|
![]() | GetOriginalOptions |
Gets the options based on the original file settings.
This can be helpful to keep bit-depth and other parameters of the original image unchanged.
For example, if we load a black-white PNG image with 1 bit per pixel and then save it using the
Save(String) method, the output PNG image with 8-bit per pixel will be produced.
To avoid it and save PNG image with 1-bit per pixel, use this method to get corresponding saving options and pass them
to the Save(String, ImageOptionsBase) method as the second parameter.
(Inherited from Image.) |
![]() | GetPixel |
Gets an image pixel.
|
![]() | GetSkewAngle |
Gets the skew angle.
This method is applicable to scanned text documents, to determine the skew angle when scanning.
|
![]() | GetType | (Inherited from Object.) |
![]() | Grayscale |
Transformation of an image to its grayscale representation
|
![]() | LoadArgb32Pixels |
Loads 32-bit ARGB pixels.
|
![]() | LoadArgb64Pixels |
Loads 64-bit ARGB pixels.
|
![]() | LoadCmyk32Pixels |
Loads pixels in CMYK format.
|
![]() | LoadCmykPixels | Obsolete.
Loads pixels in CMYK format.
This method is deprecated. Please use more effective the LoadCmyk32Pixels(Rectangle) method.
|
![]() | LoadPartialArgb32Pixels |
Loads 32-bit ARGB pixels partially by packs.
|
![]() | LoadPartialPixels |
Loads pixels partially by packs.
|
![]() ![]() | LoadPixels |
Loads pixels.
|
![]() | LoadRawData(Rectangle, RawDataSettings, IPartialRawDataLoader) |
Loads raw data.
|
![]() | LoadRawData(Rectangle, Rectangle, RawDataSettings, IPartialRawDataLoader) |
Loads raw data.
|
![]() | MemberwiseClone | (Inherited from Object.) |
![]() | NormalizeAngle |
Normalizes the angle.
This method is applicable to scanned text documents to get rid of the skewed scan.
This method uses GetSkewAngle and Rotate(Single) methods.
|
![]() | NormalizeAngle(Boolean, Color) |
Normalizes the angle.
This method is applicable to scanned text documents to get rid of the skewed scan.
This method uses GetSkewAngle and Rotate(Single, Boolean, Color) methods.
|
![]() | OnDataStreamContainerChanging |
Called when data stream container is changing.
(Inherited from DataStreamSupporter.) |
![]() | OnPaletteChanged |
Called when palette is changed.
(Inherited from Image.) |
![]() | OnPaletteChanging |
Called when palette is changing.
(Inherited from Image.) |
![]() | ReadArgb32ScanLine |
Reads the whole scan line by the specified scan line index.
|
![]() | ReadScanLine |
Reads the whole scan line by the specified scan line index.
|
![]() | ReleaseManagedResources |
Releases the managed resources. Make sure no unmanaged resources are released here, since they may have been already released.
(Overrides ImageReleaseManagedResources.) |
![]() | ReleaseUnmanagedResources |
Releases the unmanaged resources. Make sure no managed resources are released here, since they may have been already released.
(Inherited from DisposableObject.) |
![]() | ReplaceColor(Int32, Byte, Int32) |
Replaces one color to another with allowed difference and preserves original alpha value to save smooth edges.
|
![]() | ReplaceColor(Color, Byte, Color) |
Replaces one color to another with allowed difference and preserves original alpha value to save smooth edges.
|
![]() | ReplaceNonTransparentColors(Int32) |
Replaces all non-transparent colors with new color and preserves original alpha value to save smooth edges.
Note: if you use it on images without transparency, all colors will be replaced with a single one.
|
![]() | ReplaceNonTransparentColors(Color) |
Replaces all non-transparent colors with new color and preserves original alpha value to save smooth edges.
Note: if you use it on images without transparency, all colors will be replaced with a single one.
|
![]() ![]() | Resize(Int32, Int32) |
Resizes the image. The default LeftTopToLeftTop is used.
(Inherited from Image.) |
![]() | Resize(Int32, Int32, ImageResizeSettings) |
Resizes the image with extended options.
(Overrides ImageResize(Int32, Int32, ImageResizeSettings).) |
![]() | Resize(Int32, Int32, ResizeType) |
Resizes the image.
(Overrides ImageResize(Int32, Int32, ResizeType).) |
![]() | ResizeHeightProportionally(Int32) |
Resizes the height proportionally.
(Inherited from Image.) |
![]() | ResizeHeightProportionally(Int32, ImageResizeSettings) |
Resizes the height proportionally.
(Inherited from Image.) |
![]() | ResizeHeightProportionally(Int32, ResizeType) |
Resizes the height proportionally.
(Inherited from Image.) |
![]() | ResizeWidthProportionally(Int32) |
Resizes the width proportionally.
(Inherited from Image.) |
![]() | ResizeWidthProportionally(Int32, ImageResizeSettings) |
Resizes the width proportionally.
(Inherited from Image.) |
![]() | ResizeWidthProportionally(Int32, ResizeType) |
Resizes the width proportionally.
(Inherited from Image.) |
![]() | Rotate(Single) |
Rotate image around the center.
|
![]() | Rotate(Single, Boolean, Color) |
Rotate image around the center.
|
![]() ![]() | RotateFlip |
Rotates, flips, or rotates and flips the image.
(Inherited from Image.) |
![]() | Save |
Saves the image data to the underlying stream.
(Inherited from Image.) |
![]() | Save(Stream) |
Saves the object's data to the specified stream.
(Inherited from DataStreamSupporter.) |
![]() | Save(String) |
Saves the object's data to the specified file location.
(Inherited from DataStreamSupporter.) |
![]() | Save(String, Boolean) |
Saves the object's data to the specified file location.
(Inherited from DataStreamSupporter.) |
![]() ![]() | Save(Stream, ImageOptionsBase) |
Saves the image's data to the specified stream in the specified file format according to save options.
(Inherited from Image.) |
![]() ![]() | Save(String, ImageOptionsBase) |
Saves the object's data to the specified file location in the specified file format according to save options.
(Inherited from Image.) |
![]() | Save(String, ImageOptionsBase, Rectangle) |
Saves the object's data to the specified file location in the specified file format according to save options.
(Inherited from Image.) |
![]() | Save(Stream, ImageOptionsBase, Rectangle) |
Saves the image's data to the specified stream in the specified file format according to save options.
(Overrides ImageSave(Stream, ImageOptionsBase, Rectangle).) |
![]() | SaveArgb32Pixels |
Saves the 32-bit ARGB pixels.
|
![]() | SaveCmyk32Pixels |
Saves the pixels.
|
![]() | SaveCmykPixels | Obsolete.
Saves the pixels.
This method is deprecated. Please use more effective the SaveCmyk32Pixels(Rectangle, Int32) method.
|
![]() | SaveData |
Saves the data.
(Inherited from DataStreamSupporter.) |
![]() ![]() | SavePixels |
Saves the pixels.
|
![]() | SavePixelsInternal |
Saves pixels (format specific method).
|
![]() | SaveRawData |
Saves the raw data.
|
![]() | SetArgb32Pixel |
Sets an image 32-bit ARGB pixel for the specified position.
|
![]() | SetPalette |
Sets the image palette.
(Overrides ImageSetPalette(IColorPalette, Boolean).) |
![]() | SetPixel |
Sets an image pixel for the specified position.
|
![]() | SetResolution |
Sets the resolution for this RasterImage.
|
![]() | ToBitmap |
Converts raster image to the bitmap.
|
![]() | ToString | (Inherited from Object.) |
![]() | UpdateMetadata |
Updates the image metadata.
|
![]() | VerifyNotDisposed |
Verifies that the current instance is not disposed.
(Inherited from DisposableObject.) |
![]() | WriteArgb32ScanLine |
Writes the whole scan line to the specified scan line index.
|
![]() | WriteScanLine |
Writes the whole scan line to the specified scan line index.
|
Name | Description | |
---|---|---|
![]() | Timeout |
The timeout to wait for synchronization
(Inherited from DataStreamSupporter.) |
![]() | xmpData |
The XMP metadata
|
[C#] //Create an instance of MemoryStream using (System.IO.MemoryStream stream = new System.IO.MemoryStream()) { //Create an instance of PsdOptions and set its various properties including the Source property Aspose.PSD.ImageOptions.PsdOptions psdOptions = new Aspose.PSD.ImageOptions.PsdOptions(); psdOptions.Source = new Aspose.PSD.Sources.StreamSource(stream); //Create an instance of Image using (Aspose.PSD.RasterImage image = (Aspose.PSD.RasterImage)Aspose.PSD.Image.Create(psdOptions, 500, 500)) { //Get the pixels of image by specifying the area as image boundary Aspose.PSD.Color[] pixels = image.LoadPixels(image.Bounds); //Loop over the Array and sets color of alrenative indexed pixel for (int index = 0; index < pixels.Length; index++) { if (index % 2 == 0) { //Set the indexed pixel color to yellow pixels[index] = Aspose.PSD.Color.Yellow; } else { //Set the indexed pixel color to blue pixels[index] = Aspose.PSD.Color.Blue; } } //Apply the pixel changes to the image image.SavePixels(image.Bounds, pixels); // save all changes. image.Save(); } //Write MemoryStream to File stream.WriteTo(new System.IO.FileStream(@"C:\temp\output.psd", System.IO.FileMode.CreateNew)); }