dev-master
9999999-dev http://github.com/ChubV/php-stlLibrary to parse STL file and get some statistics of the model
MIT
The Requires
- php >=5.4.0
The Development Requires
3d stl volume
Wallogit.com
2017 © Pedro Peláez
Library to parse STL file and get some statistics of the model
This repository contains code for handling 3D models saved in STL format., (*1)
The suggested installation method is via composer., (*2)
Add a dependency on chubv/php-stl to your project's composer.json file., (*3)
To get the model build the Reader and read the model from file, (*4)
$model = STLReader::forFile(__DIR__ . '/stls/text.stl')->readModel();, (*5)
You can use VolumeHandler to calculate volume of 3D model without STLModel object construction
(memory consumption is proportional to model size)
or write your own handler by implementing HandlerInterface and setting it to reader., (*6)
$reader = STLReader::forFile(__DIR__ . '/stls/text.stl');
$reader->setHandler(new VolumeHandler());
$volume = $reader->readModel();
The PHPUnit version to be used is the one installed as a dev- dependency via composer:, (*7)
$ ./vendor/bin/phpunit
It's under MIT. Look at LICENSE file., (*8)
Feel free to make pull requests or create issues. You can also contact me via e-mail v[at]chub.com.ua, (*9)
Library to parse STL file and get some statistics of the model
MIT
3d stl volume