weekit / WeeKit

A tiny toolkit for interactive Rust applications.
Apache License 2.0
11 stars 0 forks source link

Rocks appears frozen when run #3

Open scomp opened 5 years ago

scomp commented 5 years ago

Rocks appears frozen when run, though it updates when window is resized.

Am I missing something here - what key is used to start game?

Running on Mojave 10.14

timburks commented 5 years ago

I think this is related to Apple's deprecation of OpenGL on Mojave. When I build and run on Mojave, I get the same error. I also get a bunch of warnings building the platform.a support library:

clang platform/macOS/platform.m -c -g -I platform/macOS -I third-party/amanithvg-sdk/include -I /usr/local/include -I src  -o foo/platform.o
platform/macOS/platform.m:48:21: warning: 'NSOpenGLView' is deprecated: first deprecated in macOS 10.14 - Please use MTKView instead.
      [-Wdeprecated-declarations]
@interface WKView : NSOpenGLView <NSWindowDelegate> {
                    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGLView.h:16:12: note: 
      'NSOpenGLView' has been explicitly marked deprecated here
@interface NSOpenGLView : NSView {
           ^
platform/macOS/platform.m:165:3: warning: 'NSOpenGLPixelFormatAttribute' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
  NSOpenGLPixelFormatAttribute attributes[] = {
  ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:99:18: note: 
      'NSOpenGLPixelFormatAttribute' has been explicitly marked deprecated here
typedef uint32_t NSOpenGLPixelFormatAttribute NS_OPENGL_DEPRECATED(10_0, 10_14);
                 ^
platform/macOS/platform.m:166:5: warning: 'NSOpenGLPFAAccelerated' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFAAccelerated,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:78:5: note: 
      'NSOpenGLPFAAccelerated' has been explicitly marked deprecated here
    NSOpenGLPFAAccelerated           NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =  73,     /* choose a hardware accelerated renderer       */
    ^
platform/macOS/platform.m:167:5: warning: 'NSOpenGLPFANoRecovery' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFANoRecovery,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:77:5: note: 
      'NSOpenGLPFANoRecovery' has been explicitly marked deprecated here
    NSOpenGLPFANoRecovery            NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =  72,     /* disable all failure recovery systems         */
    ^
platform/macOS/platform.m:168:5: warning: 'NSOpenGLPFADoubleBuffer' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFADoubleBuffer,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:60:5: note: 
      'NSOpenGLPFADoubleBuffer' has been explicitly marked deprecated here
    NSOpenGLPFADoubleBuffer          NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =   5,     /* choose a double buffered pixel format        */
    ^
platform/macOS/platform.m:169:5: warning: 'NSOpenGLPFAOpenGLProfile' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFAOpenGLProfile, NSOpenGLProfileVersionLegacy,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:84:5: note: 
      'NSOpenGLPFAOpenGLProfile' has been explicitly marked deprecated here
    NSOpenGLPFAOpenGLProfile         NS_OPENGL_ENUM_DEPRECATED(10_7, 10_14)  =  99,    /* specify an OpenGL Profile to use             */
    ^
platform/macOS/platform.m:169:31: warning: 'NSOpenGLProfileVersionLegacy' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFAOpenGLProfile, NSOpenGLProfileVersionLegacy,
                              ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:103:5: note: 
      'NSOpenGLProfileVersionLegacy' has been explicitly marked deprecated here
    NSOpenGLProfileVersionLegacy     NS_OPENGL_ENUM_DEPRECATED(10_7, 10_14)  = 0x1000,   /* choose a Legacy/Pre-OpenGL 3.0 Implementation */
    ^
platform/macOS/platform.m:170:5: warning: 'NSOpenGLPFAColorSize' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFAColorSize, 32,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:62:5: note: 
      'NSOpenGLPFAColorSize' has been explicitly marked deprecated here
    NSOpenGLPFAColorSize             NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =   8,     /* number of color buffer bits                  */
    ^
platform/macOS/platform.m:172:5: warning: 'NSOpenGLPFASupersample' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFASupersample,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:74:5: note: 
      'NSOpenGLPFASupersample' has been explicitly marked deprecated here
    NSOpenGLPFASupersample           NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =  60,    /* choose supersampling                         */
    ^
platform/macOS/platform.m:173:5: warning: 'NSOpenGLPFADepthSize' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFADepthSize, 24,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:64:5: note: 
      'NSOpenGLPFADepthSize' has been explicitly marked deprecated here
    NSOpenGLPFADepthSize             NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =  12,     /* number of depth buffer bits                  */
    ^
platform/macOS/platform.m:174:5: warning: 'NSOpenGLPFAStencilSize' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFAStencilSize, 8,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:65:5: note: 
      'NSOpenGLPFAStencilSize' has been explicitly marked deprecated here
    NSOpenGLPFAStencilSize           NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =  13,     /* number of stencil buffer bits                */
    ^
platform/macOS/platform.m:175:5: warning: 'NSOpenGLPFASampleBuffers' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFASampleBuffers, 1,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:69:5: note: 
      'NSOpenGLPFASampleBuffers' has been explicitly marked deprecated here
    NSOpenGLPFASampleBuffers         NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =  55,     /* number of multi sample buffers               */
    ^
platform/macOS/platform.m:176:5: warning: 'NSOpenGLPFASamples' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    NSOpenGLPFASamples, 8,
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:70:5: note: 
      'NSOpenGLPFASamples' has been explicitly marked deprecated here
    NSOpenGLPFASamples               NS_OPENGL_ENUM_DEPRECATED(10_0, 10_14)  =  56,     /* number of samples per multi sample buffer    */
    ^
platform/macOS/platform.m:177:6: warning: 'NSOpenGLPixelFormatAttribute' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
    (NSOpenGLPixelFormatAttribute)0
     ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:99:18: note: 
      'NSOpenGLPixelFormatAttribute' has been explicitly marked deprecated here
typedef uint32_t NSOpenGLPixelFormatAttribute NS_OPENGL_DEPRECATED(10_0, 10_14);
                 ^
platform/macOS/platform.m:179:3: warning: 'NSOpenGLPixelFormat' is deprecated: first deprecated in macOS 10.14 - Please use Metal or MetalKit.
      [-Wdeprecated-declarations]
  NSOpenGLPixelFormat *format = [[NSOpenGLPixelFormat alloc] initWithAttributes:attributes];
  ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:113:12: note: 
      'NSOpenGLPixelFormat' has been explicitly marked deprecated here
@interface NSOpenGLPixelFormat : NSObject <NSCoding>
           ^
platform/macOS/platform.m:179:55: warning: 'NSOpenGLPixelFormat' is deprecated: first deprecated in macOS 10.14 - Please use Metal or MetalKit.
      [-Wdeprecated-declarations]
  NSOpenGLPixelFormat *format = [[NSOpenGLPixelFormat alloc] initWithAttributes:attributes];
                                                      ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:113:12: note: 
      'NSOpenGLPixelFormat' has been explicitly marked deprecated here
@interface NSOpenGLPixelFormat : NSObject <NSCoding>
           ^
platform/macOS/platform.m:208:57: warning: 'NSOpenGLCPSwapInterval' is deprecated: first deprecated in macOS 10.14 [-Wdeprecated-declarations]
  [[self openGLContext] setValues:&swapInt forParameter:NSOpenGLCPSwapInterval];
                                                        ^~~~~~~~~~~~~~~~~~~~~~
                                                        NSOpenGLContextParameterSwapInterval
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSOpenGL.h:281:39: note: 
      'NSOpenGLCPSwapInterval' has been explicitly marked deprecated here
static const NSOpenGLContextParameter NSOpenGLCPSwapInterval NS_DEPRECATED_WITH_REPLACEMENT_MAC("NSOpenGLContextParameterSwapInterval", 10_5, 10_1...
                                      ^
platform/macOS/platform.m:240:13: warning: 'lockFocusIfCanDraw' is deprecated: first deprecated in macOS 10.14 - To draw, subclass NSView and implement
      -drawRect:; AppKit's automatic deferred display mechanism will call -drawRect: as necessary to display the view. [-Wdeprecated-declarations]
  if ([self lockFocusIfCanDraw]) {
            ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSView.h:237:1: note: 
      'lockFocusIfCanDraw' has been explicitly marked deprecated here
- (BOOL)lockFocusIfCanDraw NS_DEPRECATED_MAC(10_0, 10_14, "To draw, subclass NSView and implement -drawRect:; AppKit's automatic deferred display ...
^
platform/macOS/platform.m:246:5: warning: 'CGLLockContext' is deprecated: first deprecated in macOS 10.14 - OpenGL API deprecated. (Define
      GL_SILENCE_DEPRECATION to silence these warnings) [-Wdeprecated-declarations]
    CGLLockContext([[self openGLContext] CGLContextObj]);
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/OpenGL.framework/Headers/OpenGL.h:110:17: note: 
      'CGLLockContext' has been explicitly marked deprecated here
extern CGLError CGLLockContext(CGLContextObj ctx) OPENGL_AVAILABLE(10_4) OPENGL_DEPRECATED(10.4, 10.14);
                ^
platform/macOS/platform.m:252:5: warning: 'CGLFlushDrawable' is deprecated: first deprecated in macOS 10.14 - OpenGL API deprecated. (Define
      GL_SILENCE_DEPRECATION to silence these warnings) [-Wdeprecated-declarations]
    CGLFlushDrawable([[self openGLContext] CGLContextObj]);
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/OpenGL.framework/Headers/OpenGL.h:79:17: note: 
      'CGLFlushDrawable' has been explicitly marked deprecated here
extern CGLError CGLFlushDrawable(CGLContextObj ctx) OPENGL_DEPRECATED(10.0, 10.14);
                ^
platform/macOS/platform.m:258:5: warning: 'CGLUnlockContext' is deprecated: first deprecated in macOS 10.14 - OpenGL API deprecated. (Define
      GL_SILENCE_DEPRECATION to silence these warnings) [-Wdeprecated-declarations]
    CGLUnlockContext([[self openGLContext] CGLContextObj]);
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/OpenGL.framework/Headers/OpenGL.h:112:17: note: 
      'CGLUnlockContext' has been explicitly marked deprecated here
extern CGLError CGLUnlockContext(CGLContextObj ctx) OPENGL_AVAILABLE(10_4) OPENGL_DEPRECATED(10.4, 10.14);
                ^
platform/macOS/platform.m:259:11: warning: 'unlockFocus' is deprecated: first deprecated in macOS 10.14 - To draw, subclass NSView and implement
      -drawRect:; AppKit's automatic deferred display mechanism will call -drawRect: as necessary to display the view. [-Wdeprecated-declarations]
    [self unlockFocus];
          ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSView.h:236:1: note: 
      'unlockFocus' has been explicitly marked deprecated here
- (void)unlockFocus NS_DEPRECATED_MAC(10_0, 10_14, "To draw, subclass NSView and implement -drawRect:; AppKit's automatic deferred display mechani...
^
platform/macOS/platform.m:268:13: warning: 'lockFocusIfCanDraw' is deprecated: first deprecated in macOS 10.14 - To draw, subclass NSView and implement
      -drawRect:; AppKit's automatic deferred display mechanism will call -drawRect: as necessary to display the view. [-Wdeprecated-declarations]
  if ([self lockFocusIfCanDraw]) {
            ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSView.h:237:1: note: 
      'lockFocusIfCanDraw' has been explicitly marked deprecated here
- (BOOL)lockFocusIfCanDraw NS_DEPRECATED_MAC(10_0, 10_14, "To draw, subclass NSView and implement -drawRect:; AppKit's automatic deferred display ...
^
platform/macOS/platform.m:274:5: warning: 'CGLLockContext' is deprecated: first deprecated in macOS 10.14 - OpenGL API deprecated. (Define
      GL_SILENCE_DEPRECATION to silence these warnings) [-Wdeprecated-declarations]
    CGLLockContext([[self openGLContext] CGLContextObj]);
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/OpenGL.framework/Headers/OpenGL.h:110:17: note: 
      'CGLLockContext' has been explicitly marked deprecated here
extern CGLError CGLLockContext(CGLContextObj ctx) OPENGL_AVAILABLE(10_4) OPENGL_DEPRECATED(10.4, 10.14);
                ^
platform/macOS/platform.m:288:5: warning: 'CGLUnlockContext' is deprecated: first deprecated in macOS 10.14 - OpenGL API deprecated. (Define
      GL_SILENCE_DEPRECATION to silence these warnings) [-Wdeprecated-declarations]
    CGLUnlockContext([[self openGLContext] CGLContextObj]);
    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/OpenGL.framework/Headers/OpenGL.h:112:17: note: 
      'CGLUnlockContext' has been explicitly marked deprecated here
extern CGLError CGLUnlockContext(CGLContextObj ctx) OPENGL_AVAILABLE(10_4) OPENGL_DEPRECATED(10.4, 10.14);
                ^
platform/macOS/platform.m:289:11: warning: 'unlockFocus' is deprecated: first deprecated in macOS 10.14 - To draw, subclass NSView and implement
      -drawRect:; AppKit's automatic deferred display mechanism will call -drawRect: as necessary to display the view. [-Wdeprecated-declarations]
    [self unlockFocus];
          ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/System/Library/Frameworks/AppKit.framework/Headers/NSView.h:236:1: note: 
      'unlockFocus' has been explicitly marked deprecated here
- (void)unlockFocus NS_DEPRECATED_MAC(10_0, 10_14, "To draw, subclass NSView and implement -drawRect:; AppKit's automatic deferred display mechani...
^
26 warnings generated.