A command-line tool to convert COLLADA (.dae
) files to glTF.
git clone --recursive https://github.com/KhronosGroup/COLLADA2GLTF.git
apt-get install cmake libxml2-dev libpcre3-dev libpng-dev zlib1g-dev
Install Visual Studio
Install CMake
Install Xcode
Install dependencies with brew
brew install cmake pkgconfig pcre libpng
if the PNG package is not found, the workaround is to Download the the *.tar.gz install from libpng and then:
./configure
make check
sudo make install
cd COLLADA2GLTF
mkdir build
cd build
cmake ..
make
Open COLLADA2GLTF.sln with Visual Studio and build
Open COLLADA2GLTF.xcodeproj and build or if you installed xcode command line tools you can also build in the terminal: xcodebuild -target collada2gltf -configuration Release (or Debug)
./bin/collada2gltf
./bin/Release/collada2gltf.exe
./bin/Release/collada2gltf
collada2gltf -f [file] [options]
options:
-z -> path of configuration file [string]
-f -> path of input file, argument [string]
-o -> path of output file argument [string]
-b -> path of output bundle argument [string]
-g -> [experimental] GLSL version to output in generated shaders
-i -> invert-transparency
-d -> export pass details to be able to regenerate shaders and states
-p -> output progress
-l -> enable default lighting (if no lights in scene) [bool], default:true
-c -> compression type: available: Open3DGC [string]
-m -> compression mode: for Open3DGC can be "ascii"(default) or "binary" [string]
-v -> print version
-s -> experimental mode
-h -> help
-r -> verbose logging
-e -> embed resources (bin, shaders, available textures) in glTF file
-n -> don't combine animations with the same target
-k -> export materials and lights using KHR_materials_common extension