GUI and setHardwareScalingLevel

Version: 7.45.0
Engine: any
Browser: any

There is a setHardwareScalingLevel method of engine, which is often used to adapt for scaling of the browser, of dpi scaling of the OS.
Setting this can get better pixel-aligned rendering of the 3d content without changing the size of rendered meshes, but in case of 2d (gui), it changes the size of rendered gui.

See this playground for example of how setHardwareScalingLevel affect GUI (CreateFullscreenUI in this case):

So, is there an option, or should there be one, to make 2d GUI have the same behavior as 3d meshes, to not scale when setHardwareScalingLevel changes?

You can compensate with renderScale:
gg | Babylon.js Playground

So it’s only possible to do it manually? Should there be an option that the renderScale would auto align with setHardwareScalingLevel?

It is possible to add this to the resize function of the advanced dynamic texture, but it will be a break change so we will need to put it behind a flag.

This is interesting, that said, how do you maintain high resolution

e.g.,
(engine.setHardwareScalingLevel(.3); )

with a frame rate over 145 fps? How do you optimize this as such

computer.setHardwareScalingLevel(5090) :grin:

You forgot the units!

computer.setHardwareScalingLevel(5090TI)

Joke aside, there are always tradeoffs with anything you do - quality means, usually, a reduction of performance. If there was a magical solution that will get you to 144 fps while rendering in 8k without replacing your GPU to an RTX PRO 6000, believe me, we would have implemented it already