tpaviot / pythonocc-demos

Examples and demos for the pythonocc CAD package
216 stars 115 forks source link

TDocStd.py | TypeError: in method 'new_TDocStd_Document', argument 1 of type 'TCollection_ExtendedString const &' #71

Open im44pos opened 11 months ago

im44pos commented 11 months ago

Want to export a shape or solid to a .glb file. Example code from pythonocc-demos/examples/core_export_gltf_single_shape.py results in TypeError on "create document" line 37 '''doc = TDocStd_Document("pythonocc-doc")''' '''TypeError: in method 'new_TDocStd_Document', argument 1 of type 'TCollection_ExtendedString const &'''' ..\lib\site-packages\OCC\Core\TDocStd.py:1120

amoghsundararaman commented 6 months ago

Same issue would love a solution

tpaviot commented 6 months ago

Try:

doc = TDocStd_Document(TCollection_ExtendedString("pythonocc-doc"))