diff --git a/kglobe.py b/kglobe.py index 8d33e55..d2eaac3 100644 --- a/kglobe.py +++ b/kglobe.py @@ -94,6 +94,7 @@ async def main(): ) parser.add_argument("-t", "--traceroute", default=None) parser.add_argument("--example", action="store_true") + parser.add_argument("-s", "--size", nargs=2, type=int, help="width x height in px") args = parser.parse_args() locations = [] @@ -123,7 +124,10 @@ async def main(): else: points_3d = [latlon_to_xyz(lat, lon) for lat, lon in locations] - height, width = await kitty.get_terminal_size_pixel() + if args.size: + width, height = args.size + else: + height, width = await kitty.get_terminal_size_pixel() plotter = TerminalPlotter(width, height) plotter.add_mesh(globe, color="tan", smooth_shading=False, texture=tex, show_edges=False)