next up previous contents index
Next: LIBRARY record Up: Computer Graphics Exchange (CGX) Previous: CGX Data Types   Contents   Index

CGX Data Records

The four-byte file header is followed by any number of data records, the last of which signals the end of data. There are 11 defined record types. Each record begins with a 4-byte header:

short recsize  
byte rectype  
byte flags  

The recsize field is a short unsigned integer giving the total record size, including the header. Thus, as in GDSII, records are limited to 64K bytes in length. The record size will always be an even number. The rectype byte is set to a small integer to define the type of record. The flags byte is used in some of the record types, otherwise it is ignored.

The defined record types are given in the table below.

rectype name
0 LIBRARY
1 STRUCT
2 CPRPTY
3 PROPERTY
4 LAYER
5 BOX
6 POLY
7 WIRE
8 TEXT
9 SREF
10 ENDLIB

It is allowable to define additional record types for local or proprietary purposes. If a parser encounters an unknown record type, it may skip over the record, ignoring it.



Subsections
next up previous contents index
Next: LIBRARY record Up: Computer Graphics Exchange (CGX) Previous: CGX Data Types   Contents   Index
Stephen R. Whiteley 2017-10-02