PHP code example of jean-gblr / dxf

1. Go to this page and download the library: Download jean-gblr/dxf library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

jean-gblr / dxf example snippets


$dxf = new Creator(Creator::MILLIMETERS);
$dxf->setColor(Color::rgb(0, 100, 0))
    ->addEllipse(-20, 0, 0, -20, 30, 0, 0.5)
    ->setLayer('2', Color::MAGENTA, LineType::SOLID)
    ->addEllipseBy3Points(20, 0, 0, 20, 30, 0, 35, 0, 0)
    ->saveToFile(dirname(__FILE__) . '/demo3.dxf');