UNPKG

@thi.ng/iges

Version:

IGES 5.3 serializer for (currently only) polygonal geometry, both open & closed

174 lines 3.53 kB
import type { Fn } from "@thi.ng/api"; export declare enum Unit { IN = 1,// inches MM = 2,// millimeters FT = 4,// feet MI = 5,// miles M = 6,// meters KM = 7,// kilometers MIL = 8,// mils UM = 9,// microns CM = 10,// centimeters UIN = 11 } export declare enum Type { INT = 0, FLOAT = 1, STR = 2, HSTR = 3, DATE = 4, POINTER = 5 } export declare enum SpecVersion { IGES50 = 8, IGES51 = 9, IGES52 = 10, IGES53 = 11 } export declare enum DraftVersion { NONE = 0, ISO = 1, AFNOR = 2, ANSI = 3, BSI = 4, CSA = 5, DIN = 6, JIS = 7 } export type SectionType = "G" | "S" | "D" | "P" | "T"; export declare enum LineFontPattern { NONE = 0, SOLID = 1, DASHED = 2, PHANTOM = 3, CENTERLINE = 4, DOTTED = 5 } export declare enum Color { NONE = 0, BLACK = 1, RED = 2, GREEN = 3, BLUE = 4, YELLOW = 5, MAGENTA = 6, CYAN = 7, WHITE = 8 } export declare enum StatusBlank { VISIBLE = 0, BLANK = 1 } export declare enum StatusSubord { INDEPENDENT = 0, PHYSICAL = 1, LOGICAL = 2, BOTH = 3 } export declare enum StatusUsage { GEOMETRY = 0, ANNOTATION = 1, DEFINITION = 2, OTHER = 3, LOGICAL = 4, PARAMETRIC2D = 5, CONSTRUCTIVE = 6 } export declare enum StatusHierarchy { GLOBAL_TOP_DOWN = 0, GLOBAL_DEFER = 1, USE_PROP = 2 } export declare enum PolylineMode { OPEN = 0, CLOSED = 1, FILLED = 2 } export declare enum BooleanOp { UNION = 1, INTERSECTION = 2, DIFFERENCE = 3 } export type BooleanNode = number | BooleanTree; export interface BooleanTree extends Array<BooleanNode> { [0]: BooleanOp; } export declare enum EntityType { POLYLINE = 106, LINE = 110, POINT = 116, CSG_BOX = 150, CSG_CYLINDER = 154, BOOLEAN_TREE = 180 } export interface EntityOpts { color: Color; pattern: LineFontPattern; } export interface DictEntry { type: number; param: number; struct: number; pattern: LineFontPattern; level: number; view: number; matrix: number; labelAssoc: number; status: Partial<EntityStatus>; index: number; lineWeight: number; color: Color; lineCount: number; form: number; label: string; subscript: number; } export interface EntityStatus { blank: StatusBlank; subord: StatusSubord; usage: StatusUsage; hierarchy: StatusHierarchy; } export interface GlobalParams { delimParam: string; delimRecord: string; senderProductID: string; receiverProductID: string; fileName: string; generator: string; generatorVersion: string; intBits: number; singleMaxPow: number; singleDigits: number; doubleMaxPow: number; doubleDigits: number; modelScale: number; units: Unit; numLineWeights: number; maxLineWeight: number; created: Date; modified: Date; precision: number; maxCoord: number; author: string; authorOrg: string; specVersion: SpecVersion; draftVersion: DraftVersion; } export type Param = [any, Type]; export interface IGESDocument { start: string[]; globals: GlobalParams; dict: string[]; param: string[]; offsets: { S: number; G: number; P: number; D: number; }; $FF: Fn<number, string>; $PARAM: Fn<any[], string>; } export declare const DEFAULT_GLOBALS: Partial<GlobalParams>; //# sourceMappingURL=api.d.ts.map