Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender-addons.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVilém Duha <vilda.novak@gmail.com>2020-01-04 16:19:17 +0300
committerVilém Duha <vilda.novak@gmail.com>2020-01-07 13:43:43 +0300
commitf272cf57a5ce7538ea01a16b88d7a0ec297e311d (patch)
treeb523567401b0691e7d9f42ef429ed2b4787725ff
parent4d10cb46d9152ed7892772e04ae2d7e3f4c2d3bd (diff)
BlenderKit: move process flag generation to utils.
-rw-r--r--blenderkit/utils.py17
1 files changed, 16 insertions, 1 deletions
diff --git a/blenderkit/utils.py b/blenderkit/utils.py
index eebdb078..3b7eac20 100644
--- a/blenderkit/utils.py
+++ b/blenderkit/utils.py
@@ -28,9 +28,24 @@ import bpy
from mathutils import Vector
import json
import os
-import requests
+import sys
+
+
+ABOVE_NORMAL_PRIORITY_CLASS = 0x00008000
+BELOW_NORMAL_PRIORITY_CLASS = 0x00004000
+HIGH_PRIORITY_CLASS = 0x00000080
+IDLE_PRIORITY_CLASS = 0x00000040
+NORMAL_PRIORITY_CLASS = 0x00000020
+REALTIME_PRIORITY_CLASS = 0x00000100
+
+def get_process_flags():
+ flags = BELOW_NORMAL_PRIORITY_CLASS
+ if sys.platform != 'win32': # TODO test this on windows
+ flags = 0
+ return flags
+
def activate(ob):
bpy.ops.object.select_all(action='DESELECT')
ob.select_set(True)