如此处所述,我在将使用 MonoGame 开发的现有 Android 游戏移植到诺基亚 X 时遇到困难。
OpenTK 似乎无法正确检测设备功能或类似情况:
OpenTK.Platform.Android.EglException: Failed to find a valid GraphicsMode configuration
at OpenTK.Platform.Android.AndroidGraphicsMode.ChooseConfig (Javax.Microedition.Khronos.Egl.EGLDisplay display) [0x0035c] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.10.1-branch/9d03ce3e/source/monodroid/src/OpenGLES/Android/AndroidGraphicsMode.cs:186
at OpenTK.Platform.Android.AndroidGraphicsMode.Initialize (Javax.Microedition.Khronos.Egl.EGLDisplay display, Int32 version) [0x0000a] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.10.1-branch/9d03ce3e/source/monodroid/src/OpenGLES/Android/AndroidGraphicsMode.cs:223
at OpenTK.Platform.Android.AndroidGraphicsContext.Init (OpenTK.Graphics.GraphicsMode mode, IWindowInfo win, IGraphicsContext sharedContext, Int32 major, GraphicsContextFlags flags) [0x000a9] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.10.1-branch/9d03ce3e/source/monodroid/src/OpenGLES/Android/AndroidGraphicsContext.cs:114
at OpenTK.Platform.Android.AndroidGraphicsContext..ctor (OpenTK.Graphics.GraphicsMode mode, IWindowInfo window, IGraphicsContext sharedContext, GLContextVersion glesVersion, GraphicsContextFlags flags) [0x00015] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.10.1-branch/9d03ce3e/source/monodroid/src/OpenGLES/Android/AndroidGraphicsContext.cs:88
at OpenTK.Platform.Android.AndroidGraphicsContext.CreateGraphicsContext (OpenTK.Graphics.GraphicsMode mode, IWindowInfo window, IGraphicsContext sharedContext, GLContextVersion glVersion, GraphicsContextFlags flags) [0x00007] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.10.1-branch/9d03ce3e/source/monodroid/src/OpenGLES/Android/AndroidGraphicsContext.cs:50
at OpenTK.Platform.Android.AndroidGameView.CreateContext () [0x0001b] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.10.1-branch/9d03ce3e/source/monodroid/src/OpenGLES/Android/AndroidGameView.cs:314
at OpenTK.Platform.Android.AndroidGameView.CreateFrameBuffer () [0x00002] in /Users/builder/data/lanes/monodroid-mlion-monodroid-4.10.1-branch/9d03ce3e/source/monodroid/src/OpenGLES/Android/AndroidGameView.cs:165
at Microsoft.Xna.Framework.AndroidGameWindow.CreateFrameBuffer () [0x0003f] in /Users/paulharman/MonoGame/MonoGame.Framework/Android/AndroidGameWindow.cs:164
我要求的是 800x480 屏幕(这是设备的本机屏幕尺寸)和颜色模式(8,8,8,8) - 尽管 MonoGame 本身尝试各种回退到更简单的位深度、模板等,但似乎没有工作。
有没有其他人看到这个问题并知道可能出了什么问题?
在撰写本文时,我正在使用 MonoGame(开发分支)的提示。Xamarin 详细信息:
=== Xamarin 工作室 ===
版本 4.2.3 (build 54) 安装 UUID: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx 运行时: Mono 3.2.6 ((no/9b58377) GTK+ 2.24.23 主题: Raleigh GTK# (2.12.0.0) 包版本: 302060000
=== 苹果开发者工具 ===
Xcode 5.0.2 (3335.32) 构建 5A3005
=== Xamarin.Mac ===
Xamarin.Mac:未安装
=== Xamarin.iOS ===
版本:7.0.6.168(商业版)哈希:2ed9bc9 分支:构建日期:2014-21-01 06:33:05-0500
=== Xamarin.Android ===
版本:4.10.1(商业版) Android SDK:/Users/paulharman/Library/Developer/Xamarin/android-sdk-mac_x86 支持的Android版本:1.6(API级别4)2.1(API级别7)2.2(API级别8) 2.3(API 级别 10) 3.1(API 级别 12) 3.2(API 级别 13) 4.0(API 级别 14) 4.0.3(API 级别 15) 4.1(API 级别 16) 4.2(API 级别 17) 4.4(API 级别 19) Java SDK: /usr java version "1.6.0_65" Java(TM) SE Runtime Environment (build 1.6.0_65-b14-462-11M4609) Java HotSpot(TM) 64-Bit Server VM (build 20.65-b04-462, mixed模式)
=== 构建信息 ===
发布 ID:402030054 Git 修订:f3fd2a8582693cd1728166bcfc17056235cb5b05 构建日期:2014-02-03 17:26:56+0000 Xamarin 插件:b992974cc7bee7713bba6abaf2b4fac94e67dd1c
=== 操作系统 ===
Mac OS X 10.9.1 Darwin HOSTNAME 13.0.0 Darwin Kernel Version 13.0.0 Thu Sep 19 22:22:27 PDT 2013 root:xnu-2422.1.72~6/RELEASE_X86_64 x86_64