Class BmpOptions

BmpOptions class

The bmp file format creation options.

public class BmpOptions : ImageOptionsBase

Constructors

NameDescription
BmpOptions()Initializes a new instance of the BmpOptions class.
BmpOptions(BmpOptions)Initializes a new instance of the BmpOptions class.

Properties

NameDescription
BitsPerPixel { get; set; }Gets or sets the image bits per pixel count.
BufferSizeHint { get; set; }Gets or sets the buffer size hint which is defined max allowed size for all internal buffers.
Compression { get; set; }Gets or sets the compression.
virtual DefaultReplacementFont { get; set; }Gets or sets the default replacement font (font that will be used to draw text when exporting to raster, if existing layer font in PSD file is not presented in system). To take proper name of default font can be used next code snippet: System.Drawing.Text.InstalledFontCollection col = new System.Drawing.Text.InstalledFontCollection(); System.Drawing.FontFamily[] families = col.Families; string defaultFontName = families[0].Name; PsdLoadOptions psdLoadOptions = new PsdLoadOptions() { DefaultReplacementFont = defaultFontName });
Disposed { get; }Gets a value indicating whether this instance is disposed.
FullFrame { get; set; }Gets or sets a value indicating whether [full frame].
MultiPageOptions { get; set; }The multipage options
virtual Palette { get; set; }Gets or sets the color palette.
ProgressEventHandler { get; set; }Gets or sets the progress event handler.
virtual ResolutionSettings { get; set; }Gets or sets the resolution settings.
Source { get; set; }Gets or sets the source to create image in.
VectorRasterizationOptions { get; set; }Gets or sets the vector rasterization options.
virtual XmpData { get; set; }Gets or sets the XMP metadata container.

Methods

NameDescription
virtual Clone()Clones this instance.
Dispose()Disposes the current instance.

Examples

This example demonstrates the use of different classes from SaveOptions Namespace for export purposes. An image of type Psd is loaded into an instance of Image and then exported out to several formats.

[C#]

//Load an existing image in an instance of Image class
using (Aspose.PSD.Image image = Aspose.PSD.Image.Load(@"C:\temp\image.psd"))
{
    //Export to BMP file format using the default options
    image.Save(@"C:\temp\output.bmp", new Aspose.PSD.ImageOptions.BmpOptions());

    //Export to JPEG file format using the default options
    image.Save(@"C:\temp\output.jpeg", new Aspose.PSD.ImageOptions.JpegOptions());

    //Export to JPEG 2000 file format using the default options
    image.Save(@"C:\temp\output.jp2", new Aspose.PSD.ImageOptions.Jpeg2000Options());

    //Export to PNG file format using the default options
    image.Save(@"C:\temp\output.png", new Aspose.PSD.ImageOptions.PngOptions());

    //Export to TIFF file format using the default options
    image.Save(@"c:\temp\output.tiff", new Aspose.PSD.ImageOptions.TiffOptions(Aspose.PSD.FileFormats.Tiff.Enums.TiffExpectedFormat.Default));
}

See Also