Re: Mac Retian and OpenGL
Zhipeng Shi <[email protected]> Wed, 14 Jan 2026 20:49:47 -0800 (PST)
| Newsgroups | gmane.comp.lib.wxwindows.general |
|---|---|
| Message-ID | <[email protected]> |
Dear VZ,
I am building my projects with wxWidget3.3.1. But It built with some
errors. I think this is caused by the differences between the APIs of
wxWidgets 3.3.1 and wxWidgets 3.2.9. I'm currently fixing this issue and
will let you know the result later.
Thank you very much!
Best Regards
Shi
在2026年1月12日星期一 UTC+8 23:27:30<Vadim Zeitlin> 写道:
> On Sun, 11 Jan 2026 21:06:00 -0800 (PST) Zhipeng Shi wrote:
>
> ZS> I'm using wxGLCanvas to render OpenGL on a Retina display of a Mac.
> ZS> During rendering, I have to use glViewport(0, 0,
> GetContentScaleFactor() *
> ZS> width, GetContentScaleFactor() * height) to achieve full-screen
> rendering,
> ZS> instead of rendering only in the bottom-left quarter of the area.
>
> This is correct, glViewport() requires physical pixels, while wxWidgets
> API works (with some exceptions) with logical pixels.
>
> ZS> However, when I want to use pick to select a certain rendering unit,
> ZS> wxGetMousePosition() returns physical coordinates.
>
> This looks like a bug, it should return logical coordinates.
>
> ZS> My Mac version is 26.2, and the wxWidgets version is 3.2.9.
>
> Please check if wxGetMousePosition() works correctly with 3.3.1. If it
> does, we may need to backport some fix from 3.3 into 3.2. And if it
> doesn't, we still need to fix this.
>
> Thanks,
> VZ
>
> --
> TT-Solutions: wxWidgets consultancy and technical support
> https://www.tt-solutions.com/
>
--
Please read https://www.wxwidgets.org/support/mlhowto.htm before posting.
---
You received this message because you are subscribed to the Google Groups "wx-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To view this discussion visit https://groups.google.com/d/msgid/wx-users/192bc223-a032-4b93-be3f-966cac3cd42dn%40googlegroups.com.