jdryg / vg-renderer

A vector graphics renderer for bgfx, based on ideas from NanoVG and ImDrawList (Dear ImGUI)
BSD 2-Clause "Simplified" License
504 stars 55 forks source link

Fix devicePixelRatio setting incorrect scissor. #28

Closed mcourteaux closed 3 months ago

mcourteaux commented 3 months ago

Everything in the vg API is using "canvas" coordinates, which is then stretched using the view-transform matrix. However, the scissor commands were also executed using canvas coordinates, instead of device coordinates.

Ping @bkaradzic

bkaradzic commented 3 months ago

@mcourteaux You should submit this PR to C99 branch here: https://github.com/bkaradzic/vg-renderer/tree/c99