This package can be used to verify that in a given folder, the .obj has all the required files to be run as a binary 3d model.
docker run -v "$PWD/vendor/artglass/assimp2amc/assimp2amc:/home" -w "/home" -i -t mcr.microsoft.com/dotnet/sdk:5.0-alpine dotnet publish -r linux-x64 -p:PublishSingleFile=true --self-contained true
The compiled file will be stored in /vendor/artglass/assimp2amc/assimp2amc/bin/Debug/netcoreapp3.1/linux-x64/publish
cp $PWD/vendor/artglass/assimp2amc/assimp2amc/bin/Debug/netcoreapp3.1/linux-x64/publish/assimp2amc .
or simply run:
composer compile
docker run -v "$PWD:/home" -w "/home" -i -t alpine ./assimp2amc -c src/ExampleModelData/851e122f30504b90ae495fe567342936.obj
You can install the package via composer:
composer require soiposervices/assimp2amc
You can publish and run the migrations with:
php artisan vendor:publish --provider="SoipoServices\Assimp2AmcServiceProvider" --tag="assimp2amc-migrations"
php artisan migrate
You can publish the config file with:
php artisan vendor:publish --provider="SoipoServices\Assimp2AmcServiceProvider" --tag="assimp2amc-config"
This is the contents of the published config file:
return [
'bash_script' => './',
'path_to_executable' => 'src/assimp2amcosx'
];
$laravel-assimp2amc = new SoipoServices\Assimp2Amc();
echo $laravel-assimp2amc->run('src/ExampleModelData/851e122f30504b90ae495fe567342936.obj');
Assimp2Amc::run('src/ExampleModelData/851e122f30504b90ae495fe567342936.obj');
Make sure you compile first in order to have the excutable in the src folder
composer compile
or for mac:
composer compile-osx
You should also have a folder containing 3d model .obj file with its assets in a folder called ExampleModelData in the src folder.
composer test
Please see CHANGELOG for more information on what has changed recently.
The MIT License (MIT). Please see License File for more information.