52 lines
1.5 KiB
Diff
52 lines
1.5 KiB
Diff
=== modified file 'include/wx/glcanvas.h'
|
|
--- include/wx/glcanvas.h 2015-05-21 00:36:27.406145182 +0200
|
|
+++ include/wx/glcanvas.h 2015-05-21 00:37:59.169474782 +0200
|
|
@@ -19,6 +19,8 @@
|
|
#include "wx/palette.h"
|
|
#include "wx/window.h"
|
|
|
|
+#define RETINA_OPENGL_PATCH
|
|
+
|
|
class WXDLLIMPEXP_FWD_GL wxGLCanvas;
|
|
class WXDLLIMPEXP_FWD_GL wxGLContext;
|
|
|
|
=== modified file 'include/wx/osx/glcanvas.h'
|
|
--- include/wx/osx/glcanvas.h 2015-05-21 00:36:27.419478515 +0200
|
|
+++ include/wx/osx/glcanvas.h 2015-05-21 00:36:37.319478112 +0200
|
|
@@ -88,6 +88,9 @@ public:
|
|
// update the view port of the current context to match this window
|
|
void SetViewport();
|
|
|
|
+ void SetViewWantsBestResolution( bool aValue );
|
|
+ bool GetViewWantsBestResolution();
|
|
+ float GetBackingScaleFactor();
|
|
|
|
// deprecated methods
|
|
// ------------------
|
|
=== modified file 'src/osx/cocoa/glcanvas.mm'
|
|
--- src/osx/cocoa/glcanvas.mm 2015-05-21 00:36:27.542811843 +0200
|
|
+++ src/osx/cocoa/glcanvas.mm 2015-05-21 00:36:37.322811445 +0200
|
|
@@ -313,6 +313,22 @@ bool wxGLCanvas::SwapBuffers()
|
|
return true;
|
|
}
|
|
|
|
+void wxGLCanvas::SetViewWantsBestResolution( bool aValue )
|
|
+{
|
|
+ [GetHandle() setWantsBestResolutionOpenGLSurface:aValue];
|
|
+}
|
|
+
|
|
+bool wxGLCanvas::GetViewWantsBestResolution()
|
|
+{
|
|
+ return [GetHandle() wantsBestResolutionOpenGLSurface];
|
|
+}
|
|
+
|
|
+float wxGLCanvas::GetBackingScaleFactor()
|
|
+{
|
|
+ return [[GetHandle() window] backingScaleFactor];
|
|
+}
|
|
+
|
|
+
|
|
bool wxGLContext::SetCurrent(const wxGLCanvas& win) const
|
|
{
|
|
if ( !m_glContext )
|