AiImage Class |
Namespace: Aspose.PSD.FileFormats.Ai
The AiImage type exposes the following members.
Name | Description | |
---|---|---|
![]() | AiImage | Initializes a new instance of the AiImage 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.
(Overrides ImageBitsPerPixel.) |
![]() | 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.) |
![]() | DataSection |
Gets the data section.
|
![]() | 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
(Overrides ImageFileFormat.) |
![]() | FinalizeSection |
Gets the finalize section.
|
![]() | HasBackgroundColor |
Gets or sets a value indicating whether image has background color.
(Inherited from Image.) |
![]() | Header |
Gets the header.
|
![]() | Height |
Gets the image height.
(Overrides ImageHeight.) |
![]() | 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.
(Overrides DataStreamSupporterIsCached.) |
![]() | Layers |
Gets the layer sections.
|
![]() | Palette |
Gets or sets the color palette. The color palette is not used when pixels are represented directly.
(Inherited from Image.) |
![]() | SetupSection |
Gets the setup section.
|
![]() | Size |
Gets the image size.
(Inherited from Image.) |
![]() | Version |
Gets the version of Adobe Illustrator format
|
![]() | Width |
Gets the image width.
(Overrides ImageWidth.) |
Name | Description | |
---|---|---|
![]() | AddLayer |
Adds the AI layer section.
|
![]() | CacheData |
Caches the data and ensures no additional data loading will be performed from the underlying DataStreamContainer.
(Overrides DataStreamSupporterCacheData.) |
![]() | CanSave |
Determines whether image can be saved to the specified file format represented by the passed save options.
(Inherited from Image.) |
![]() | Dispose |
Disposes the current instance.
(Inherited from DisposableObject.) |
![]() | Equals | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
![]() | GetDefaultOptions |
Gets the default options.
(Inherited from Image.) |
![]() | GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() | 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.) |
![]() | GetType | Gets the type of the current instance. (Inherited from Object.) |
![]() ![]() | Resize(Int32, Int32) |
Resizes the image. The default LeftTopToLeftTop is used.
(Inherited from Image.) |
![]() | Resize(Int32, Int32, ImageResizeSettings) |
Resizes the image.
(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.) |
![]() | RotateFlip |
Rotates, flips, or rotates and flips the image.
(Overrides ImageRotateFlip(RotateFlipType).) |
![]() | 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(Stream, ImageOptionsBase, Rectangle) |
Saves the image's data to the specified stream 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.) |
![]() | SetPalette |
Sets the image palette.
(Overrides ImageSetPalette(IColorPalette, Boolean).) |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object.) |
[C#] string sourceFilePath = "rect2_color.ai"; string outputFilePath = "rect2_color.ai_output.pdf"; using (AiImage image = (AiImage)Image.Load(sourceFilePath)) { image.Save(outputFilePath, new PdfOptions()); }
[C#] string sourceFileName = "form_8.ai"; string outputFileName = "form_8_export"; using (AiImage image = (AiImage)Image.Load(sourceFileName)) { image.Save(outputFileName + ".psd", new PsdOptions()); image.Save(outputFileName + ".png", new PngOptions() { ColorType = PngColorType.TruecolorWithAlpha }); }
[C#] string[] sourcesFiles = new string[] { @"34992OStroke", @"rect2_color", }; for (int i = 0; i < sourcesFiles.Length; i++) { string name = sourcesFiles[i]; string sourceFileName = name + ".ai"; using (AiImage image = (AiImage)Image.Load(sourceFileName)) { string outFileName = name + ".psd"; ImageOptionsBase options = new PsdOptions(); image.Save(outFileName, options); outFileName = name + ".png"; options = new PngOptions() { ColorType = PngColorType.TruecolorWithAlpha }; image.Save(outFileName, options); outFileName = name + ".jpg"; options = new JpegOptions() { Quality = 85 }; image.Save(outFileName, options); outFileName = name + ".gif"; options = new GifOptions() { DoPaletteCorrection = false }; image.Save(outFileName, options); outFileName = name + ".tif"; options = new TiffOptions(TiffExpectedFormat.TiffDeflateRgba); image.Save(outFileName, options); } }