force-draco2.patch 860 B

12345678910111213141516171819202122
  1. diff --git a/io_scene_gltf2/io/com/gltf2_io_draco_compression_extension.py b/io_scene_gltf2/io/com/gltf2_io_draco_compression_extension.py
  2. index e7518ac4..c0d78564 100644
  3. --- a/io_scene_gltf2/io/com/gltf2_io_draco_compression_extension.py
  4. +++ b/io_scene_gltf2/io/com/gltf2_io_draco_compression_extension.py
  5. @@ -13,6 +13,7 @@
  6. # limitations under the License.
  7. import os
  8. +import site
  9. import sys
  10. from pathlib import Path
  11. import bpy
  12. @@ -30,7 +31,7 @@ def dll_path() -> Path:
  13. python_lib = Path('{v[0]}.{v[1]}/python/lib'.format(v=bpy.app.version))
  14. python_version = 'python{v[0]}.{v[1]}'.format(v=sys.version_info)
  15. - path = os.environ.get('BLENDER_EXTERN_DRACO_LIBRARY_PATH')
  16. + path = f"{site.getsitepackages()[0]}/libextern_draco.so"
  17. if path is None:
  18. path = {
  19. 'win32': blender_root / python_lib / 'site-packages',