NVIDIA / warp

A Python framework for high performance GPU simulation and graphics
https://nvidia.github.io/warp/
Other
4.28k stars 243 forks source link

[BUG] OpenGLRenderer example: example_render_opengl.py #312

Closed mmmovania closed 2 months ago

mmmovania commented 2 months ago

Bug Description

When setting the argument --num_tiles to 1 as default, the code gives a divison by zero error at line 117 aspect_ratio = example.renderer.tile_height / example.renderer.tile_width Image

An easy fix is to simply change line 34 in class Example from this if num_tiles > 1: to this if num_tiles >= 1:

and then it works fine.

System Information

No response

shi-eric commented 2 months ago

Thanks for reporting the issue, it should now be fixed in the main branch.