You are here: Visualization & Analysis > RAW file format

RAW file format

RAW format is a flexible file format for transferring documents between different applications and computer platforms. It is basically an import/export format rather than a storage format.

A RAW file has no predefined format, not even for image width and height, palettes, etc. RAW format consists of a stream of bytes describing the color information in the file.

Exporting RAW files

You have two options when exporting to RAW format: binary (.raw) or text (.txt).

To export to RAW format (binary):

  1. Choose File | Save As.
  2. Select RAW Image (binary) as the format.
  3. Click Save.
  4. In the Raw Image Export Options (binary) dialog box, select your settings.
  5. Click OK.

Raw Image Export Options dialog box (binary)

Image Specs

This section indicates the color mode, image size, and color depth.

Binary options

Output: For 8-bit and 16-bit images, this menu is disabled and only indicates the color depth shown in the Image Specs section. For images with a color depth of FP-32 bits/channel, you can select the output depth.

Channels order: Select either Interleaved or Planar. These options are disabled if grayscale is selected as the color mode. Interleaved refers to an image having the pixels stored contiguously; i.e., rgbrgbrgb. Planar means the color data is stored in separate 8-bit planes.

Byte order: For 8-bit images, this option is disabled. Select whether the byte order is for PC or Mac.

Alignment: Refers to the alignment of image data in file. Each row ends at a location, which is a multiple of 8 bits, 16 bits, 32 bits, or 64 bits.

Header: Enter the number of bytes in the file before the first byte of image data.

BGR (Reverse Colors): Select this check box to reverse the color order.

To export to RAW format (text):

  1. Choose File | Save As.
  2. Select RAW Image (text) as the format.
  3. Click Save.
  4. In the Raw Image Export Options (binary) dialog box, select your settings.
  5. Click OK.

Raw Image Export Options dialog box (text)

Image Specs

This section indicates the color mode, image size, and color depth.

Text options

Format: Select from Comma delimited, Tab delimited, Space delimited, Colon delimited, or Semicolon delimited.

Output: For 8-bit and 16-bit images, this menu is disabled and only indicates the color depth shown in the Image Specs section. For images with a color depth of FP-32 bits/channel, you can select the output depth.

Channels order: Select either Interleaved or Planar. These options are disabled if grayscale is selected as the color mode. Interleaved refers to an image having the pixels stored contiguously; i.e., rgbrgbrgb. Planar means the color data is stored in separate 8-bit planes.

BGR (Reverse Colors): Select this check box to reverse the color order.

Importing RAW files

You have three options when importing RAW files: binary (.raw), text (.txt), or comma separated values file (.csv).

Binary (.raw) is the most common selection since devices, like microscopes or various measuring equipment, produce binary (.raw) files.

To import RAW files:

  1. Choose File | Open.
  2. Select Raw Image as the format and navigate to the file.
  3. Click Open.
  4. In the Raw Image Import Options dialog box, select your settings.
  5. Click OK.

Raw Image Import Options dialog box

Input Data

Canvas normally detects the appropriate option. You can select either radio button.

Image specs

Mode: Select the color mode for the image: Grayscale, RGB, BGR, CMYK, LAB, or Multichannel.

Source: Select the source image type: 8 Bits/Channel, 16 Bits/Channel, 16 Bits/Channel signed, or Float-32 Bits/Channel.

Target: Select the target image type: 8 Bits/Channel, 16 Bits/Channel, or Float-32 Bits/Channel.

Height & Width: You must know these specifications to properly import the raw image.

Channels: The number of color channels depends on the image’s color mode.

Resolution: Set the resolution for the image. Use either pixels/in or pixels/cm.

Quantity: Indicates the number of images stored in the file.

Gap: Indicates the number of bytes from the end of one image to the beginning of the next.

Channels order: Select either Interleaved or Planar. These options are disabled if grayscale is selected as the color mode. Interleaved refers to an image having the pixels stored contiguously; i.e., rgbrgbrgb. Planar means the color data is stored in separate 8-bit planes.

Binary options

Byte order: Indicates whether the file originates from a PC or Mac.

Header: Enter the number of bytes in the file before the first byte of image data.

Alignment: Refers to the alignment of image data in memory. Each row ends at a memory location, which is a multiple of 8 bits, 16 bits, 32 bits, or 64 bits.