[Bf-committers] DPI scaling question...

Brecht Van Lommel brechtvanlommel at pandora.be
Thu Jun 27 13:43:03 CEST 2013


On Thu, Jun 27, 2013 at 9:38 AM, David Jeske <davidj at gmail.com> wrote:
> ...which brings us back to my original question. Why is DPI exposed to so
> much blender code? If there was a virtual coordinate system and DPI/PIXEL
> scaling was hidden, then none of these places would know about DPI, node
> placement would be right, and node spacing would be consistent.
>
> Is this to avoid a wrapper around the GL calls for 2d operations? Does that
> overhead matter? They could be inlined.

I don't know the reason behind this, Ton decided to do it this way
when he worked on DPI and later retina support. I would have
implemented it at a lower level too in the UI code, though maybe not
as an OpenGL wrapper because you still want to round to integer
coordinates for final button drawing I think, or have line thickness
of 1 or 2, not 1.5 if you want things to draw crisp.

Brecht.


More information about the Bf-committers mailing list