CASTLE-MODEL-CONVERTER(1) | castle-model-converter | CASTLE-MODEL-CONVERTER(1) |
NAME¶
castle-model-converter - converter for various 3D and 2D model formats
SYNOPSIS¶
castle-model-converter [OPTION]... INPUT-FILE [OUTPUT-FILE]
FEATURES¶
As input, we support all 3D and 2D model formats supported by Castle Game Engine: glTF, X3D, VRML, Spine JSON, sprite sheets (in Castle Game Engine, Cocos2D and Starling XML formats), MD3, Wavefront OBJ, 3DS, STL, Collada, and more.
As output, we support X3D, VRML and STL. You can convert any input format to X3D or STL. You can also convert between X3D classic and X3D XML encodings (in both directions) and you can convert (upgrade) from VRML 2.0 to X3D.
We can also validate the input model, without doing any conversion.
USAGE¶
Call with these parameters:
Required.
This parameter is optional. If not provided, the output is written to the standard output (so it is equivalent to using - as the output filename), unless --validate is used (then the output is not written anywhere).
EXAMPLES¶
# Convert glTF to X3D castle-model-converter input.gltf output.x3d # Validate some glTF and X3D files castle-model-converter --validate input.gltf castle-model-converter --validate input.x3d # Convert file from X3D classic encoding to X3D XML encoding castle-model-converter input.x3dv output.x3d # Convert file from X3D XML encoding to X3D classic encoding castle-model-converter input.x3d output.x3dv # Convert VRML 2.0 to X3D in classic encoding. castle-model-converter input.wrl output.x3dv # Convert standard input to standard output castle-model-converter - - < input.x3dv > output.x3dv castle-model-converter - --stdin-url=fakeurl.gltf - < input.gltf > output.x3dv
ALL COMMAND-LINE OPTIONS¶
--validate
Note
Our "validation" isn’t 100% complete, that is: passing the validation doesn’t guarantee that your model satisfies every detail of the specification of given format. We check for a lot of model issues (including, but not limited to, issues that would make it impossible to render this model using Castle Game Engine). But it’s not a complete validation of the model per every detail of the specification.
--no-x3d-extensions
--enable-downloads
--stdin-url=URL
--stdout-url=URL
--float-precision=DIGITS
-h / --help
-v / --version
Deprecated¶
--encoding=classic|xml
Deprecated, do not use this. The 2nd parameter should determine the output type, ".x3d" extension says to make X3D XML, ".x3dv" says to make X3D classic. Or use --stdout-url to provide fake URL in case output is to stdout.
RESOURCES¶
Project web site: <https://castle-engine.io/castle-model-converter>
Using Castle Game Engine: <https://castle-engine.io/>
SEE ALSO¶
AUTHOR¶
Michalis Kamburelis
2024-05-15 | castle-model-converter |