Correcting non-square pixels application-wide
-
My application (also) runs on screens that have non-square pixels. Suddenly, a circle is an ellipse, a square is a rectangle, and it all looks pretty stupid.
I am looking for ideas on how I can fix that, if possible in an application-wide fashion. Something that would ideally stretch the whole Qt application (Widgets, GraphicsView, QML) by a factor to account for the hardware.
I pretty much know I can do in GraphicsView whatever I want, but it would leave all Widget and QML parts aside. I'd prefer something that works on a more global level.
-
My application (also) runs on screens that have non-square pixels. Suddenly, a circle is an ellipse, a square is a rectangle, and it all looks pretty stupid.
I am looking for ideas on how I can fix that, if possible in an application-wide fashion. Something that would ideally stretch the whole Qt application (Widgets, GraphicsView, QML) by a factor to account for the hardware.
I pretty much know I can do in GraphicsView whatever I want, but it would leave all Widget and QML parts aside. I'd prefer something that works on a more global level.
@Asperamanca Are you sure the problem is "non-square pixels" and not simply wrong resolution configured? You also did not say what screen/device that is.
-
@Asperamanca Are you sure the problem is "non-square pixels" and not simply wrong resolution configured? You also did not say what screen/device that is.
@jsulm In this case it's an industrial touch panel. I take the technical specs as a given...
-
@jsulm In this case it's an industrial touch panel. I take the technical specs as a given...
@Asperamanca Are you sure you configured the correct resolution?
-
I checked the specs. Native resolution is 800x480, Active screen area is 154,08x85,92 mm. That means a single pixel has a size of 0,1926 x 0,179 mm
I could try to set a resolution of 861x480 px in the operating system and see whether the driver is able to cope with it...
-
I checked the specs. Native resolution is 800x480, Active screen area is 154,08x85,92 mm. That means a single pixel has a size of 0,1926 x 0,179 mm
I could try to set a resolution of 861x480 px in the operating system and see whether the driver is able to cope with it...
@Asperamanca
In the end, I simply used the view transformation of GraphicsView to solve this (only for GraphicsView, for now)