Closed dirkesquire closed 4 years ago
yellow box is in negative quadrant and renders fine green box is in positive quadrant and renders fine white box spans from (-50, -50) to (50, 50) and looks odd. The following is a code snippet one can play with and demonstate the issue:
import sys import wasabi2d as w2d from wasabi2d.keyboard import keys scene = w2d.Scene(background="#223366") # centre = scene.width // 2, scene.height // 2 centre = (0, 0) scene.camera.pos = centre speedlabel = scene.layers[0].add_label( f"{centre}", pos=centre, ) # Renders OK origin = -200 extent = -5 boundary = scene.layers[0].add_line( [(origin, origin), (extent, origin), (extent, extent), (origin, extent), (origin, origin)], color="yellow", stroke_width=2 ) # Renders Oddly origin = -50 extent = 50 boundary = scene.layers[0].add_line( [(origin, origin), (extent, origin), (extent, extent), (origin, extent), (origin, origin)], color="white", stroke_width=2 ) # Renders OK origin = 5 extent = 200 boundary = scene.layers[0].add_line( [(origin, origin), (extent, origin), (extent, extent), (origin, extent), (origin, origin)], color="green", stroke_width=2 ) @w2d.event def on_key_down(key): if key == keys.Q: # Quit sys.exit(0) w2d.run()
Fixed in 71b7421
yellow box is in negative quadrant and renders fine green box is in positive quadrant and renders fine white box spans from (-50, -50) to (50, 50) and looks odd. The following is a code snippet one can play with and demonstate the issue: