Skip to content

Documentation

Joe Pietler edited this page Dec 30, 2016 · 2 revisions

DXF files are build of multiple sections which contain different things. At the moment DXFighter only allows to add entities but other elements like line types will follow.

#Entities Entities are elements which are drawn when viewing the DXF file like lines and ellipses so all kind of graphical objects belong to this area of the dxf file. Every type of entity needs different attributes but there are several common elements all entities have.

Name Default Description
Space 0 0 => Object is in model space, 1 => Object is in paper space
Layer name 0 The name of the layer an entity is placed on
Linetype name BYLAYER The name of the line type which should be used for drawing the entity
Color number BYLAYER A color representing number, more infos can be found here
Linetype scale 1.0 A scale for drawing the line type
Object visibility 0 0 => object is visible, 1 => object is hidden

##ARC An arc is a kind of circle which is only drawn from one specific angle to another.

$dxf->addEntity(new \DXFighter\lib\Arc(
    array(20, 0, 0),    //Center point
    4,                  //Radius
    0,                  //Starting angle
    100,                //End angle
    0,                  //Thickness, default = 0
    array(0, 0, 1),     //Extrusion direction, default = array(0, 0, 1)
));

This code will generate something like ARC

##CIRCLE

##ELLIPSE

##LINE

##POINT

Clone this wiki locally