diff --git a/addons/hpcmonitor4b/actions/action_node.py b/addons/hpcmonitor4b/actions/action_node.py index 06099138011d8770827fd311241f12d21d8230ff..1d28857b2e096b63f22edf66bb96123d6358b23b 100644 --- a/addons/hpcmonitor4b/actions/action_node.py +++ b/addons/hpcmonitor4b/actions/action_node.py @@ -65,6 +65,14 @@ if ob_plane: ob_plane.rotation_euler[0] = 1.0 ob['GRAPH_OBNAME'] = ob_plane.name + + if 'Graph' in bpy.data.collections: + graph_collection = bpy.data.collections['Graph'] + else: + graph_collection = bpy.data.collections.new('Graph') + bpy.context.scene.collection.children.link(graph_collection) + + graph_collection.objects.link(ob_plane) diff --git a/addons/hpcmonitor4b/monitoring.py b/addons/hpcmonitor4b/monitoring.py index aa2a6955e82c63f5ace975f61a0d5aaa3a66ca2d..977ea956b3ed50c65668245800c4dcb6614ef23e 100644 --- a/addons/hpcmonitor4b/monitoring.py +++ b/addons/hpcmonitor4b/monitoring.py @@ -145,14 +145,14 @@ class HPCMonitor4BMonitoringShowLoad(bpy.types.Operator): if not math.isnan(fvalue): total = total + fvalue / 128.0 - ivalue = int(fvalue) + ivalue = int(fvalue * 100.0 / 128.0) else: ivalue = 0 total_count = total_count + 1 - if ivalue > 128: - ivalue = 128 + if ivalue > 100: + ivalue = 100 elif ivalue < 0: ivalue = 0 @@ -182,14 +182,14 @@ class HPCMonitor4BMonitoringShowLoad(bpy.types.Operator): if not math.isnan(fvalue): total = total + fvalue / 800.0 - ivalue = int(fvalue) + ivalue = int(fvalue * 100.0 / 800.0) else: ivalue = 0 total_count = total_count + 1 - if ivalue > 800: - ivalue = 800 + if ivalue > 100: + ivalue = 100 elif ivalue < 0: ivalue = 0 diff --git a/addons/hpcmonitor4b/prepare_scene.py b/addons/hpcmonitor4b/prepare_scene.py index e0f1c931c437ab31280a4e91ce7d25546f8d96ac..3c07b61b4ec956f34de06b7337f0cb38a93b5ede 100644 --- a/addons/hpcmonitor4b/prepare_scene.py +++ b/addons/hpcmonitor4b/prepare_scene.py @@ -184,20 +184,20 @@ class HPCMonitor4BPrepareScene: def create_values(self, context): tex_path = context.scene.view_pg_hpcmonitor4b_prepare_scene.output_path #LOAD_CPU - for i in range(129): - self.create_value_png(tex_path, 'load_cpu_%d' % i, '%d' % i, float(i) / 128.0 , (150, 33, 33, 255)) + for i in range(101): + self.create_value_png(tex_path, 'load_cpu_%d' % i, '%d %%' % i, float(i) / 100.0 , (150, 33, 33, 255)) + + #LOAD_GPU + for i in range(101): + self.create_value_png(tex_path, 'load_gpu_%d' % i, '%d %%' % i, float(i) / 100.0 , (33, 150, 33, 255)) #POWER_CPU for i in range(701): - self.create_value_png(tex_path, 'power_cpu_%d' % i, '%dW' % + self.create_value_png(tex_path, 'power_cpu_%d' % i, '%d W' % i, float(i) / 700.0, (150, 33, 33, 255)) - #LOAD_GPU - for i in range(801): - self.create_value_png(tex_path, 'load_gpu_%d' % i, '%d' % i, float(i) / 800.0 , (33, 150, 33, 255)) - #POWER_GPU for i in range(3501): - self.create_value_png(tex_path, 'power_gpu_%d' % i, '%dW' % + self.create_value_png(tex_path, 'power_gpu_%d' % i, '%d W' % i, float(i) / 3500.0, (33, 150, 33, 255)) def create_value_png(self, tex_path, filename, txt, value, color): diff --git a/docs/3dviewport_menu.png b/docs/3dviewport_menu.png new file mode 100644 index 0000000000000000000000000000000000000000..a33e1811b86854312b5cd501279c6bdd791f282c Binary files /dev/null and b/docs/3dviewport_menu.png differ diff --git a/docs/blender_screen.png b/docs/blender_screen.png new file mode 100644 index 0000000000000000000000000000000000000000..6c7c57cbf3285b2395d4206d23323d111e3da742 Binary files /dev/null and b/docs/blender_screen.png differ diff --git a/docs/graph.png b/docs/graph.png new file mode 100644 index 0000000000000000000000000000000000000000..1964d32c2b781fa159e6acc7176c24307490ae85 Binary files /dev/null and b/docs/graph.png differ diff --git a/docs/preferences_menu.png b/docs/preferences_menu.png new file mode 100644 index 0000000000000000000000000000000000000000..f66f1af81f06b8fd238080330bbfdaeb791ad01c Binary files /dev/null and b/docs/preferences_menu.png differ