-
Notifications
You must be signed in to change notification settings - Fork 109
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #422 from OpenSmalltalk/hack_to_restore_b3D_macos3…
…2x86 hack to restore B3DAcceleratorPlugin on macos32x86 No objection, it fixes issue #397, without causing any supplementary CI failure (our cog trunk branch status is a tiny bit less red, but still red, as it should never be, but constantly is...). Let's move to something else.
- Loading branch information
Showing
9 changed files
with
1,550 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# The current version of B3DAcceleratorPlugin (the OpenGL interface) uses lots | ||
# of Carbon code & is hence 32-bit only. So include the Carbon frameworks. | ||
# Until this can be rewritten this implies no 64-bit OpenGL on Mac OS X :-(. | ||
|
||
INCDIRS:=$(PLATDIR)/Cross/plugins/FilePlugin \ | ||
$(PLATDIR)/unix/vm | ||
INCDIRS:=$(PLATDIR)/unix/vm | ||
|
||
EXTRADYFLAGS=-Wl,-U,_getImageName,-U,_getSTWindow,-U,_setWindowChangedHook,-U,_warning \ | ||
-Wl,-U,_getMainWindowOpenGLContext,-U,_createOpenGLTextureLayerHandle,-U,_destroyOpenGLTextureLayerHandle,-U,_setOpenGLTextureLayerContent | ||
EXTRALIBS:= -framework CoreFoundation -framework OpenGL -framework Cocoa | ||
#EXTRALIBS:= -framework OpenGL -framework AGL | ||
|
||
include ../common/Makefile.plugin |
47 changes: 47 additions & 0 deletions
47
platforms/iOS/plugins/B3DAcceleratorPlugin32/sqMacOpenGL.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
#ifndef SQ_MAC_OPENGL_H | ||
#define SQ_MAC_OPENGL_H | ||
|
||
#define MAX_RENDERER 16 | ||
|
||
# import <OpenGL/gl.h> | ||
#if __MAC_OS_X_VERSION_MAX_ALLOWED >= 1070 | ||
# import <OpenGL/OpenGL.h> | ||
#else | ||
# import <OpenGL/Opengl.h> | ||
#endif | ||
|
||
typedef struct glRendererFramebuffer { | ||
GLuint handle; | ||
GLuint texture; | ||
GLuint depthStencilBuffer; | ||
|
||
GLuint resolveFramebuffer; | ||
GLuint multisampleColorbuffer; | ||
} glRendererFramebuffer; | ||
|
||
typedef struct glRenderer { | ||
/* Required by the common implementation */ | ||
GLint bufferRect[4]; | ||
GLint viewport[4]; | ||
|
||
int used; | ||
|
||
void* theOpenGLContext; | ||
unsigned int layerHandle; | ||
|
||
// Multi sampling | ||
int hasMultisampling; | ||
int sampleCount; | ||
|
||
// Depth and stencil buffer | ||
int hasStencilBuffer; | ||
GLenum depthStencilFormat; | ||
|
||
glRendererFramebuffer framebuffers[2]; | ||
unsigned int backBufferIndex; | ||
|
||
} glRenderer; | ||
|
||
#define GL_RENDERER_DEFINED 1 | ||
|
||
#endif /* SQ_MAC_OPENGL_H */ |
Oops, something went wrong.