ImageGear for C and C++ on Windows v21.0 - Updated
User Guide / File Formats and Compressions / File Formats / File Formats Reference / HPGL
In This Topic
    HPGL
    In This Topic
    Full Name HPGL
    Format ID IG_FORMAT_HPGL = 72
    File Extension(s) *.hpgl, *.plt
    Data Type Vector image
    Data Encoding Text, Binary
    Color Profile Support No
    Multi-Page Support Yes
    Alpha Channel Support No
    ImageGear 3D Image Support No
    ImageGear Raster to Vector Format Conversion Support No
    ImageGear Unicode Text Display Support Yes
    To support the HPGL format, attach the ImageGear CAD/Vector HPGL, HPGL/2 Component to Core ImageGear. See Attaching Components.

    ImageGear Supported Versions:

    HPGL, HPGL/2

    ImageGear Supported Features:

    ImageGear Read Support:

    IG_COMPRESSION_NONE - Vector/CAD data

    ImageGear Write Support:

    None

    ImageGear Filter Control Parameters:

    Filter Control Parameter Type Default Value Available Values Description
    BACKCOLOR AT_INT32 0 Any positive value This parameter sets view background color for image reading. If 0, black background color is set, otherwise white background color is set.
    WIDTH AT_INT32 512 Any positive value Defines the width of the empty DIB associated with the image after loading. DIB height is calculated using the file's scale factors. See Working with Vector Images.

    Comments:

    HPGL ("Hewlett Packard Graphics Language") is a vector graphics language used to output vector/CAD drawings to plotters. Due to widespread support among CAD software, it is sometimes used as a vector/CAD interchange format.

    HPGL Features Supported for Reading

    HPGL Instruction

    Supported Attributes

    Imported into ImageGear as:

    BR (Bezier relative)

    Relative points

    IG_VECT_ENT_NURBS_CURVE entity.

    BZ (Bezier absolute)

    Absolute points

    IG_VECT_ENT_BEZIER_CURVE entity.

    DF (Default)

     

    Used internally. Resets the settings to their default values.

    DI (Absolute direction)

    X coordinate of arc tangent

    Y coordinate of arc tangent

    Defines a direction for IG_VECT_ENT_TEXT entity.

    DR (Relative direction)

    X coordinate of arc tangent

    Y coordinate of arc tangent

    Defines a direction for IG_VECT_ENT_TEXT entity.

    DT (Define terminator)

    Terminator

    Used internally. Defines a terminator for text.

    EA (Rectangle absolute)

    Second corner of the rectangle

    IG_VECT_ENT_POLYLINE entity.

    EP (Edge polygon)

     

    Appends IG_VECT_ENT_ATTR_LINETYPEINDEX, IG_VECT_ENT_ATTR_DRAWCOLOR, and IG_VECT_ENT_ATTR_THICKNESS attributes to the extended polyline being previously created from PM instruction.

    ER (Rectangle relative)

    Second corner of the rectangle

    IG_VECT_ENT_POLYLINE entity.

    FT (fill type)

    Fill pattern

    Fill spacing

    Fill angle

    Used for creating HIG_VECT_FILLTYPE object.

    FP (Fill type polygon)

     

    Appends IG_VECT_ENT_ATTR_FILLTYPEINDEX and IG_VECT_ENT_ATTR_FILLCOLOR attributes to the extended polyline being previously created from PM instruction.

    IN (Initialize)

     

    Used internally. Initializes the drawing parameters.

    IP (Input P1 and P2)

    Minimum point

    Maximum point

    Used internally for specifying layout, scale factors, and so on.

    SC (Scale)

    Minimum scale point

    Maximum scale point

    Scale mode

    Used internally for specifying layout, scale factors, and so on.

    SI (Absolute character size)

    Width

    Height

    Defines font width and height for IG_VECT_ENT_TEXT entities.

    SR (Relative character size)

    Relative width

    Relative height

    Defines font width and height for IG_VECT_ENT_TEXT entities.

    SL (Character slant)

    Slant

    Defines character slant for IG_VECT_ENT_TEXT entities.

    LB (Label)

    Text string

    IG_VECT_ENT_TEXT entity.

    \x1b. (Esc sequence)

     

    Used internally.

    PA (Plot absolute)

    Absolute position

    Defines a position of entities.

    If pen is down, then either new IG_VECT_ENT_POLYLINE entity or new region for IG_VECT_ENT_POLYLINEEX is created.

    PC (Palette entry)

    Entry number

    Red, Green, Blue color values

    Used internally for specifying colors.

    PR (Plot relative)

    Relative position

    Defines a position of entities.

    If pen is down, then either new IG_VECT_ENT_POLYLINE entity or new region for IG_VECT_ENT_POLYLINEEX is created.

    RA (Shade rectangle absolute)

    Second corner

    IG_VECT_ENT_POLYLINE entity.

    RR (Fill rectangle absolute)

    Second corner

    IG_VECT_ENT_POLYLINE entity.

    AA (Arc absolute)

    Center

    Angle (Starting from the current position)

    Vertexes with bulge attribute being set if the arc is added to the polygon, otherwise - IG_VECT_ENT_ARC entity.

    PG (New page)

     

    Used for navigation through the pages.

    AF (New plot)

     

    Used for navigation through the pages.

    AR (Arc relative)

    Offset of the center

    Angle

    IG_VECT_ENT_ARC entity.

    AT (Arc absolute three points)

    Second point

    Third point

    IG_VECT_ENT_ARC entity.

    CI (Circle)

    Radius

    IG_VECT_ENT_ELLIPSE entity.

    CP (Character plot)

    Spaces

    Lines

    Used for updating current position for IG_VECT_ENT_TEXT entity.

    EW (Edge wedge)

    Radius

    Start angle

    Sweep angle

    IG_VECT_ENT_ARC entity.

    LT (Line type)

    Line style

    Line pattern length

    Used for creating HIG_VECT_LINETYPE objects.

    PD (Pen down)

    X position

    Y position

    Either IG_VECT_ENT_POLYLINE entity or new region for the existing IG_VECT_ENT_POLYLINEEX entity.

    PE (Polyline encoding)

    Binary sequence

    IG_VECT_ENT_POLYLINE entity.

    PM (Polygon mode)

    Mode (new polygon or close)

    IG_VECT_ENT_POLYLINEEX entity.

    PU (Pen up)

    X position

    Y position

    Changes current position. For polygons, appends hidden vertices to the vertex container.

    PW (Pen width)

    Thickness

    Defines line thickness when creating IG_VECT_ENT_ATTR_THICKNESS attribute.

    RO (rotate coordinate system)

    Angle

    Creates new IG_VECT_ENT_BLOCK entity with the corresponding rotation.

    SP (Select pen)

    Pen number

    Selects drawing color. Used as IG_VECT_ENT_ATTR_DRAWCOLOR attribute.

    TL (tick length)

    Length positive

    Length negative

    Used for creating coordinate axes – see below.

    WG (Shade wedge)

    Radius

    Start angle

    Sweep angle

     

    IG_VECT_ENT_ARC entity.

    WU (Pen width units)

    Unit type (Plot units or mm)

    Used for creating IG_VECT_ENT_ATTR_THICKNESS attribute.

    XT (X Tick, that is, X axe)

     

    IG_VECT_ENT_EASYLINE entity.

    YT (Y Tick, that is, Y axe)

     

    IG_VECT_ENT_EASYLINE entity.