分辨率处理

imgui的很多代码需要自己设置大小,例如 ImGui::SetNextItemWidth(200.0f);

但是会导致渲染出来在1080p和4k分辨率下大小会不一样,就像这个issue描述的:

https://github.com/ocornut/imgui/issues/3676

官方的解决方法可以参考:

https://github.com/ocornut/imgui/blob/master/docs/FAQ.md#q-how-should-i-handle-dpi-in-my-application

Last updated