2019-02-08 00:41:18 +08:00
|
|
|
bl_info = {
|
|
|
|
"name" : "rcf",
|
|
|
|
"author" : "CUBE",
|
|
|
|
"description" : "",
|
|
|
|
"blender" : (2, 80, 0),
|
|
|
|
"location" : "",
|
|
|
|
"warning" : "",
|
|
|
|
"category" : "Collaboration"
|
|
|
|
}
|
|
|
|
|
2019-03-14 23:44:18 +08:00
|
|
|
|
|
|
|
import bpy
|
|
|
|
import os
|
|
|
|
import sys
|
2019-05-09 20:20:42 +08:00
|
|
|
import subprocess
|
|
|
|
import bpy
|
|
|
|
import addon_utils
|
|
|
|
from pathlib import Path
|
|
|
|
|
|
|
|
python_path = Path(bpy.app.binary_path_python)
|
|
|
|
cwd_for_subprocesses = python_path.parent
|
|
|
|
|
|
|
|
def get_package_install_directory():
|
|
|
|
for path in sys.path:
|
|
|
|
if os.path.basename(path) in ("dist-packages", "site-packages"):
|
|
|
|
return path
|
|
|
|
|
|
|
|
try:
|
|
|
|
import zmq
|
|
|
|
except:
|
|
|
|
target = get_package_install_directory()
|
|
|
|
subprocess.run([str(python_path), "-m", "pip", "install", "zmq", '--target', target], cwd=cwd_for_subprocesses)
|
2019-03-14 23:44:18 +08:00
|
|
|
|
2019-04-10 23:01:21 +08:00
|
|
|
from . import operators
|
|
|
|
from . import ui
|
2019-02-08 00:57:03 +08:00
|
|
|
|
2019-02-08 00:41:18 +08:00
|
|
|
def register():
|
2019-04-10 23:01:21 +08:00
|
|
|
operators.register()
|
|
|
|
ui.register()
|
|
|
|
|
2019-02-08 00:41:18 +08:00
|
|
|
|
|
|
|
def unregister():
|
2019-04-10 23:01:21 +08:00
|
|
|
ui.unregister()
|
|
|
|
operators.unregister()
|
|
|
|
|
2019-04-01 22:14:21 +08:00
|
|
|
|