Important: The information in this document is obsolete and should not be used for new development.
QuickDraw GX Stream Format Summary
Opcode Constants and Data Types
Operation Opcode Byte
enum gxGraphicsOperationOpcode { gxNewObjectOpcode = 0x00, gxSetDataOpcode = 0x40, gxSetDefaultOpcode= 0x80, gxReservedOpcode = 0xC0, gxNextOpcode = 0xFF, };Data Type Opcode Byte
enum gxGraphicsNewOpcode { gxHeaderTypeOpcode = 0x00, gxStyleTypeOpcode = 0x28, gxInkTypeOpcode, gxTransformTypeOpcode, gxColorProfileTypeOpcode, gxColorSetTypeOpcode, gxTagTypeOpcode, gxBitImageOpcode, gxFontNameTypeOpcode, gxTrailerTypeOpcode, };Generic Data Opcode
enum gxGenericDataOpcode { gxTypeOpcode, gxSizeOpcode }; /* constants used by current operand when current operation is gxNextOpcode */ #define gxCompressionShift 6 #define gxObjectTypeMask 0x3F #define gxBitImageOpcodeMask 0xC0 #define gxBitImageCountMask 0x3F #define gxBitImageOpcodeShift 6Modified Shape Data Opcodes
enum gxShapeDataOpcode { gxShapeAttributesOpcode, gxShapeTagOpcode, gxShapeFillOpcode };Modified Style Data Opcodes
enum gxStyleDataOpcode { gxStyleAttributesOpcode, gxStyleTagOpcode, gxStyleCurveErrorOpcode, gxStylePenOpcode, gxStyleJoinOpcode, gxStyleDashOpcode, gxStyleCapsOpcode, gxStylePatternOpcode, gxStyleTextAttributesOpcode, gxStyleTextSizeOpcode, gxStyleFontOpcode, gxStyleTextFaceOpcode, gxStylePlatformOpcode, gxStyleFontVariationsOpcode, #ifdef gxLayoutStyleRuns gxStyleRunControlsOpcode, gxStyleRunPriorityJustOverrideOpcode, gxStyleRunGlyphJustOverridesOpcode, gxStyleRunGlyphSubstitutionsOpcode, gxStyleRunFeaturesOpcode, gxStyleRunKerningAdjustmentsOpcode, gxStyleLayoutInfoOpcode, gxStyleJustificationOpcode };Modified Ink Data Opcodes
enum gxInkDataOpcode { gxInkAttributesOpcode, gxInkTagOpcode, gxInkColorOpcode, gxInkTransferModeOpcode };Modified Color Set Data Opcodes
enum gxColorSetDataOpcode { gxColorSetReservedOpcode, gxColorSetTagOpcode };Modified Color Profile Data Opcodes
enum gxProfileDataOpcode { gxColorProfileAttributesOpcode, gxColorProfileTagOpcode };Modified Transform Data Opcodes
enum gxTransformDataOpcode { gxTransformReservedOpcode, gxTransformTagOpcode, gxTransformClipOpcode, gxTransformMappingOpcode, gxTransformPartMaskOpcode, gxTransformToleranceOpcode };Bit Image Compression Opcodes
enum gxBitImageCompression { gxCopyBitImageBytesOpcode = 0x00, gxRepeatBitImageBytesOpcode= 0x40, gxLookupBitImageBytesOpcode= 0x80, gxRepeatBitImageScanOpcode = 0xC0 };Two Bit Compression Values
enum gxTwoBitCompressionValues { gxNoCompression, = 0x00 gxWordCompression, = 0x40 gxByteCompression, = 0x80 gxOmitCompression = = 0x?? };Flatten Header Bytes
struct gxFlattenHeader { fixed version; unsigned char flatFlags; };Style Object Omit Byte Constants and Data Types
Dash Style Omit Byte Masks and Shifts
enum gxOmitDashMask1 { gxOmitDashAttributesMask = 0xC0, gxOmitDashShapeMask = 0x30, gxOmitDashAdvanceMask = 0x0C, gxOmitDashPhaseMask = 0x03 }; enum gxOmitDashShift1 { gxOmitDashAttributesShift = 6, gxOmitDashShapeShift = 4, gxOmitDashAdvanceShift = 2, gxOmitDashPhaseShift = 0 }; enum gxOmitDashMask2 { gxOmitDashScaleMask = 0xC0 }; enum gxOmitDashShift2 { gxOmitDashScaleShift = 6 };Pattern Style Omit Byte Masks and Shifts
enum gxOmitPatternMask1 { gxOmitPatternAttributesMask = 0xC0, gxOmitPatternShapeMask = 0x30, gxOmitPatternUXMask = 0x0C, gxOmitPatternUYMask = 0x03 }; enum gxOmitPatternShift1 { gxOmitPatternAttributesShift = 6, gxOmitPatternShapeShift = 4, gxOmitPatternUXShift = 2, gxOmitPatternUYShift = 0 }; enum gxOmitPatternMask2 { gxOmitPatternVXMask = 0xC0, gxOmitPatternVYMask = 0x30 }; enum gxOmitPatternShift2 { gxOmitPatternVXShift= 6, gxOmitPatternVYShift= 4 };Join Style Omit Byte Masks and Shifts
enum gxOmitJoinMask { gxOmitJoinAttributesMask= 0xC0, gxOmitJoinShapeMask = 0x30, gxOmitJoinMiterMask = 0x0C }; enum gxOmitJoinShift { gxOmitJoinAttributesShift = 6, gxOmitJoinShapeShift = 4, gxOmitJoinMiterShift = 2 };Cap Style Omit Byte Masks and Shifts
enum gxOmitCapMask { gxOmitCapAttributesMask = 0xC0, gxOmitCapStartShapeMask = 0x30, gxOmitCapEndShapeMask = 0x0C }; enum gxOmitCapShift { gxOmitCapAttributesShift= 6, gxOmitCapStartShapeShift= 4, gxOmitCapEndShapeShift = 2 };Text Face Style Omit Byte Masks and Shifts
enum gxOmitFaceMask { gxOmitFaceLayersMask = 0xC0, gxOmitFaceMappingMask= 0x30 }; enum gxOmitFaceShift { gxOmitFaceLayersShift = 6, gxOmitFaceMappingShift= 4 };Face Layer Omit Byte Masks and Shifts
enum gxOmitFaceLayerMask1 { gxOmitFaceLayerFillMask = 0xC0, gxOmitFaceLayerFlagsMask = 0x30, gxOmitFaceLayerStyleMask = 0x0C, gxOmitFaceLayerTransformMask = 0x03 }; enum gxOmitFaceLayerShift1 { gxOmitFaceLayerFillShift = 6, gxOmitFaceLayerFlagsShift = 4, gxOmitFaceLayerStyleShift = 2, gxOmitFaceLayerTransformShift = 0 }; enum gxOmitFaceLayerMask2 { gxOmitFaceLayerBoldXMask = 0xC0, gxOmitFaceLayerBoldYMask = 0x30 }; enum gxOmitFaceLayerShift2 { gxOmitFaceLayerBoldXShift = 6, gxOmitFaceLayerBoldYShift = 4 };Ink Object Omit Byte Constants and Data Types
Colors Omit Byte Masks and Shifts
enum gxOmitColorsMask { gxOmitColorsSpaceMask = 0xC0, gxOmitColorsProfileMask = 0x30, gxOmitColorsComponentsMask = 0x0F, gxOmitColorsIndexMask = 0x0C, gxOmitColorsIndexSetMask = 0x03 }; enum gxOmitColorsShift { gxOmitColorsSpaceShift = 6, gxOmitColorsProfileShift = 4, gxOmitColorsComponentsShift = 0, gxOmitColorsIndexShift = 2, gxOmitColorsIndexSetShift = 0 };Transfer Omit Byte Masks and Shifts
enum gxOmitTransferMask1 { gxOmitTransferSpaceMask = 0xC0, gxOmitTransferSetMask = 0x30, gxOmitTransferProfileMask = 0x0C }; enum gxOmitTransferShift1 { gxOmitTransferSpaceShift = 6, gxOmitTransferSetShift = 4, gxOmitTransferProfileShift = 2 }; enum gxOmitTransferMask2 { gxOmitTransferSourceMatrixMask= 0xC0, gxOmitTransferDeviceMatrixMask= 0x30, gxOmitTransferResultMatrixMask= 0x0C, gxOmitTransferFlagsMask = 0x03 }; enum gxOmitTransferShift2 { gxOmitTransferSourceMatrixShift = 6, gxOmitTransferDeviceMatrixShift = 4, gxOmitTransferResultMatrixShift = 2, gxOmitTransferFlagsShift = 0 };Transfer Component Omit Byte Masks and Shifts
enum gxOmitTransferComponentMask1{ gxOmitTransferComponentModeMask = 0x80, gxOmitTransferComponentFlagsMask = 0x40, gxOmitTransferComponentSourceMinimumMask = 0x30, gxOmitTransferComponentSourceMaximumMask = 0x0C, gxOmitTransferComponentDeviceMinimumMask = 0x03 } ; enum gxOmitTransferComponentShift1 { gxOmitTransferComponentModeShift = 7, gxOmitTransferComponentFlagsShift = 6, gxOmitTransferComponentSourceMinimumShift = 4, gxOmitTransferComponentSourceMaximumShift = 2, gxOmitTransferComponentDeviceMinimumShift = 0 }; enum gxOmitTransferComponentMask2 { gxOmitTransferComponentDeviceMaximumMask = 0xC0, gxOmitTransferComponentClampMinimumMask = 0x30, gxOmitTransferComponentClampMaximumMask = 0x0C, gxOmitTransferComponentOperandMask = 0x03 }; enum gxOmitTransferComponentShift2 { gxOmitTransferComponentDeviceMaximumShift = 6, gxOmitTransferComponentClampMinimumShift = 4, gxOmitTransferComponentClampMaximumShift = 2, gxOmitTransferComponentOperandShift = 0 };Shape Object Omit Byte Constants and Data Types
Path Shape Omit Byte Masks and Shifts
enum gxOmitPathMask { gxOmitPathPositionXMask = 0xC0, gxOmitPathPositionYMask = 0x30, gxOmitPathDeltaXMask = 0x0C, gxOmitPathDeltaYMask = 0x03 }; enum gxOmitPathShift { gxOmitPathPositionXShift = 6, gxOmitPathPositionYShift = 4, gxOmitPathDeltaXShift = 2, gxOmitPathDeltaYShift = 0 };Bitmap Shape Omit Byte Masks and Shifts
enum gxOmitBitmapMask1 { gxOmitBitmapImageMask = 0xC0, gxOmitBitmapWidthMask = 0x30, gxOmitBitmapHeightMask = 0x0C, gxOmitBitmapRowBytesMask = 0x03 }; enum gxOmitBitmapShift1 { gxOmitBitmapImageShift = 6, gxOmitBitmapWidthShift = 4, gxOmitBitmapHeightShift = 2, gxOmitBitmapRowBytesShift = 0 }; enum gxOmitBitmapMask2 { gxOmitBitmapPixelSizeMask = 0xC0, gxOmitBitmapSpaceMask = 0x30, gxOmitBitmapSetMask = 0x0C, gxOmitBitmapProfileMask = 0x03 }; enum gxOmitBitmapShift2 { gxOmitBitmapPixelSizeShift = 6, gxOmitBitmapSpaceShift = 4, gxOmitBitmapSetShift = 2, gxOmitBitmapProfileShift = 0 }; enum gxOmitBitmapMask3 { gxOmitBitmapPositionXMask = 0xC0, gxOmitBitmapPositionYMask = 0x30 }; enum gxOmitBitmapShift3 { gxOmitBitmapPositionXShift = 6, gxOmitBitmapPositionYShift = 4 };Bit Image Omit Byte Masks and Shifts
enum gxOmitBitImageMask { gxOmitBitImageRowBytesMask = 0xC0, gxOmitBitImageHeightMask = 0x30, gxOmitBitImageDataMask = 0x08 }; enum gxOmitBitImageShift { gxOmitBitImageRowBytesShift = 6, gxOmitBitImageHeightShift = 4, gxOmitBitImageDataShift = 3 };Text Shape Omit Byte Masks and Shifts
enum gxOmitTextMask { gxOmitTextCharactersMask = 0xC0, gxOmitTextPositionXMask = 0x30, gxOmitTextPositionYMask = 0x0C, gxOmitTextDataMask = 0x02 }; enum gxOmitTextShift { gxOmitTextCharactersShift = 6, gxOmitTextPositionXShift = 4, gxOmitTextPositionYShift = 2, gxOmitTextDataShift = 1 };Glyph Shape Omit Byte Masks and Shifts
enum gxOmitGlyphMask1 { gxOmitGlyphCharactersMask = 0xC0, gxOmitGlyphLengthMask = 0x30, gxOmitGlyphRunNumberMask = 0x0C, gxOmitGlyphOnePositionMask = 0x02, gxOmitGlyphDataMask = 0x01 }; enum gxOmitGlyphShift1 { gxOmitGlyphCharactersShift = 6, gxOmitGlyphLengthShift = 4, gxOmitGlyphRunNumberShift = 2, gxOmitGlyphOnePositionShift = 1, gxOmitGlyphDataShift = 0 }; enum gxOmitGlyphMask2 { gxOmitGlyphPositionsMask = 0xC0, gxOmitGlyphAdvancesMask = 0x20, gxOmitGlyphTangentsMask = 0x18, gxOmitGlyphRunsMask = 0x04, gxOmitGlyphStylesMask = 0x03 }; enum gxOmitGlyphShift2 { gxOmitGlyphPositionsShift = 6, gxOmitGlyphAdvancesShift = 5, gxOmitGlyphTangentsShift = 3, gxOmitGlyphRunsShift = 2, gxOmitGlyphStylesShift = 0 };Layout Shape Omit Byte Masks and Shifts
enum gxOmitLayoutMask1 { gxOmitLayoutLengthMask = 0xC0, gxOmitLayoutPositionXMask = 0x30, gxOmitLayoutPositionYMask = 0x0C, gxOmitLayoutDataMask = 0x02 }; enum gxOmitLayoutShift1 { gxOmitLayoutLengthShift = 6, gxOmitLayoutPositionXShift = 4, gxOmitLayoutPositionYShift = 2, gxOmitLayoutDataShift = 1 }; enum gxOmitLayoutMask2 { gxOmitLayoutWidthMask = 0xC0, gxOmitLayoutFlushMask = 0x30, gxOmitLayoutJustMask = 0x0C, gxOmitLayoutOptionsMask = 0x03 }; enum gxOmitLayoutShift2 { gxOmitLayoutWidthShift = 6, gxOmitLayoutFlushShift = 4, gxOmitLayoutJustShift = 2, gxOmitLayoutOptionsShift = 0 }; enum gxOmitLayoutMask3 { gxOmitLayoutStyleRunNumberMask= 0xC0, gxOmitLayoutLevelRunNumberMask= 0x30, gxOmitLayoutHasBaselineMask = 0x08, gxOmitLayoutStyleRunsMask = 0x04, gxOmitLayoutStylesMask = 0x03 }; enum gxOmitLayoutShift3 { gxOmitLayoutStyleRunNumberShift = 6, gxOmitLayoutLevelRunNumberShift = 4, gxOmitLayoutHasBaselineShift = 3, gxOmitLayoutStyleRunsShift = 2, gxOmitLayoutStylesShift = 0 }; enum gxOmitLayoutMask4 { gxOmitLayoutLevelRunsMask = 0x80, gxOmitLayoutLevelsMask = 0x40 }; enum gxOmitLayoutShift4 { gxOmitLayoutLevelRunsShift = 7, gxOmitLayoutLevelsShift = 6 };Picture Shape Omit Byte Masks and Shifts
enum gxOmitPictureParametersMask { gxOmitPictureShapeMask = 0xC0, gxOmitOverrideStyleMask = 0x30, gxOmitOverrideInkMask = 0x0C, gxOmitOverrideTransformMask = 0x03 }; enum gxOmitPictureParametersShift { gxOmitPictureShapeShift = 0x6, gxOmitOverrideStyleShift = 0x4, gxOmitOverrideInkShift = 0x2, gxOmitOverrideTransformShift = 0x0 };