Skip header
 

Printable CALS files

The following restrictions apply to CALS files that can be printed using RTIFF. Only CALS files that have bitmap image data in CALS Raster (Type 1) format can be printed.

Header (CALS file)

CALS data must include a header block that is compliant with the following conditions:

  • The header block requires the following eleven header records to be entered at the top in the order shown in the data structure diagram.

    Header block

    Byte

    Record ID and value

    0

    srcdocid: (Optional)

    128 (0x80)

    dstdocid: (Optional)

    258 (0x100)

    txtfilid: (Optional)

    348 (0x180)

    figid: : (Optional)

    512 (0x200)

    srcgph: (Optional)

    640 (0x280)

    doccls: (Optional)

    768 (0x300)

    rtype: 1

    896 (0x380)

    rorient: 000,270

    1024 (0x400)

    rpelcnt: (Appropriate value)

    1152 (0x480)

    rdensty: (Appropriate value)

    1280 (0x500)

    notes: (Optional)

    1408 (0x580)

    0x20 × 128 bytes

    1530 (0x600)

    0x20 × 128 bytes

    1664 (0x680)

    0x20 × 128 bytes

    1792 (0x700)

    0x20 × 128 bytes

    1920 (0x780)

    0x20 × 128 bytes

    2048 (0x800)

    Bitmap image data

  • The size of the header block is 2,048 bytes, fixed length.

  • The size of a header record is 128 bytes, fixed length.

  • Header records start with a record ID, followed by two byte-separator characters, ":" colon (0x3a) and space (0x20). Specified values for header record IDs are entered after the separator characters. All of those must be entered as ASCII character codes.

  • If a header record has no effective information to be entered, "NONE" is entered as its value.

  • Empty bytes in the header records and header blocks are padded with spaces (0x20).

Note

  • CALS files that can be processed must comply with the following data file formats and raster representation specifications described in the following specification documents.

    • “MIL-STD-1840A”(issued by US Department of Defense, 22 December 1987)

    • “MIL-R-28002B”(issued by US Department of Defense, 30 September 1993)

  • "srcdocid" (8 bytes) out of record ID "srcdocid" is used in RTIFF as the keyword for identifying CALS Raster data.

  • The type of raster data is specified in record ID "rtype". Only "1" can be specified.

  • The orientations of raster graphics are specified in record ID "rorient". Specify the pixel rasterizing direction and line rasterizing direction of raster graphics in this order. RTIFF allows processing of the following image orientations only:

    1. Line rasterizing direction: 270 degrees

    2. Pixel rasterizing direction: None

  • Enter the total number of pixels of the raster image in the order of main scanning and scanning directions as the values for record ID “rpelcnt”.

  • Enter the pixel density of the raster image for record ID “rdensty”.

  • If record ID "rtype" and/or "rpelcnt" are not specified, or if either setting is invalid (including the setting "NONE"), RTIFF returns a fatal error and cancels processing.

  • If record ID "rorient" and/or "rdensty" are not specified, or if either setting is invalid (including the setting "NONE"), RTIFF returns a warning error but continues processing.

  • RTIFF does not use header records for record ID "srcdocid", "dstdocid", "txtfilid", "figid", "srcgph", "doccls", and/or "notes" for print processing, and simply ignores them.

Bitmap image (CALS file)

Bitmap data must follow immediately after the header block’s final byte (beginning in the 2,048th byte), and must be in the following format:

  • Black and white raster data compressed as per the ITU-T Recommendations T.6 (Group 4 Facsimile) encoding method.

  • This compression method is the same as that of MMR (Modified Modified Read) compression method.