GlTF: Difference between revisions

From FreeCAD Documentation
No edit summary
(Marked this version for translation)
 
(One intermediate revision by one other user not shown)
Line 10: Line 10:
<!--T:2-->
<!--T:2-->
The [https://www.khronos.org/gltf/ GL Transmission Format] (glTF™) is a royalty-free specification for the efficient transmission and loading of 3D scenes and models by applications. It minimizes both the size of 3D assets, and the runtime processing needed to unpack and use those assets.
The [https://www.khronos.org/gltf/ GL Transmission Format] (glTF™) is a royalty-free specification for the efficient transmission and loading of 3D scenes and models by applications. It minimizes both the size of 3D assets, and the runtime processing needed to unpack and use those assets.

==Installation== <!--T:15-->

<!--T:16-->
According to this [https://forum.freecadweb.org/viewtopic.php?f=8&t=31680&p=450917&#p450658 forum thread], OCC must be compiled with RapidJSON support in order to utilize glTF features. Therefore set the option {{incode|USE_RAPIDJSON}} in the CMake configuration step. This requires the package rapidjson-dev.


==Importing== <!--T:3-->
==Importing== <!--T:3-->

Latest revision as of 19:36, 25 February 2021

Other languages:

Description

The GL Transmission Format (glTF™) is a royalty-free specification for the efficient transmission and loading of 3D scenes and models by applications. It minimizes both the size of 3D assets, and the runtime processing needed to unpack and use those assets.

Installation

According to this forum thread, OCC must be compiled with RapidJSON support in order to utilize glTF features. Therefore set the option USE_RAPIDJSON in the CMake configuration step. This requires the package rapidjson-dev.

Importing

Currently not supported in FreeCAD.

Exporting

Since FreeCAD version 0.19.23074 the Std Export command can export to the gITF format.

Alternative export solutions

For earlier versions these workarounds can be used:

1. Export as STEP → Import into CAD Assistant from Opencascade -> Export to glTF

OR

2. Use the cqparts Python library (website):

import cqparts
cqparts.Assembly.importer('step')('myfile.stp').exporter('gltf')('myfile.gltf')

Source: Forum thread

Related