ImageGear .NET v25.2 - Updated
Developer Guide / File Formats and Compressions / File Formats / File Formats Reference / XWD
In This Topic
    XWD
    In This Topic
    Full Name XWD (X Window Dump)
    Format ID ImGearFormats.XWD
    File Extension(s) *.xwd, *.wd (for Unix)
    Data Type Raster Image
    Data Encoding Binary
    Multi-Page Support No
    Alpha Channel Support No
    Metadata Update Support No
    ImageGear Platforms Support WIN32, WIN64, Unix, Unix64, .NET, .NET64, MAC

    ImageGear Supported Versions

    ImageGear Supported Features

    ImageGear Read Support

    ImageGear Write Support

    ImageGear Filter Control Parameters

    None

    Comments

    An XWD file can contain a representation of the window, the background, or the entire screen display. It has been designed to be a very versatile, device-independent format. See also XBM, XPM.

    The general structure of the XWD graphics format begins with a long header, that is sometimes followed by a palette and contains the bitmap data. The header contains integer data and stores the header size, the XWD version, the size and location of the bitmap, the window size, location, and border width. A ByteOrder field indicates whether the bytes are stored in big-endian or little-endian order.

    In the interest of making this format device-independent, the XWD supports six "visual classes" and three image formats. The visual class code is stored in the visual_class field of the header, and represents the following categories:

    The image-format categories, whose codes are stored in the pixmap_format field of the header, are called XYBitmap (1-bit), XYPixmap (single plane), and ZPixmap (two or more planes).

    Where the value of pixmap_format indicates GrayScale, PseudoColor or DirectColor, a palette follows the header.

    The image data is the last structure in the file. The bytes are stored in rows with groupings called "units", whose lengths are determined by the bitmap_unit field of the header.

    If the pixmap_format field is 1, indicating an XYPixmap, there are multiple representations of the bitmap data, one for each color plane, where the first bitmap represents the highest bit of the data; the second bitmap represents the second-highest bit, and so on. An image with a bit depth of 4 yields a file with four bitmaps.

    References Used

    Brown, C. Wayne, and Barry J. Shepherd. Graphics File Formats: Reference and Guide. Greenwich, CT.: Manning Publications, 1992.

    Kay, David C. and John R. Levine. Graphics File Formats. Windcrest Books, 1992.

    Murray, James D. and William vanRyper. Encyclopedia of Graphics File Formats. Sebastopol, CA: O'Reilly & Associates, Inc., 1994.