From c14f7e2d0be36f312ef3d4efec7388c2a7ade4e7 Mon Sep 17 00:00:00 2001 From: raphael60650 Date: Mon, 2 Aug 2021 20:44:45 +0200 Subject: [PATCH] reverted color so that dark = background and white = foreground --- scripts/minimap/obj_to_png.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/minimap/obj_to_png.py b/scripts/minimap/obj_to_png.py index e45da8f..13b5afc 100644 --- a/scripts/minimap/obj_to_png.py +++ b/scripts/minimap/obj_to_png.py @@ -70,7 +70,7 @@ def draw_model(scene_scale, scene_trans, scene): elif height < min_height: min_height = height - min_height -= (max_height - min_height) // 3 + min_height += (max_height - min_height) // 3 glBegin(GL_TRIANGLES) for face in mesh.faces: @@ -78,7 +78,7 @@ def draw_model(scene_scale, scene_trans, scene): height = scene.vertices[vertex_i][color_axe] color = 1 if max_height != 0: - color = ((height - min_height) / max_height) + color = 1-((height - min_height) / max_height) glColor3f(color, color, color) glVertex3f(*scene.vertices[vertex_i])