mirror of https://github.com/bjornbytes/lovr.git
Fixes as far as running without crashes, no display yet
This commit is contained in:
parent
56f8f1e26b
commit
5ad8fdd3e3
|
@ -18,9 +18,9 @@ option(LOVR_ENABLE_JSON "Bundle with lua-cjson" ON)
|
||||||
|
|
||||||
option(LOVR_USE_LUAJIT "Use LuaJIT instead of Lua" ON)
|
option(LOVR_USE_LUAJIT "Use LuaJIT instead of Lua" ON)
|
||||||
option(LOVR_USE_ASSIMP "Enable model loading with Assimp" ON)
|
option(LOVR_USE_ASSIMP "Enable model loading with Assimp" ON)
|
||||||
option(LOVR_USE_OPENVR "Enable the OpenVR backend for the headset module" ON)
|
|
||||||
option(LOVR_USE_WEBVR "Enable the WebVR backend for the headset module" OFF)
|
option(LOVR_USE_WEBVR "Enable the WebVR backend for the headset module" OFF)
|
||||||
option(LOVR_USE_OCULUS "Enable the LibOVR backend for the headset module (be sure to also set LOVR_OCULUS_PATH to point to the Oculus SDK)" OFF)
|
option(LOVR_USE_OCULUS "Enable the LibOVR backend for the headset module (be sure to also set LOVR_OCULUS_PATH to point to the Oculus SDK)" OFF)
|
||||||
|
option(LOVR_USE_OCULUS_MOBILE "Enable the Oculus Mobile (Android) backend for the headset module" OFF)
|
||||||
option(LOVR_USE_FAKE_HEADSET "Enable the keyboard/mouse backend for the headset module" ON)
|
option(LOVR_USE_FAKE_HEADSET "Enable the keyboard/mouse backend for the headset module" ON)
|
||||||
option(LOVR_USE_SSE "Enable SIMD use of intrinsics" ON)
|
option(LOVR_USE_SSE "Enable SIMD use of intrinsics" ON)
|
||||||
|
|
||||||
|
@ -60,6 +60,17 @@ if(EMSCRIPTEN)
|
||||||
set(LOVR_USE_OPENVR OFF)
|
set(LOVR_USE_OPENVR OFF)
|
||||||
set(LOVR_USE_OCULUS OFF)
|
set(LOVR_USE_OCULUS OFF)
|
||||||
set(LOVR_USE_SSE OFF)
|
set(LOVR_USE_SSE OFF)
|
||||||
|
elseif(ANDROID)
|
||||||
|
#set(LOVR_ANDROID_FLAGS "-Wno-narrowing")
|
||||||
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${LOVR_ANDROID_FLAGS}")
|
||||||
|
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${LOVR_ANDROID_FLAGS}")
|
||||||
|
|
||||||
|
set(LOVR_USE_OPENVR OFF)
|
||||||
|
set(LOVR_USE_OCULUS OFF)
|
||||||
|
set(LOVR_USE_FAKE_HEADSET OFF)
|
||||||
|
set(LOVR_USE_OCULUS_MOBILE ON)
|
||||||
|
set(LOVR_USE_LUAJIT OFF) # Until buildvm re-invoke works
|
||||||
|
set(LOVR_USE_SSE OFF) # Assume ARM. Technically wrong on Android X86…?
|
||||||
elseif(UNIX)
|
elseif(UNIX)
|
||||||
if(APPLE)
|
if(APPLE)
|
||||||
set(CMAKE_MACOSX_RPATH 1)
|
set(CMAKE_MACOSX_RPATH 1)
|
||||||
|
@ -104,6 +115,9 @@ if(LOVR_ENABLE_DATA AND LOVR_USE_ASSIMP)
|
||||||
set(ZLIB_LIBRARIES "-s USE_ZLIB=1")
|
set(ZLIB_LIBRARIES "-s USE_ZLIB=1")
|
||||||
set(ZLIB_INCLUDE_DIR "assimp/contrib/zlib")
|
set(ZLIB_INCLUDE_DIR "assimp/contrib/zlib")
|
||||||
endif()
|
endif()
|
||||||
|
if (ANDROID)
|
||||||
|
set(ASSIMP_BUILD_ZLIB ON CACHE BOOL "")
|
||||||
|
endif()
|
||||||
set(ASSIMP_BUILD_ASSIMP_TOOLS OFF CACHE BOOL "")
|
set(ASSIMP_BUILD_ASSIMP_TOOLS OFF CACHE BOOL "")
|
||||||
set(ASSIMP_BUILD_TESTS OFF CACHE BOOL "")
|
set(ASSIMP_BUILD_TESTS OFF CACHE BOOL "")
|
||||||
set(ASSIMP_NO_EXPORT ON CACHE BOOL "")
|
set(ASSIMP_NO_EXPORT ON CACHE BOOL "")
|
||||||
|
@ -140,7 +154,7 @@ if(LOVR_ENABLE_ENET)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# GLFW
|
# GLFW
|
||||||
if(NOT (EMSCRIPTEN OR OCULUS_ANDROID_EMBED))
|
if(NOT (EMSCRIPTEN OR ANDROID))
|
||||||
if(LOVR_SYSTEM_GLFW)
|
if(LOVR_SYSTEM_GLFW)
|
||||||
pkg_search_module(GLFW REQUIRED glfw3)
|
pkg_search_module(GLFW REQUIRED glfw3)
|
||||||
include_directories(${GLFW_INCLUDE_DIRS})
|
include_directories(${GLFW_INCLUDE_DIRS})
|
||||||
|
@ -157,7 +171,7 @@ if(NOT (EMSCRIPTEN OR OCULUS_ANDROID_EMBED))
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Lua
|
# Lua
|
||||||
if(LOVR_USE_LUAJIT AND NOT (EMSCRIPTEN OR OCULUS_ANDROID_EMBED))
|
if(LOVR_USE_LUAJIT AND NOT (EMSCRIPTEN OR ANDROID))
|
||||||
if (APPLE)
|
if (APPLE)
|
||||||
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -pagezero_size 10000 -image_base 100000000")
|
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -pagezero_size 10000 -image_base 100000000")
|
||||||
endif()
|
endif()
|
||||||
|
@ -180,9 +194,6 @@ else()
|
||||||
option(LUA_USE_ULONGJMP OFF)
|
option(LUA_USE_ULONGJMP OFF)
|
||||||
option(LUA_USE_POPEN OFF)
|
option(LUA_USE_POPEN OFF)
|
||||||
endif()
|
endif()
|
||||||
if (OCULUS_ANDROID_EMBED)
|
|
||||||
set_target_properties(lua luac liblua liblua_static PROPERTIES EXCLUDE_FROM_ALL 1)
|
|
||||||
endif ()
|
|
||||||
if(LOVR_SYSTEM_LUA)
|
if(LOVR_SYSTEM_LUA)
|
||||||
pkg_search_module(LUA REQUIRED lua)
|
pkg_search_module(LUA REQUIRED lua)
|
||||||
include_directories(${LUA_INCLUDE_DIRS})
|
include_directories(${LUA_INCLUDE_DIRS})
|
||||||
|
@ -257,7 +268,7 @@ if(LOVR_ENABLE_AUDIO)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# OpenGL
|
# OpenGL
|
||||||
if(NOT (WIN32 OR EMSCRIPTEN OR OCULUS_ANDROID_EMBED))
|
if(NOT (WIN32 OR EMSCRIPTEN OR ANDROID))
|
||||||
find_package(OpenGL REQUIRED)
|
find_package(OpenGL REQUIRED)
|
||||||
include_directories(${OPENGL_INCLUDE_DIRS})
|
include_directories(${OPENGL_INCLUDE_DIRS})
|
||||||
set(LOVR_OPENGL ${OPENGL_LIBRARIES})
|
set(LOVR_OPENGL ${OPENGL_LIBRARIES})
|
||||||
|
@ -306,15 +317,9 @@ if(NOT WIN32)
|
||||||
set(LOVR_PTHREADS Threads::Threads)
|
set(LOVR_PTHREADS Threads::Threads)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if (NOT OCULUS_ANDROID_EMBED)
|
|
||||||
set(FAKE_SRC src/headset/fake.c)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# LÖVR
|
# LÖVR
|
||||||
|
|
||||||
|
set(LOVR_SRC
|
||||||
|
|
||||||
add_executable(lovr
|
|
||||||
src/main.c
|
src/main.c
|
||||||
src/util.c
|
src/util.c
|
||||||
src/luax.c
|
src/luax.c
|
||||||
|
@ -323,6 +328,14 @@ add_executable(lovr
|
||||||
src/lib/vec/vec.c
|
src/lib/vec/vec.c
|
||||||
)
|
)
|
||||||
|
|
||||||
|
if (ANDROID)
|
||||||
|
# For Android only we build as a library.
|
||||||
|
add_library(lovr SHARED ${LOVR_SRC})
|
||||||
|
target_link_libraries(lovr log EGL)
|
||||||
|
else()
|
||||||
|
add_executable(lovr ${LOVR_SRC})
|
||||||
|
endif()
|
||||||
|
|
||||||
set_target_properties(lovr PROPERTIES C_STANDARD 99)
|
set_target_properties(lovr PROPERTIES C_STANDARD 99)
|
||||||
target_include_directories(lovr PRIVATE src)
|
target_include_directories(lovr PRIVATE src)
|
||||||
target_link_libraries(lovr
|
target_link_libraries(lovr
|
||||||
|
@ -439,6 +452,17 @@ if(LOVR_ENABLE_HEADSET)
|
||||||
add_definitions(-DLOVR_USE_OCULUS)
|
add_definitions(-DLOVR_USE_OCULUS)
|
||||||
target_sources(lovr PRIVATE src/headset/oculus.c)
|
target_sources(lovr PRIVATE src/headset/oculus.c)
|
||||||
endif()
|
endif()
|
||||||
|
if(LOVR_USE_OCULUS_MOBILE)
|
||||||
|
add_definitions(-DLOVR_USE_OCULUS_MOBILE)
|
||||||
|
add_definitions(-DNO_WINDOW=1)
|
||||||
|
|
||||||
|
#add_definitions(-DLOVRAPP_LIBLOVR_INTERNAL_PATH=) # TODO?
|
||||||
|
|
||||||
|
# OCULUS_MOBILE assumes it will be built as part of an Android app, and that it is a git submodule of that app.
|
||||||
|
# The "BridgeLovr" files live in the parent (app) repository:
|
||||||
|
include_directories(../include)
|
||||||
|
target_sources(lovr PRIVATE src/headset/oculus_mobile.c ../BridgeLovr.cpp ../BridgeLovrPrintOverride.cpp)
|
||||||
|
endif()
|
||||||
if(LOVR_USE_WEBVR)
|
if(LOVR_USE_WEBVR)
|
||||||
add_definitions(-DLOVR_USE_WEBVR)
|
add_definitions(-DLOVR_USE_WEBVR)
|
||||||
target_sources(lovr PRIVATE src/headset/webvr.c)
|
target_sources(lovr PRIVATE src/headset/webvr.c)
|
||||||
|
|
|
@ -1,6 +1,10 @@
|
||||||
#include "api.h"
|
#include "api.h"
|
||||||
#include "headset/headset.h"
|
#include "headset/headset.h"
|
||||||
|
|
||||||
|
#if defined(EMSCRIPTEN) || defined(LOVR_USE_OCULUS_MOBILE)
|
||||||
|
#define LOVR_HEADSET_HELPER_USES_REGISTRY
|
||||||
|
#endif
|
||||||
|
|
||||||
const char* ControllerAxes[] = {
|
const char* ControllerAxes[] = {
|
||||||
[CONTROLLER_AXIS_TRIGGER] = "trigger",
|
[CONTROLLER_AXIS_TRIGGER] = "trigger",
|
||||||
[CONTROLLER_AXIS_GRIP] = "grip",
|
[CONTROLLER_AXIS_GRIP] = "grip",
|
||||||
|
@ -32,6 +36,7 @@ const char* ControllerHands[] = {
|
||||||
const char* HeadsetDrivers[] = {
|
const char* HeadsetDrivers[] = {
|
||||||
[DRIVER_FAKE] = "fake",
|
[DRIVER_FAKE] = "fake",
|
||||||
[DRIVER_OCULUS] = "oculus",
|
[DRIVER_OCULUS] = "oculus",
|
||||||
|
[DRIVER_OCULUS_MOBILE] = "oculusmobile",
|
||||||
[DRIVER_OPENVR] = "openvr",
|
[DRIVER_OPENVR] = "openvr",
|
||||||
[DRIVER_WEBVR] = "webvr",
|
[DRIVER_WEBVR] = "webvr",
|
||||||
NULL
|
NULL
|
||||||
|
@ -53,6 +58,7 @@ const char* HeadsetTypes[] = {
|
||||||
[HEADSET_UNKNOWN] = "unknown",
|
[HEADSET_UNKNOWN] = "unknown",
|
||||||
[HEADSET_VIVE] = "vive",
|
[HEADSET_VIVE] = "vive",
|
||||||
[HEADSET_RIFT] = "rift",
|
[HEADSET_RIFT] = "rift",
|
||||||
|
[HEADSET_OCULUS_MOBILE] = "oculusmobile",
|
||||||
[HEADSET_WINDOWS_MR] = "windowsmr",
|
[HEADSET_WINDOWS_MR] = "windowsmr",
|
||||||
NULL
|
NULL
|
||||||
};
|
};
|
||||||
|
@ -64,11 +70,14 @@ typedef struct {
|
||||||
|
|
||||||
static HeadsetRenderData headsetRenderData;
|
static HeadsetRenderData headsetRenderData;
|
||||||
|
|
||||||
|
#include <android/log.h>
|
||||||
|
|
||||||
static void renderHelper(void* userdata) {
|
static void renderHelper(void* userdata) {
|
||||||
HeadsetRenderData* renderData = userdata;
|
HeadsetRenderData* renderData = userdata;
|
||||||
lua_State* L = renderData->L;
|
lua_State* L = renderData->L;
|
||||||
#ifdef EMSCRIPTEN
|
#ifdef LOVR_HEADSET_HELPER_USES_REGISTRY
|
||||||
lua_rawgeti(L, LUA_REGISTRYINDEX, renderData->ref);
|
lua_rawgeti(L, LUA_REGISTRYINDEX, renderData->ref);
|
||||||
|
__android_log_print(ANDROID_LOG_ERROR, "LOVR", "ON ANDROID PATH AS EXPECTED (%d) (%d,%d)", (int)renderData->ref, (int)lua_type(L, -1), (int)LUA_TFUNCTION);
|
||||||
#else
|
#else
|
||||||
lua_pushvalue(L, -1);
|
lua_pushvalue(L, -1);
|
||||||
#endif
|
#endif
|
||||||
|
@ -278,7 +287,7 @@ static int l_lovrHeadsetRenderTo(lua_State* L) {
|
||||||
lua_settop(L, 1);
|
lua_settop(L, 1);
|
||||||
luaL_checktype(L, 1, LUA_TFUNCTION);
|
luaL_checktype(L, 1, LUA_TFUNCTION);
|
||||||
|
|
||||||
#ifdef EMSCRIPTEN
|
#ifdef LOVR_HEADSET_HELPER_USES_REGISTRY
|
||||||
if (headsetRenderData.ref != LUA_NOREF) {
|
if (headsetRenderData.ref != LUA_NOREF) {
|
||||||
luaL_unref(L, LUA_REGISTRYINDEX, headsetRenderData.ref);
|
luaL_unref(L, LUA_REGISTRYINDEX, headsetRenderData.ref);
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <pwd.h>
|
#include <pwd.h>
|
||||||
#endif
|
#endif
|
||||||
#if LOVR_OVR_MOBILE
|
#if LOVR_USE_OCULUS_MOBILE
|
||||||
#include "BridgeLovr.h"
|
#include "BridgeLovr.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -98,7 +98,7 @@ int lovrFilesystemGetAppdataDirectory(char* dest, unsigned int size) {
|
||||||
#elif EMSCRIPTEN
|
#elif EMSCRIPTEN
|
||||||
strncpy(dest, "/home/web_user", size);
|
strncpy(dest, "/home/web_user", size);
|
||||||
return 0;
|
return 0;
|
||||||
#elif LOVR_OVR_MOBILE
|
#elif LOVR_USE_OCULUS_MOBILE
|
||||||
strncpy(dest, bridgeLovrWritablePath, size);
|
strncpy(dest, bridgeLovrWritablePath, size);
|
||||||
#elif __linux__
|
#elif __linux__
|
||||||
const char* home;
|
const char* home;
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
|
|
||||||
#ifdef LOVR_OVR_MOBILE
|
#ifdef LOVR_USE_OCULUS_MOBILE
|
||||||
#include <EGL/egl.h>
|
#include <EGL/egl.h>
|
||||||
#include <EGL/eglext.h>
|
#include <EGL/eglext.h>
|
||||||
#endif
|
#endif
|
||||||
|
@ -67,8 +67,9 @@ void lovrGraphicsPresent() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void lovrGraphicsCreateWindow(int w, int h, bool fullscreen, int msaa, const char* title, const char* icon) {
|
void lovrGraphicsCreateWindow(int w, int h, bool fullscreen, int msaa, const char* title, const char* icon) {
|
||||||
lovrAssert(!state.window, "Window is already created");
|
lovrAssert(!state.window && !state.initialized, "Window is already created");
|
||||||
|
|
||||||
|
#ifndef NO_WINDOW
|
||||||
if ((state.window = glfwGetCurrentContext()) == NULL) {
|
if ((state.window = glfwGetCurrentContext()) == NULL) {
|
||||||
glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3);
|
glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3);
|
||||||
glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 3);
|
glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 3);
|
||||||
|
@ -110,12 +111,21 @@ void lovrGraphicsCreateWindow(int w, int h, bool fullscreen, int msaa, const cha
|
||||||
glfwSetWindowCloseCallback(state.window, onCloseWindow);
|
glfwSetWindowCloseCallback(state.window, onCloseWindow);
|
||||||
glfwSetWindowSizeCallback(state.window, onResizeWindow);
|
glfwSetWindowSizeCallback(state.window, onResizeWindow);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef EMSCRIPTEN
|
#if !(defined(EMSCRIPTEN) || defined(LOVR_USE_OCULUS_MOBILE))
|
||||||
glfwSwapInterval(0);
|
glfwSwapInterval(0);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
glfwGetFramebufferSize(state.window, &state.width, &state.height);
|
glfwGetFramebufferSize(state.window, &state.width, &state.height);
|
||||||
lovrGpuInit(state.gammaCorrect, glfwGetProcAddress);
|
|
||||||
|
#if LOVR_USE_OCULUS_MOBILE
|
||||||
|
getGpuProcProc getProcAddress = eglGetProcAddress;
|
||||||
|
#else
|
||||||
|
getGpuProcProc getProcAddress = glfwGetProcAddress;
|
||||||
|
#endif
|
||||||
|
lovrGpuInit(state.gammaCorrect, getProcAddress);
|
||||||
|
|
||||||
VertexFormat format;
|
VertexFormat format;
|
||||||
vertexFormatInit(&format);
|
vertexFormatInit(&format);
|
||||||
vertexFormatAppend(&format, "lovrPosition", ATTR_FLOAT, 3);
|
vertexFormatAppend(&format, "lovrPosition", ATTR_FLOAT, 3);
|
||||||
|
|
|
@ -229,9 +229,11 @@ void lovrGraphicsFill(Texture* texture, float u, float v, float w, float h);
|
||||||
// GPU
|
// GPU
|
||||||
|
|
||||||
typedef void (*gpuProc)(void);
|
typedef void (*gpuProc)(void);
|
||||||
|
typedef gpuProc (*getGpuProcProc)(const char*);
|
||||||
|
|
||||||
void lovrGpuInit(bool srgb, gpuProc (*getProcAddress)(const char*));
|
void lovrGpuInit(bool srgb, getGpuProcProc getProcAddress);
|
||||||
void lovrGpuDestroy();
|
void lovrGpuDestroy();
|
||||||
|
void lovrGpuBindFramebuffer(uint32_t framebuffer);
|
||||||
void lovrGpuBindPipeline(Pipeline* pipeline);
|
void lovrGpuBindPipeline(Pipeline* pipeline);
|
||||||
void lovrGpuSetViewports(float* viewports, int count);
|
void lovrGpuSetViewports(float* viewports, int count);
|
||||||
void lovrGpuClear(Canvas* canvas, Color* color, float* depth, int* stencil);
|
void lovrGpuClear(Canvas* canvas, Color* color, float* depth, int* stencil);
|
||||||
|
|
|
@ -512,7 +512,7 @@ static void lovrGpuDestroySyncResource(void* resource, uint8_t incoherent) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static void lovrGpuBindFramebuffer(uint32_t framebuffer) {
|
void lovrGpuBindFramebuffer(uint32_t framebuffer) {
|
||||||
if (state.framebuffer != framebuffer) {
|
if (state.framebuffer != framebuffer) {
|
||||||
state.framebuffer = framebuffer;
|
state.framebuffer = framebuffer;
|
||||||
glBindFramebuffer(GL_FRAMEBUFFER, framebuffer);
|
glBindFramebuffer(GL_FRAMEBUFFER, framebuffer);
|
||||||
|
@ -605,7 +605,7 @@ static void lovrGpuUseProgram(uint32_t program) {
|
||||||
|
|
||||||
// GPU
|
// GPU
|
||||||
|
|
||||||
void lovrGpuInit(bool srgb, gpuProc (*getProcAddress)(const char*)) {
|
void lovrGpuInit(bool srgb, getGpuProcProc getProcAddress) {
|
||||||
#ifndef EMSCRIPTEN
|
#ifndef EMSCRIPTEN
|
||||||
gladLoadGLLoader((GLADloadproc) getProcAddress);
|
gladLoadGLLoader((GLADloadproc) getProcAddress);
|
||||||
state.features.computeShaders = GLAD_GL_ARB_compute_shader;
|
state.features.computeShaders = GLAD_GL_ARB_compute_shader;
|
||||||
|
@ -656,7 +656,7 @@ void lovrGpuInit(bool srgb, gpuProc (*getProcAddress)(const char*)) {
|
||||||
glFrontFace(GL_CCW);
|
glFrontFace(GL_CCW);
|
||||||
|
|
||||||
state.wireframe = false;
|
state.wireframe = false;
|
||||||
#ifndef EMSCRIPTEN
|
#if !(defined(EMSCRIPTEN) || defined(__ANDROID__))
|
||||||
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
|
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -1654,7 +1654,7 @@ Shader* lovrShaderCreateGraphics(const char* vertexSource, const char* fragmentS
|
||||||
Shader* shader = lovrAlloc(Shader, lovrShaderDestroy);
|
Shader* shader = lovrAlloc(Shader, lovrShaderDestroy);
|
||||||
if (!shader) return NULL;
|
if (!shader) return NULL;
|
||||||
|
|
||||||
#ifdef EMSCRIPTEN
|
#if defined(EMSCRIPTEN) || defined(__ANDROID__)
|
||||||
const char* vertexHeader = "#version 300 es\nprecision mediump float;\nprecision mediump int;\n";
|
const char* vertexHeader = "#version 300 es\nprecision mediump float;\nprecision mediump int;\n";
|
||||||
const char* fragmentHeader = vertexHeader;
|
const char* fragmentHeader = vertexHeader;
|
||||||
#else
|
#else
|
||||||
|
|
|
@ -18,6 +18,9 @@ void lovrHeadsetInit(HeadsetDriver* drivers, int count, float offset, int msaa)
|
||||||
#ifdef LOVR_USE_OCULUS
|
#ifdef LOVR_USE_OCULUS
|
||||||
case DRIVER_OCULUS: interface = &lovrHeadsetOculusDriver; break;
|
case DRIVER_OCULUS: interface = &lovrHeadsetOculusDriver; break;
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef LOVR_USE_OCULUS_MOBILE
|
||||||
|
case DRIVER_OCULUS_MOBILE: interface = &lovrHeadsetOculusMobileDriver; break;
|
||||||
|
#endif
|
||||||
#ifdef LOVR_USE_OPENVR
|
#ifdef LOVR_USE_OPENVR
|
||||||
case DRIVER_OPENVR: interface = &lovrHeadsetOpenVRDriver; break;
|
case DRIVER_OPENVR: interface = &lovrHeadsetOpenVRDriver; break;
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -19,10 +19,9 @@ typedef enum {
|
||||||
typedef enum {
|
typedef enum {
|
||||||
DRIVER_FAKE,
|
DRIVER_FAKE,
|
||||||
DRIVER_OCULUS,
|
DRIVER_OCULUS,
|
||||||
|
DRIVER_OCULUS_MOBILE,
|
||||||
DRIVER_OPENVR,
|
DRIVER_OPENVR,
|
||||||
DRIVER_WEBVR,
|
DRIVER_WEBVR
|
||||||
DRIVER_OVR,
|
|
||||||
DRIVER_OVR_MOBILE
|
|
||||||
} HeadsetDriver;
|
} HeadsetDriver;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
|
@ -103,6 +102,7 @@ extern HeadsetInterface lovrHeadsetOculusDriver;
|
||||||
extern HeadsetInterface lovrHeadsetOpenVRDriver;
|
extern HeadsetInterface lovrHeadsetOpenVRDriver;
|
||||||
extern HeadsetInterface lovrHeadsetWebVRDriver;
|
extern HeadsetInterface lovrHeadsetWebVRDriver;
|
||||||
extern HeadsetInterface lovrHeadsetFakeDriver;
|
extern HeadsetInterface lovrHeadsetFakeDriver;
|
||||||
|
extern HeadsetInterface lovrHeadsetOculusMobileDriver;
|
||||||
|
|
||||||
// Active driver
|
// Active driver
|
||||||
extern HeadsetInterface* lovrHeadsetDriver;
|
extern HeadsetInterface* lovrHeadsetDriver;
|
||||||
|
|
|
@ -3,165 +3,31 @@
|
||||||
#include "BridgeLovr.h"
|
#include "BridgeLovr.h"
|
||||||
#include "math/quat.h"
|
#include "math/quat.h"
|
||||||
#include "graphics/graphics.h"
|
#include "graphics/graphics.h"
|
||||||
|
#include "math/mat4.h"
|
||||||
|
|
||||||
void lovrHeadsetInit(HeadsetDriver* drivers, int count) {
|
static void (*renderCallback)(void*);
|
||||||
}
|
|
||||||
|
|
||||||
void lovrHeadsetDestroy() {
|
|
||||||
}
|
|
||||||
|
|
||||||
static HeadsetDriver driver = DRIVER_OVR_MOBILE;
|
|
||||||
|
|
||||||
const HeadsetDriver* lovrHeadsetGetDriver() {
|
|
||||||
return &driver;
|
|
||||||
}
|
|
||||||
|
|
||||||
void lovrHeadsetPoll() {
|
|
||||||
}
|
|
||||||
|
|
||||||
bool lovrHeadsetIsPresent() {
|
|
||||||
return true; // Can't not ?!?
|
|
||||||
}
|
|
||||||
|
|
||||||
HeadsetType lovrHeadsetGetType() {
|
|
||||||
return HEADSET_RIFT;
|
|
||||||
}
|
|
||||||
|
|
||||||
HeadsetOrigin lovrHeadsetGetOriginType() {
|
|
||||||
return ORIGIN_FLOOR;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool lovrHeadsetIsMirrored() {
|
|
||||||
return false; // Can't ever??
|
|
||||||
}
|
|
||||||
|
|
||||||
void lovrHeadsetSetMirrored(bool mirrored) {
|
|
||||||
// Don't care?
|
|
||||||
}
|
|
||||||
|
|
||||||
void lovrHeadsetGetDisplayDimensions(int* width, int* height) {
|
|
||||||
*width = bridgeLovrMobileData.displayDimensions.width;
|
|
||||||
*height = bridgeLovrMobileData.displayDimensions.height;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
void lovrHeadsetGetClipDistance(float* near, float* far) {
|
|
||||||
*near = *far = 0.f;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
/// TODO
|
|
||||||
void lovrHeadsetSetClipDistance(float near, float far) {
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
float lovrHeadsetGetBoundsWidth() {
|
|
||||||
return 0.f;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
float lovrHeadsetGetBoundsDepth() {
|
|
||||||
return 0.f;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
void lovrHeadsetGetPose(float* x, float* y, float* z, float* angle, float* ax, float* ay, float* az) {
|
|
||||||
*x = bridgeLovrMobileData.lastHeadPose.x;
|
|
||||||
*y = bridgeLovrMobileData.lastHeadPose.y;
|
|
||||||
*z = bridgeLovrMobileData.lastHeadPose.z;
|
|
||||||
|
|
||||||
quat_getAngleAxis(bridgeLovrMobileData.lastHeadPose.q, angle, ax, ay, az);
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
void lovrHeadsetGetEyePose(HeadsetEye eye, float* x, float* y, float* z, float* angle, float* ax, float* ay, float* az) {
|
|
||||||
// This is very wrong!
|
|
||||||
lovrHeadsetGetPose(x, y, z, angle, ax, ay, az);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
void lovrHeadsetGetVelocity(float* x, float* y, float* z) {
|
|
||||||
*x = bridgeLovrMobileData.lastHeadVelocity.x;
|
|
||||||
*y = bridgeLovrMobileData.lastHeadVelocity.y;
|
|
||||||
*z = bridgeLovrMobileData.lastHeadVelocity.z;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
void lovrHeadsetGetAngularVelocity(float* x, float* y, float* z) {
|
|
||||||
*x = bridgeLovrMobileData.lastHeadVelocity.ax;
|
|
||||||
*y = bridgeLovrMobileData.lastHeadVelocity.ay;
|
|
||||||
*z = bridgeLovrMobileData.lastHeadVelocity.az;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
vec_controller_t* lovrHeadsetGetControllers() {
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
bool lovrHeadsetControllerIsPresent(Controller* controller) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
ControllerHand lovrHeadsetControllerGetHand(Controller* controller) {
|
|
||||||
return HAND_UNKNOWN;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
void lovrHeadsetControllerGetPose(Controller* controller, float* x, float* y, float* z, float* angle, float* ax, float* ay, float* az) {
|
|
||||||
*x = *y = *z = *angle = *ax = *ay = *az = 0.f;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
float lovrHeadsetControllerGetAxis(Controller* controller, ControllerAxis axis) {
|
|
||||||
return 0.f;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
bool lovrHeadsetControllerIsDown(Controller* controller, ControllerButton button) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
bool lovrHeadsetControllerIsTouched(Controller* controller, ControllerButton button) {
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
void lovrHeadsetControllerVibrate(Controller* controller, float duration, float power) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
ModelData* lovrHeadsetControllerNewModelData(Controller* controller) {
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
// TODO
|
|
||||||
static headsetRenderCallback renderCallback;
|
|
||||||
static void* renderUserdata;
|
static void* renderUserdata;
|
||||||
void lovrHeadsetRenderTo(headsetRenderCallback callback, void* userdata) {
|
|
||||||
renderCallback = callback;
|
|
||||||
renderUserdata = userdata;
|
|
||||||
}
|
|
||||||
|
|
||||||
void lovrOculusMobileDraw(int eye, int framebuffer, int width, int height, float *eyeViewMatrix, float *projectionMatrix) {
|
void lovrOculusMobileDraw(int eye, int framebuffer, int width, int height, float *eyeViewMatrix, float *projectionMatrix) {
|
||||||
lovrGraphicsPush();
|
lovrGraphicsPush();
|
||||||
lovrGraphicsBindFramebuffer(framebuffer);
|
lovrGpuBindFramebuffer(framebuffer);
|
||||||
lovrGraphicsMatrixTransform(MATRIX_VIEW, eyeViewMatrix);
|
|
||||||
lovrGraphicsSetProjection(projectionMatrix);
|
|
||||||
lovrGraphicsClear(true, true, true, lovrGraphicsGetBackgroundColor(), 1., 0); // Needed?
|
|
||||||
|
|
||||||
lovrGraphicsSetViewport(0, 0, width, height);
|
float m[16];
|
||||||
glScissor(0, 0, width, height);
|
mat4_set(m, projectionMatrix);
|
||||||
|
mat4_multiply(m, eyeViewMatrix);
|
||||||
renderCallback(eye, renderUserdata);
|
|
||||||
|
lovrGraphicsOrigin();
|
||||||
|
lovrGraphicsMatrixTransform(m);
|
||||||
|
|
||||||
|
Color color = lovrGraphicsGetBackgroundColor();
|
||||||
|
float depth = 1.f;
|
||||||
|
int stencil = 0;
|
||||||
|
lovrGraphicsClear(&color, &depth, &stencil); // Needed?
|
||||||
|
|
||||||
|
float viewports[4] = { 0, 0, width, height };
|
||||||
|
lovrGpuSetViewports(viewports, 1);
|
||||||
|
|
||||||
|
renderCallback(renderUserdata);
|
||||||
|
|
||||||
lovrGraphicsPop();
|
lovrGraphicsPop();
|
||||||
}
|
}
|
||||||
|
@ -170,6 +36,158 @@ void lovrOculusMobileDraw(int eye, int framebuffer, int width, int height, float
|
||||||
void lovrHeadsetUpdate(float dt) {
|
void lovrHeadsetUpdate(float dt) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Headset driver object
|
||||||
|
|
||||||
|
static bool oculusMobileInit(float offset, int msaa) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileDestroy() {
|
||||||
|
}
|
||||||
|
|
||||||
|
static HeadsetType oculusMobileGetType() {
|
||||||
|
return HEADSET_OCULUS_MOBILE;
|
||||||
|
}
|
||||||
|
|
||||||
|
static HeadsetOrigin oculusMobileGetOriginType() {
|
||||||
|
return ORIGIN_FLOOR;
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool oculusMobileIsMounted() {
|
||||||
|
return true; // ???
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileIsMirrored(bool* mirrored, bool* eye) {
|
||||||
|
*mirrored = false; // Can't ever??
|
||||||
|
*eye = false;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileSetMirrored(bool mirror, HeadsetEye eye) {
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileGetDisplayDimensions(uint32_t* width, uint32_t* height) {
|
||||||
|
*width = bridgeLovrMobileData.displayDimensions.width;
|
||||||
|
*height = bridgeLovrMobileData.displayDimensions.height;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileGetClipDistance(float* clipNear, float* clipFar) {
|
||||||
|
// TODO
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileSetClipDistance(float clipNear, float clipFar) {
|
||||||
|
// TODO
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileGetBoundsDimensions(float* width, float* depth) {
|
||||||
|
*width = 0;
|
||||||
|
*depth = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
static const float* oculusMobileGetBoundsGeometry(int* count) {
|
||||||
|
*count = 0;
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileGetPose(float* x, float* y, float* z, float* angle, float* ax, float* ay, float* az) {
|
||||||
|
*x = bridgeLovrMobileData.lastHeadPose.x;
|
||||||
|
*y = bridgeLovrMobileData.lastHeadPose.y;
|
||||||
|
*z = bridgeLovrMobileData.lastHeadPose.z;
|
||||||
|
|
||||||
|
quat_getAngleAxis(bridgeLovrMobileData.lastHeadPose.q, angle, ax, ay, az);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileGetEyePose(HeadsetEye eye, float* x, float* y, float* z, float* angle, float* ax, float* ay, float* az) {
|
||||||
|
// TODO: This is very wrong!
|
||||||
|
oculusMobileGetPose(x, y, z, angle, ax, ay, az);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileGetVelocity(float* x, float* y, float* z) {
|
||||||
|
*x = bridgeLovrMobileData.lastHeadVelocity.x;
|
||||||
|
*y = bridgeLovrMobileData.lastHeadVelocity.y;
|
||||||
|
*z = bridgeLovrMobileData.lastHeadVelocity.z;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileGetAngularVelocity(float* x, float* y, float* z) {
|
||||||
|
*x = bridgeLovrMobileData.lastHeadVelocity.ax;
|
||||||
|
*y = bridgeLovrMobileData.lastHeadVelocity.ay;
|
||||||
|
*z = bridgeLovrMobileData.lastHeadVelocity.az;
|
||||||
|
}
|
||||||
|
|
||||||
|
static Controller** oculusMobileGetControllers(uint8_t* count) {
|
||||||
|
*count = 0; // TODO
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool oculusMobileControllerIsConnected(Controller* controller) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
static ControllerHand oculusMobileControllerGetHand(Controller* controller) {
|
||||||
|
return HAND_UNKNOWN;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileControllerGetPose(Controller* controller, float* x, float* y, float* z, float* angle, float* ax, float* ay, float* az) {
|
||||||
|
}
|
||||||
|
|
||||||
|
static float oculusMobileControllerGetAxis(Controller* controller, ControllerAxis axis) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
static int oculusMobileControllerIsDown(Controller* controller, ControllerButton button) {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
static bool oculusMobileControllerIsTouched(Controller* controller, ControllerButton button) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileControllerVibrate(Controller* controller, float duration, float power) {
|
||||||
|
}
|
||||||
|
|
||||||
|
static ModelData* oculusMobileControllerNewModelData(Controller* controller) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO: need to set up swap chain textures for the eyes and finish view transforms
|
||||||
|
static void oculusMobileRenderTo(void (*callback)(void*), void* userdata) {
|
||||||
|
renderCallback = callback;
|
||||||
|
renderUserdata = userdata;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void oculusMobileUpdate(float dt) {
|
||||||
|
}
|
||||||
|
|
||||||
|
HeadsetInterface lovrHeadsetOculusMobileDriver = {
|
||||||
|
DRIVER_OCULUS_MOBILE,
|
||||||
|
oculusMobileInit,
|
||||||
|
oculusMobileDestroy,
|
||||||
|
oculusMobileGetType,
|
||||||
|
oculusMobileGetOriginType,
|
||||||
|
oculusMobileIsMounted,
|
||||||
|
oculusMobileIsMirrored,
|
||||||
|
oculusMobileSetMirrored,
|
||||||
|
oculusMobileGetDisplayDimensions,
|
||||||
|
oculusMobileGetClipDistance,
|
||||||
|
oculusMobileSetClipDistance,
|
||||||
|
oculusMobileGetBoundsDimensions,
|
||||||
|
oculusMobileGetBoundsGeometry,
|
||||||
|
oculusMobileGetPose,
|
||||||
|
oculusMobileGetEyePose,
|
||||||
|
oculusMobileGetVelocity,
|
||||||
|
oculusMobileGetAngularVelocity,
|
||||||
|
oculusMobileGetControllers,
|
||||||
|
oculusMobileControllerIsConnected,
|
||||||
|
oculusMobileControllerGetHand,
|
||||||
|
oculusMobileControllerGetPose,
|
||||||
|
oculusMobileControllerGetAxis,
|
||||||
|
oculusMobileControllerIsDown,
|
||||||
|
oculusMobileControllerIsTouched,
|
||||||
|
oculusMobileControllerVibrate,
|
||||||
|
oculusMobileControllerNewModelData,
|
||||||
|
oculusMobileRenderTo,
|
||||||
|
oculusMobileUpdate
|
||||||
|
};
|
||||||
|
|
||||||
// Pseudo GLFW
|
// Pseudo GLFW
|
||||||
|
|
||||||
void glfwPollEvents() {
|
void glfwPollEvents() {
|
||||||
|
@ -206,3 +224,9 @@ int glfwInit(void) {
|
||||||
void glfwTerminate(void) {
|
void glfwTerminate(void) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
GLFWAPI void glfwGetFramebufferSize(GLFWwindow* window, int* width, int* height)
|
||||||
|
{
|
||||||
|
*width = bridgeLovrMobileData.displayDimensions.width;
|
||||||
|
*height = bridgeLovrMobileData.displayDimensions.height;
|
||||||
|
}
|
|
@ -4,14 +4,16 @@
|
||||||
#define APIENTRY __stdcall
|
#define APIENTRY __stdcall
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifndef LOVR_OVR_MOBILE
|
#ifndef LOVR_USE_OCULUS_MOBILE
|
||||||
|
|
||||||
#define GLFW_INCLUDE_NONE
|
#define GLFW_INCLUDE_NONE
|
||||||
#include <GLFW/glfw3.h>
|
#include <GLFW/glfw3.h>
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
// Pseudo GLFW for oculus android
|
// These are stubs of necessary GLFW functions for platforms lacking GLFW, such as Oculus Mobile.
|
||||||
|
// All of Lovr will build with just these functions as long as you build with NO_WINDOW and omit fake.c.
|
||||||
|
|
||||||
// TODO: Move to own header
|
// TODO: Move to own header
|
||||||
typedef void GLFWwindow;
|
typedef void GLFWwindow;
|
||||||
#define GLFWAPI
|
#define GLFWAPI
|
||||||
|
@ -21,6 +23,8 @@ GLFWAPI GLFWwindow* glfwGetCurrentContext(void);
|
||||||
GLFWAPI void glfwSetTime(double time);
|
GLFWAPI void glfwSetTime(double time);
|
||||||
typedef void (* GLFWerrorfun)(int,const char*);
|
typedef void (* GLFWerrorfun)(int,const char*);
|
||||||
GLFWAPI GLFWerrorfun glfwSetErrorCallback(GLFWerrorfun cbfun);
|
GLFWAPI GLFWerrorfun glfwSetErrorCallback(GLFWerrorfun cbfun);
|
||||||
|
GLFWAPI void glfwGetFramebufferSize(GLFWwindow* window, int* width, int* height);
|
||||||
|
|
||||||
|
|
||||||
// Constants
|
// Constants
|
||||||
|
|
||||||
|
|
|
@ -14,6 +14,8 @@
|
||||||
bool lovrRun(int argc, char** argv, int* status);
|
bool lovrRun(int argc, char** argv, int* status);
|
||||||
void lovrQuit(int status);
|
void lovrQuit(int status);
|
||||||
|
|
||||||
|
#ifndef LOVR_USE_OCULUS_MOBILE
|
||||||
|
|
||||||
int main(int argc, char** argv) {
|
int main(int argc, char** argv) {
|
||||||
if (argc > 1 && (!strcmp(argv[1], "--version") || !strcmp(argv[1], "-v"))) {
|
if (argc > 1 && (!strcmp(argv[1], "--version") || !strcmp(argv[1], "-v"))) {
|
||||||
printf("LOVR %d.%d.%d (%s)\n", LOVR_VERSION_MAJOR, LOVR_VERSION_MINOR, LOVR_VERSION_PATCH, LOVR_VERSION_ALIAS);
|
printf("LOVR %d.%d.%d (%s)\n", LOVR_VERSION_MAJOR, LOVR_VERSION_MINOR, LOVR_VERSION_PATCH, LOVR_VERSION_ALIAS);
|
||||||
|
@ -28,6 +30,8 @@ int main(int argc, char** argv) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef EMSCRIPTEN
|
#ifdef EMSCRIPTEN
|
||||||
#include <emscripten.h>
|
#include <emscripten.h>
|
||||||
typedef struct {
|
typedef struct {
|
||||||
|
|
|
@ -61,7 +61,7 @@ function lovr.boot()
|
||||||
},
|
},
|
||||||
gammacorrect = false,
|
gammacorrect = false,
|
||||||
headset = {
|
headset = {
|
||||||
drivers = { 'oculus', 'openvr', 'webvr', 'fake' },
|
drivers = { 'oculus', 'oculusmobile', 'openvr', 'webvr', 'fake' },
|
||||||
mirror = true,
|
mirror = true,
|
||||||
offset = 1.7,
|
offset = 1.7,
|
||||||
msaa = 4
|
msaa = 4
|
||||||
|
|
|
@ -162,310 +162,311 @@ unsigned char boot_lua[] = {
|
||||||
0x74, 0x20, 0x3d, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
0x74, 0x20, 0x3d, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x73, 0x20, 0x3d, 0x20, 0x7b, 0x20,
|
0x64, 0x72, 0x69, 0x76, 0x65, 0x72, 0x73, 0x20, 0x3d, 0x20, 0x7b, 0x20,
|
||||||
0x27, 0x6f, 0x63, 0x75, 0x6c, 0x75, 0x73, 0x27, 0x2c, 0x20, 0x27, 0x6f,
|
0x27, 0x6f, 0x63, 0x75, 0x6c, 0x75, 0x73, 0x27, 0x2c, 0x20, 0x27, 0x6f,
|
||||||
0x70, 0x65, 0x6e, 0x76, 0x72, 0x27, 0x2c, 0x20, 0x27, 0x77, 0x65, 0x62,
|
0x63, 0x75, 0x6c, 0x75, 0x73, 0x6d, 0x6f, 0x62, 0x69, 0x6c, 0x65, 0x27,
|
||||||
0x76, 0x72, 0x27, 0x2c, 0x20, 0x27, 0x66, 0x61, 0x6b, 0x65, 0x27, 0x20,
|
0x2c, 0x20, 0x27, 0x6f, 0x70, 0x65, 0x6e, 0x76, 0x72, 0x27, 0x2c, 0x20,
|
||||||
0x7d, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6d, 0x69, 0x72,
|
0x27, 0x77, 0x65, 0x62, 0x76, 0x72, 0x27, 0x2c, 0x20, 0x27, 0x66, 0x61,
|
||||||
0x72, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x74, 0x72, 0x75, 0x65, 0x2c, 0x0a,
|
0x6b, 0x65, 0x27, 0x20, 0x7d, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6f, 0x66, 0x66, 0x73, 0x65, 0x74,
|
0x20, 0x6d, 0x69, 0x72, 0x72, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x74, 0x72,
|
||||||
0x20, 0x3d, 0x20, 0x31, 0x2e, 0x37, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
0x75, 0x65, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6f, 0x66,
|
||||||
0x20, 0x20, 0x6d, 0x73, 0x61, 0x61, 0x20, 0x3d, 0x20, 0x34, 0x0a, 0x20,
|
0x66, 0x73, 0x65, 0x74, 0x20, 0x3d, 0x20, 0x31, 0x2e, 0x37, 0x2c, 0x0a,
|
||||||
0x20, 0x20, 0x20, 0x7d, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x77, 0x69,
|
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6d, 0x73, 0x61, 0x61, 0x20, 0x3d,
|
||||||
0x6e, 0x64, 0x6f, 0x77, 0x20, 0x3d, 0x20, 0x7b, 0x0a, 0x20, 0x20, 0x20,
|
0x20, 0x34, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x2c, 0x0a, 0x20, 0x20,
|
||||||
0x20, 0x20, 0x20, 0x77, 0x69, 0x64, 0x74, 0x68, 0x20, 0x3d, 0x20, 0x31,
|
0x20, 0x20, 0x77, 0x69, 0x6e, 0x64, 0x6f, 0x77, 0x20, 0x3d, 0x20, 0x7b,
|
||||||
0x30, 0x38, 0x30, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x68,
|
0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x77, 0x69, 0x64, 0x74, 0x68,
|
||||||
0x65, 0x69, 0x67, 0x68, 0x74, 0x20, 0x3d, 0x20, 0x36, 0x30, 0x30, 0x2c,
|
0x20, 0x3d, 0x20, 0x31, 0x30, 0x38, 0x30, 0x2c, 0x0a, 0x20, 0x20, 0x20,
|
||||||
0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x66, 0x75, 0x6c, 0x6c, 0x73,
|
0x20, 0x20, 0x20, 0x68, 0x65, 0x69, 0x67, 0x68, 0x74, 0x20, 0x3d, 0x20,
|
||||||
0x63, 0x72, 0x65, 0x65, 0x6e, 0x20, 0x3d, 0x20, 0x66, 0x61, 0x6c, 0x73,
|
0x36, 0x30, 0x30, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x66,
|
||||||
0x65, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6d, 0x73, 0x61,
|
0x75, 0x6c, 0x6c, 0x73, 0x63, 0x72, 0x65, 0x65, 0x6e, 0x20, 0x3d, 0x20,
|
||||||
0x61, 0x20, 0x3d, 0x20, 0x30, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
|
0x66, 0x61, 0x6c, 0x73, 0x65, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x20, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x20, 0x3d, 0x20, 0x27, 0x4c, 0xc3,
|
0x20, 0x6d, 0x73, 0x61, 0x61, 0x20, 0x3d, 0x20, 0x30, 0x2c, 0x0a, 0x20,
|
||||||
0x96, 0x56, 0x52, 0x27, 0x2c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
0x20, 0x20, 0x20, 0x20, 0x20, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x20, 0x3d,
|
||||||
0x69, 0x63, 0x6f, 0x6e, 0x20, 0x3d, 0x20, 0x6e, 0x69, 0x6c, 0x0a, 0x20,
|
0x20, 0x27, 0x4c, 0xc3, 0x96, 0x56, 0x52, 0x27, 0x2c, 0x0a, 0x20, 0x20,
|
||||||
0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x7d, 0x0a, 0x0a, 0x20, 0x20,
|
0x20, 0x20, 0x20, 0x20, 0x69, 0x63, 0x6f, 0x6e, 0x20, 0x3d, 0x20, 0x6e,
|
||||||
|
0x69, 0x6c, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x7d, 0x0a, 0x20, 0x20, 0x7d,
|
||||||
|
0x0a, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c,
|
||||||
|
0x65, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x20, 0x3d, 0x20, 0x72, 0x65,
|
||||||
|
0x71, 0x75, 0x69, 0x72, 0x65, 0x28, 0x27, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
||||||
|
0x66, 0x69, 0x6c, 0x65, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x27, 0x29,
|
||||||
|
0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x68, 0x61, 0x73,
|
||||||
|
0x43, 0x6f, 0x6e, 0x66, 0x2c, 0x20, 0x68, 0x61, 0x73, 0x4d, 0x61, 0x69,
|
||||||
|
0x6e, 0x20, 0x3d, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c,
|
||||||
|
0x65, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x2e, 0x69, 0x73, 0x46, 0x69,
|
||||||
|
0x6c, 0x65, 0x28, 0x27, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x6c, 0x75, 0x61,
|
||||||
|
0x27, 0x29, 0x2c, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c,
|
||||||
|
0x65, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x2e, 0x69, 0x73, 0x46, 0x69,
|
||||||
|
0x6c, 0x65, 0x28, 0x27, 0x6d, 0x61, 0x69, 0x6e, 0x2e, 0x6c, 0x75, 0x61,
|
||||||
|
0x27, 0x29, 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6e, 0x6f, 0x74, 0x20,
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x79, 0x73,
|
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x79, 0x73,
|
||||||
0x74, 0x65, 0x6d, 0x20, 0x3d, 0x20, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72,
|
0x74, 0x65, 0x6d, 0x2e, 0x67, 0x65, 0x74, 0x53, 0x6f, 0x75, 0x72, 0x63,
|
||||||
0x65, 0x28, 0x27, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c, 0x65,
|
0x65, 0x28, 0x29, 0x20, 0x6f, 0x72, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x28,
|
||||||
0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x27, 0x29, 0x0a, 0x20, 0x20, 0x6c,
|
0x68, 0x61, 0x73, 0x43, 0x6f, 0x6e, 0x66, 0x20, 0x6f, 0x72, 0x20, 0x68,
|
||||||
0x6f, 0x63, 0x61, 0x6c, 0x20, 0x68, 0x61, 0x73, 0x43, 0x6f, 0x6e, 0x66,
|
0x61, 0x73, 0x4d, 0x61, 0x69, 0x6e, 0x29, 0x20, 0x74, 0x68, 0x65, 0x6e,
|
||||||
0x2c, 0x20, 0x68, 0x61, 0x73, 0x4d, 0x61, 0x69, 0x6e, 0x20, 0x3d, 0x20,
|
0x20, 0x6e, 0x6f, 0x67, 0x61, 0x6d, 0x65, 0x28, 0x29, 0x20, 0x65, 0x6e,
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x79, 0x73,
|
0x64, 0x0a, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x6f,
|
||||||
0x74, 0x65, 0x6d, 0x2e, 0x69, 0x73, 0x46, 0x69, 0x6c, 0x65, 0x28, 0x27,
|
0x6b, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x45, 0x72, 0x72, 0x6f, 0x72,
|
||||||
0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x6c, 0x75, 0x61, 0x27, 0x29, 0x2c, 0x20,
|
0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x68, 0x61, 0x73, 0x43, 0x6f, 0x6e,
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x79, 0x73,
|
0x66, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6f, 0x6b, 0x2c, 0x20, 0x63,
|
||||||
0x74, 0x65, 0x6d, 0x2e, 0x69, 0x73, 0x46, 0x69, 0x6c, 0x65, 0x28, 0x27,
|
0x6f, 0x6e, 0x66, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x70,
|
||||||
0x6d, 0x61, 0x69, 0x6e, 0x2e, 0x6c, 0x75, 0x61, 0x27, 0x29, 0x0a, 0x20,
|
0x63, 0x61, 0x6c, 0x6c, 0x28, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65,
|
||||||
0x20, 0x69, 0x66, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
0x2c, 0x20, 0x27, 0x63, 0x6f, 0x6e, 0x66, 0x27, 0x29, 0x20, 0x65, 0x6e,
|
||||||
0x2e, 0x66, 0x69, 0x6c, 0x65, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x2e,
|
0x64, 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
||||||
0x67, 0x65, 0x74, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x28, 0x29, 0x20,
|
0x63, 0x6f, 0x6e, 0x66, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6f, 0x6b,
|
||||||
0x6f, 0x72, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x28, 0x68, 0x61, 0x73, 0x43,
|
0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20,
|
||||||
0x6f, 0x6e, 0x66, 0x20, 0x6f, 0x72, 0x20, 0x68, 0x61, 0x73, 0x4d, 0x61,
|
0x3d, 0x20, 0x70, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
0x69, 0x6e, 0x29, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6e, 0x6f, 0x67,
|
0x2e, 0x63, 0x6f, 0x6e, 0x66, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x29,
|
||||||
0x61, 0x6d, 0x65, 0x28, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x0a, 0x20,
|
0x20, 0x65, 0x6e, 0x64, 0x0a, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x6f, 0x6b, 0x2c, 0x20, 0x63,
|
0x2e, 0x5f, 0x73, 0x65, 0x74, 0x43, 0x6f, 0x6e, 0x66, 0x28, 0x63, 0x6f,
|
||||||
0x6f, 0x6e, 0x66, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x0a, 0x20, 0x20, 0x69,
|
0x6e, 0x66, 0x29, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66,
|
||||||
0x66, 0x20, 0x68, 0x61, 0x73, 0x43, 0x6f, 0x6e, 0x66, 0x20, 0x74, 0x68,
|
0x69, 0x6c, 0x65, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x2e, 0x73, 0x65,
|
||||||
0x65, 0x6e, 0x20, 0x6f, 0x6b, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x45,
|
0x74, 0x49, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x28, 0x63, 0x6f,
|
||||||
0x72, 0x72, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x70, 0x63, 0x61, 0x6c, 0x6c,
|
0x6e, 0x66, 0x2e, 0x69, 0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x29,
|
||||||
0x28, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x2c, 0x20, 0x27, 0x63,
|
0x0a, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x6d, 0x6f,
|
||||||
0x6f, 0x6e, 0x66, 0x27, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20,
|
0x64, 0x75, 0x6c, 0x65, 0x73, 0x20, 0x3d, 0x20, 0x7b, 0x20, 0x27, 0x61,
|
||||||
0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x63, 0x6f, 0x6e, 0x66,
|
0x75, 0x64, 0x69, 0x6f, 0x27, 0x2c, 0x20, 0x27, 0x64, 0x61, 0x74, 0x61,
|
||||||
0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6f, 0x6b, 0x2c, 0x20, 0x63, 0x6f,
|
0x27, 0x2c, 0x20, 0x27, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x27, 0x2c, 0x20,
|
||||||
0x6e, 0x66, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20, 0x3d, 0x20, 0x70, 0x63,
|
0x27, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x27, 0x2c, 0x20,
|
||||||
0x61, 0x6c, 0x6c, 0x28, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x63, 0x6f, 0x6e,
|
0x27, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x27, 0x2c, 0x20, 0x27,
|
||||||
0x66, 0x2c, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x29, 0x20, 0x65, 0x6e, 0x64,
|
0x6d, 0x61, 0x74, 0x68, 0x27, 0x2c, 0x20, 0x27, 0x70, 0x68, 0x79, 0x73,
|
||||||
0x0a, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x5f, 0x73, 0x65,
|
0x69, 0x63, 0x73, 0x27, 0x2c, 0x20, 0x27, 0x74, 0x68, 0x72, 0x65, 0x61,
|
||||||
0x74, 0x43, 0x6f, 0x6e, 0x66, 0x28, 0x63, 0x6f, 0x6e, 0x66, 0x29, 0x0a,
|
0x64, 0x27, 0x2c, 0x20, 0x27, 0x74, 0x69, 0x6d, 0x65, 0x72, 0x27, 0x20,
|
||||||
0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x66, 0x69, 0x6c, 0x65, 0x73,
|
0x7d, 0x0a, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x5f, 0x2c, 0x20, 0x6d,
|
||||||
0x79, 0x73, 0x74, 0x65, 0x6d, 0x2e, 0x73, 0x65, 0x74, 0x49, 0x64, 0x65,
|
0x6f, 0x64, 0x75, 0x6c, 0x65, 0x20, 0x69, 0x6e, 0x20, 0x69, 0x70, 0x61,
|
||||||
0x6e, 0x74, 0x69, 0x74, 0x79, 0x28, 0x63, 0x6f, 0x6e, 0x66, 0x2e, 0x69,
|
0x69, 0x72, 0x73, 0x28, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x73, 0x29,
|
||||||
0x64, 0x65, 0x6e, 0x74, 0x69, 0x74, 0x79, 0x29, 0x0a, 0x0a, 0x20, 0x20,
|
0x20, 0x64, 0x6f, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x63,
|
||||||
0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65,
|
0x6f, 0x6e, 0x66, 0x2e, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x73, 0x5b,
|
||||||
0x73, 0x20, 0x3d, 0x20, 0x7b, 0x20, 0x27, 0x61, 0x75, 0x64, 0x69, 0x6f,
|
0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5d, 0x20, 0x74, 0x68, 0x65, 0x6e,
|
||||||
0x27, 0x2c, 0x20, 0x27, 0x64, 0x61, 0x74, 0x61, 0x27, 0x2c, 0x20, 0x27,
|
0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c,
|
||||||
0x65, 0x76, 0x65, 0x6e, 0x74, 0x27, 0x2c, 0x20, 0x27, 0x67, 0x72, 0x61,
|
0x20, 0x6f, 0x6b, 0x2c, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20,
|
||||||
0x70, 0x68, 0x69, 0x63, 0x73, 0x27, 0x2c, 0x20, 0x27, 0x68, 0x65, 0x61,
|
0x3d, 0x20, 0x70, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x72, 0x65, 0x71, 0x75,
|
||||||
0x64, 0x73, 0x65, 0x74, 0x27, 0x2c, 0x20, 0x27, 0x6d, 0x61, 0x74, 0x68,
|
0x69, 0x72, 0x65, 0x2c, 0x20, 0x27, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x27,
|
||||||
0x27, 0x2c, 0x20, 0x27, 0x70, 0x68, 0x79, 0x73, 0x69, 0x63, 0x73, 0x27,
|
0x20, 0x2e, 0x2e, 0x20, 0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x29, 0x0a,
|
||||||
0x2c, 0x20, 0x27, 0x74, 0x68, 0x72, 0x65, 0x61, 0x64, 0x27, 0x2c, 0x20,
|
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x5b, 0x6d,
|
||||||
0x27, 0x74, 0x69, 0x6d, 0x65, 0x72, 0x27, 0x20, 0x7d, 0x0a, 0x20, 0x20,
|
0x6f, 0x64, 0x75, 0x6c, 0x65, 0x5d, 0x20, 0x3d, 0x20, 0x6f, 0x6b, 0x20,
|
||||||
0x66, 0x6f, 0x72, 0x20, 0x5f, 0x2c, 0x20, 0x6d, 0x6f, 0x64, 0x75, 0x6c,
|
0x61, 0x6e, 0x64, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x0a, 0x20,
|
||||||
0x65, 0x20, 0x69, 0x6e, 0x20, 0x69, 0x70, 0x61, 0x69, 0x72, 0x73, 0x28,
|
0x20, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x65, 0x6e, 0x64,
|
||||||
0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x73, 0x29, 0x20, 0x64, 0x6f, 0x0a,
|
0x0a, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x61, 0x6e,
|
||||||
0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x2e,
|
0x64, 0x6c, 0x65, 0x72, 0x73, 0x20, 0x3d, 0x20, 0x73, 0x65, 0x74, 0x6d,
|
||||||
0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x73, 0x5b, 0x6d, 0x6f, 0x64, 0x75,
|
0x65, 0x74, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x28, 0x7b, 0x7d, 0x2c,
|
||||||
0x6c, 0x65, 0x5d, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x0a, 0x20, 0x20, 0x20,
|
0x20, 0x7b, 0x20, 0x5f, 0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3d,
|
||||||
0x20, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x6f, 0x6b, 0x2c,
|
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x20, 0x7d, 0x29, 0x0a, 0x20, 0x20, 0x69,
|
||||||
0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x70, 0x63,
|
0x66, 0x20, 0x63, 0x6f, 0x6e, 0x66, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20,
|
||||||
0x61, 0x6c, 0x6c, 0x28, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x2c,
|
0x74, 0x68, 0x65, 0x6e, 0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x28, 0x63,
|
||||||
0x20, 0x27, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x27, 0x20, 0x2e, 0x2e, 0x20,
|
0x6f, 0x6e, 0x66, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x29, 0x20, 0x65, 0x6e,
|
||||||
0x6d, 0x6f, 0x64, 0x75, 0x6c, 0x65, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
0x64, 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x68, 0x61, 0x73, 0x4d, 0x61,
|
||||||
0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x5b, 0x6d, 0x6f, 0x64, 0x75, 0x6c,
|
0x69, 0x6e, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x72, 0x65, 0x71, 0x75,
|
||||||
0x65, 0x5d, 0x20, 0x3d, 0x20, 0x6f, 0x6b, 0x20, 0x61, 0x6e, 0x64, 0x20,
|
0x69, 0x72, 0x65, 0x20, 0x27, 0x6d, 0x61, 0x69, 0x6e, 0x27, 0x20, 0x65,
|
||||||
0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65,
|
0x6e, 0x64, 0x0a, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20,
|
||||||
0x6e, 0x64, 0x0a, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x0a, 0x20, 0x20,
|
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x72, 0x75, 0x6e, 0x28, 0x29, 0x0a, 0x65,
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72,
|
0x6e, 0x64, 0x0a, 0x0a, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
|
||||||
0x73, 0x20, 0x3d, 0x20, 0x73, 0x65, 0x74, 0x6d, 0x65, 0x74, 0x61, 0x74,
|
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x72, 0x75, 0x6e, 0x28, 0x29, 0x0a,
|
||||||
0x61, 0x62, 0x6c, 0x65, 0x28, 0x7b, 0x7d, 0x2c, 0x20, 0x7b, 0x20, 0x5f,
|
0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x74, 0x69, 0x6d, 0x65, 0x72,
|
||||||
0x5f, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x20, 0x3d, 0x20, 0x6c, 0x6f, 0x76,
|
0x2e, 0x73, 0x74, 0x65, 0x70, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x69, 0x66,
|
||||||
0x72, 0x20, 0x7d, 0x29, 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x63, 0x6f,
|
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x6c, 0x6f, 0x61, 0x64, 0x20, 0x74,
|
||||||
0x6e, 0x66, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x20, 0x74, 0x68, 0x65, 0x6e,
|
0x68, 0x65, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x6c, 0x6f, 0x61,
|
||||||
0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x28, 0x63, 0x6f, 0x6e, 0x66, 0x45,
|
0x64, 0x28, 0x61, 0x72, 0x67, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20,
|
||||||
0x72, 0x72, 0x6f, 0x72, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20,
|
0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63,
|
||||||
0x69, 0x66, 0x20, 0x68, 0x61, 0x73, 0x4d, 0x61, 0x69, 0x6e, 0x20, 0x74,
|
0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c,
|
||||||
0x68, 0x65, 0x6e, 0x20, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x20,
|
0x6f, 0x76, 0x72, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x2e, 0x70, 0x75,
|
||||||
0x27, 0x6d, 0x61, 0x69, 0x6e, 0x27, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20,
|
0x6d, 0x70, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72,
|
||||||
0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
0x20, 0x6e, 0x61, 0x6d, 0x65, 0x2c, 0x20, 0x61, 0x2c, 0x20, 0x62, 0x2c,
|
||||||
0x2e, 0x72, 0x75, 0x6e, 0x28, 0x29, 0x0a, 0x65, 0x6e, 0x64, 0x0a, 0x0a,
|
0x20, 0x63, 0x2c, 0x20, 0x64, 0x20, 0x69, 0x6e, 0x20, 0x6c, 0x6f, 0x76,
|
||||||
0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6c, 0x6f, 0x76,
|
0x72, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x2e, 0x70, 0x6f, 0x6c, 0x6c,
|
||||||
0x72, 0x2e, 0x72, 0x75, 0x6e, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x6c, 0x6f,
|
0x28, 0x29, 0x20, 0x64, 0x6f, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x76, 0x72, 0x2e, 0x74, 0x69, 0x6d, 0x65, 0x72, 0x2e, 0x73, 0x74, 0x65,
|
0x69, 0x66, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x3d, 0x3d, 0x20, 0x27,
|
||||||
0x70, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76,
|
0x71, 0x75, 0x69, 0x74, 0x27, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x28, 0x6e,
|
||||||
0x72, 0x2e, 0x6c, 0x6f, 0x61, 0x64, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20,
|
0x6f, 0x74, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x71, 0x75, 0x69, 0x74,
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x6c, 0x6f, 0x61, 0x64, 0x28, 0x61, 0x72,
|
0x20, 0x6f, 0x72, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
0x67, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x72, 0x65, 0x74,
|
0x2e, 0x71, 0x75, 0x69, 0x74, 0x28, 0x29, 0x29, 0x20, 0x74, 0x68, 0x65,
|
||||||
0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e,
|
0x6e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65,
|
||||||
0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
0x74, 0x75, 0x72, 0x6e, 0x20, 0x61, 0x20, 0x6f, 0x72, 0x20, 0x30, 0x0a,
|
||||||
0x65, 0x76, 0x65, 0x6e, 0x74, 0x2e, 0x70, 0x75, 0x6d, 0x70, 0x28, 0x29,
|
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20,
|
||||||
0x0a, 0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x6e, 0x61, 0x6d,
|
|
||||||
0x65, 0x2c, 0x20, 0x61, 0x2c, 0x20, 0x62, 0x2c, 0x20, 0x63, 0x2c, 0x20,
|
|
||||||
0x64, 0x20, 0x69, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x65, 0x76,
|
|
||||||
0x65, 0x6e, 0x74, 0x2e, 0x70, 0x6f, 0x6c, 0x6c, 0x28, 0x29, 0x20, 0x64,
|
|
||||||
0x6f, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6e,
|
|
||||||
0x61, 0x6d, 0x65, 0x20, 0x3d, 0x3d, 0x20, 0x27, 0x71, 0x75, 0x69, 0x74,
|
|
||||||
0x27, 0x20, 0x61, 0x6e, 0x64, 0x20, 0x28, 0x6e, 0x6f, 0x74, 0x20, 0x6c,
|
|
||||||
0x6f, 0x76, 0x72, 0x2e, 0x71, 0x75, 0x69, 0x74, 0x20, 0x6f, 0x72, 0x20,
|
|
||||||
0x6e, 0x6f, 0x74, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x71, 0x75, 0x69,
|
|
||||||
0x74, 0x28, 0x29, 0x29, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x0a, 0x20, 0x20,
|
|
||||||
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
|
|
||||||
0x20, 0x61, 0x20, 0x6f, 0x72, 0x20, 0x30, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
|
||||||
0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
|
||||||
0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x61, 0x6e, 0x64,
|
|
||||||
0x6c, 0x65, 0x72, 0x73, 0x5b, 0x6e, 0x61, 0x6d, 0x65, 0x5d, 0x20, 0x74,
|
|
||||||
0x68, 0x65, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x61, 0x6e,
|
|
||||||
0x64, 0x6c, 0x65, 0x72, 0x73, 0x5b, 0x6e, 0x61, 0x6d, 0x65, 0x5d, 0x28,
|
|
||||||
0x61, 0x2c, 0x20, 0x62, 0x2c, 0x20, 0x63, 0x2c, 0x20, 0x64, 0x29, 0x20,
|
|
||||||
0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a,
|
|
||||||
0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x64, 0x74,
|
|
||||||
0x20, 0x3d, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x74, 0x69, 0x6d, 0x65,
|
|
||||||
0x72, 0x2e, 0x73, 0x74, 0x65, 0x70, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20,
|
|
||||||
0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61,
|
|
||||||
0x64, 0x73, 0x65, 0x74, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x0a, 0x20, 0x20,
|
|
||||||
0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61,
|
|
||||||
0x64, 0x73, 0x65, 0x74, 0x2e, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x28,
|
|
||||||
0x64, 0x74, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a,
|
|
||||||
0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
||||||
0x61, 0x75, 0x64, 0x69, 0x6f, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x0a, 0x20,
|
0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x73, 0x5b, 0x6e, 0x61, 0x6d,
|
||||||
0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x61, 0x75,
|
0x65, 0x5d, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
0x64, 0x69, 0x6f, 0x2e, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x28, 0x29,
|
0x2e, 0x68, 0x61, 0x6e, 0x64, 0x6c, 0x65, 0x72, 0x73, 0x5b, 0x6e, 0x61,
|
||||||
0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f,
|
0x6d, 0x65, 0x5d, 0x28, 0x61, 0x2c, 0x20, 0x62, 0x2c, 0x20, 0x63, 0x2c,
|
||||||
0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x20, 0x74,
|
0x20, 0x64, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x68, 0x65, 0x6e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61,
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x6f, 0x2e, 0x73,
|
0x6c, 0x20, 0x64, 0x74, 0x20, 0x3d, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
||||||
0x65, 0x74, 0x4f, 0x72, 0x69, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, 0x6f,
|
0x74, 0x69, 0x6d, 0x65, 0x72, 0x2e, 0x73, 0x74, 0x65, 0x70, 0x28, 0x29,
|
||||||
0x6e, 0x28, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64, 0x73,
|
|
||||||
0x65, 0x74, 0x2e, 0x67, 0x65, 0x74, 0x4f, 0x72, 0x69, 0x65, 0x6e, 0x74,
|
|
||||||
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x29, 0x0a, 0x20, 0x20, 0x20,
|
|
||||||
0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x61, 0x75,
|
|
||||||
0x64, 0x69, 0x6f, 0x2e, 0x73, 0x65, 0x74, 0x50, 0x6f, 0x73, 0x69, 0x74,
|
|
||||||
0x69, 0x6f, 0x6e, 0x28, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61,
|
|
||||||
0x64, 0x73, 0x65, 0x74, 0x2e, 0x67, 0x65, 0x74, 0x50, 0x6f, 0x73, 0x69,
|
|
||||||
0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
|
||||||
0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x61, 0x75, 0x64,
|
|
||||||
0x69, 0x6f, 0x2e, 0x73, 0x65, 0x74, 0x56, 0x65, 0x6c, 0x6f, 0x63, 0x69,
|
|
||||||
0x74, 0x79, 0x28, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64,
|
|
||||||
0x73, 0x65, 0x74, 0x2e, 0x67, 0x65, 0x74, 0x56, 0x65, 0x6c, 0x6f, 0x63,
|
|
||||||
0x69, 0x74, 0x79, 0x28, 0x29, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20,
|
|
||||||
0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64,
|
|
||||||
0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
0x2e, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x20, 0x74, 0x68, 0x65, 0x6e,
|
0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x20, 0x74, 0x68, 0x65,
|
||||||
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65,
|
0x6e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
0x28, 0x64, 0x74, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20,
|
0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e, 0x75, 0x70, 0x64,
|
||||||
0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61,
|
0x61, 0x74, 0x65, 0x28, 0x64, 0x74, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x70, 0x68, 0x69, 0x63, 0x73, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x0a, 0x20,
|
0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c,
|
||||||
0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72,
|
0x6f, 0x76, 0x72, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x6f, 0x20, 0x74, 0x68,
|
||||||
0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x6f, 0x72, 0x69, 0x67, 0x69,
|
0x65, 0x6e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76,
|
||||||
0x6e, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
|
0x72, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x6f, 0x2e, 0x75, 0x70, 0x64, 0x61,
|
||||||
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x64, 0x72, 0x61, 0x77, 0x20, 0x74,
|
0x74, 0x65, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x69,
|
||||||
0x68, 0x65, 0x6e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64, 0x73,
|
||||||
0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64,
|
0x65, 0x74, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x73, 0x65, 0x74, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x0a, 0x20, 0x20, 0x20,
|
0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x61, 0x75, 0x64,
|
||||||
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
0x69, 0x6f, 0x2e, 0x73, 0x65, 0x74, 0x4f, 0x72, 0x69, 0x65, 0x6e, 0x74,
|
||||||
0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e, 0x72, 0x65, 0x6e, 0x64,
|
0x61, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68,
|
||||||
0x65, 0x72, 0x54, 0x6f, 0x28, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x64, 0x72,
|
0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e, 0x67, 0x65, 0x74, 0x4f, 0x72,
|
||||||
0x61, 0x77, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
0x69, 0x65, 0x6e, 0x74, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x29,
|
||||||
0x65, 0x6c, 0x73, 0x65, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76,
|
||||||
0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70,
|
0x72, 0x2e, 0x61, 0x75, 0x64, 0x69, 0x6f, 0x2e, 0x73, 0x65, 0x74, 0x50,
|
||||||
0x68, 0x69, 0x63, 0x73, 0x2e, 0x63, 0x6c, 0x65, 0x61, 0x72, 0x28, 0x29,
|
0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c,
|
0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e, 0x67, 0x65, 0x74,
|
||||||
0x6f, 0x76, 0x72, 0x2e, 0x64, 0x72, 0x61, 0x77, 0x28, 0x29, 0x0a, 0x20,
|
0x50, 0x6f, 0x73, 0x69, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x29, 0x0a,
|
||||||
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20,
|
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
|
0x2e, 0x61, 0x75, 0x64, 0x69, 0x6f, 0x2e, 0x73, 0x65, 0x74, 0x56, 0x65,
|
||||||
|
0x6c, 0x6f, 0x63, 0x69, 0x74, 0x79, 0x28, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
||||||
|
0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e, 0x67, 0x65, 0x74, 0x56,
|
||||||
|
0x65, 0x6c, 0x6f, 0x63, 0x69, 0x74, 0x79, 0x28, 0x29, 0x29, 0x0a, 0x20,
|
||||||
0x20, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20,
|
0x20, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20,
|
||||||
0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70,
|
0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20,
|
||||||
0x68, 0x69, 0x63, 0x73, 0x2e, 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74,
|
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x20,
|
||||||
0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20,
|
0x74, 0x68, 0x65, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x75, 0x70,
|
||||||
0x20, 0x65, 0x6e, 0x64, 0x0a, 0x65, 0x6e, 0x64, 0x0a, 0x0a, 0x66, 0x75,
|
0x64, 0x61, 0x74, 0x65, 0x28, 0x64, 0x74, 0x29, 0x20, 0x65, 0x6e, 0x64,
|
||||||
0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72,
|
||||||
0x65, 0x72, 0x72, 0x68, 0x61, 0x6e, 0x64, 0x28, 0x6d, 0x65, 0x73, 0x73,
|
0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x20, 0x74, 0x68,
|
||||||
0x61, 0x67, 0x65, 0x29, 0x0a, 0x20, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61,
|
0x65, 0x6e, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76,
|
||||||
0x67, 0x65, 0x20, 0x3d, 0x20, 0x64, 0x65, 0x62, 0x75, 0x67, 0x2e, 0x74,
|
0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x6f,
|
||||||
0x72, 0x61, 0x63, 0x65, 0x62, 0x61, 0x63, 0x6b, 0x28, 0x27, 0x45, 0x72,
|
0x72, 0x69, 0x67, 0x69, 0x6e, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x72, 0x6f, 0x72, 0x3a, 0x5c, 0x6e, 0x27, 0x20, 0x2e, 0x2e, 0x20, 0x6d,
|
0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x64, 0x72,
|
||||||
0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2c, 0x20, 0x32, 0x29, 0x3a, 0x67,
|
0x61, 0x77, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x73, 0x75, 0x62, 0x28, 0x27, 0x5c, 0x6e, 0x5b, 0x5e, 0x5c, 0x6e, 0x5d,
|
0x20, 0x20, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
||||||
0x2b, 0x24, 0x27, 0x2c, 0x20, 0x27, 0x27, 0x29, 0x3a, 0x67, 0x73, 0x75,
|
0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x20, 0x74, 0x68, 0x65, 0x6e,
|
||||||
0x62, 0x28, 0x27, 0x5c, 0x74, 0x27, 0x2c, 0x20, 0x27, 0x27, 0x29, 0x3a,
|
0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c,
|
||||||
0x67, 0x73, 0x75, 0x62, 0x28, 0x27, 0x73, 0x74, 0x61, 0x63, 0x6b, 0x20,
|
0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e,
|
||||||
0x74, 0x72, 0x61, 0x63, 0x65, 0x62, 0x61, 0x63, 0x6b, 0x27, 0x2c, 0x20,
|
0x72, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x54, 0x6f, 0x28, 0x6c, 0x6f, 0x76,
|
||||||
0x27, 0x5c, 0x6e, 0x53, 0x74, 0x61, 0x63, 0x6b, 0x27, 0x29, 0x0a, 0x20,
|
0x72, 0x2e, 0x64, 0x72, 0x61, 0x77, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x20, 0x70, 0x72, 0x69, 0x6e, 0x74, 0x28, 0x6d, 0x65, 0x73, 0x73, 0x61,
|
0x20, 0x20, 0x20, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x0a, 0x20, 0x20, 0x20,
|
||||||
0x67, 0x65, 0x29, 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20, 0x6e, 0x6f, 0x74,
|
0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
||||||
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69,
|
0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x63, 0x6c, 0x65,
|
||||||
0x63, 0x73, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x72, 0x65, 0x74, 0x75,
|
0x61, 0x72, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20,
|
||||||
0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
|
0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x64, 0x72, 0x61, 0x77,
|
||||||
0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x31, 0x20, 0x65,
|
0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x65,
|
||||||
0x6e, 0x64, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x76,
|
0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6e, 0x64,
|
||||||
0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x72,
|
0x0a, 0x20, 0x20, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
||||||
0x65, 0x73, 0x65, 0x74, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x76,
|
0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x70, 0x72, 0x65,
|
||||||
0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x73,
|
0x73, 0x65, 0x6e, 0x74, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65,
|
||||||
0x65, 0x74, 0x42, 0x61, 0x63, 0x6b, 0x67, 0x72, 0x6f, 0x75, 0x6e, 0x64,
|
0x6e, 0x64, 0x0a, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x65, 0x6e, 0x64,
|
||||||
0x43, 0x6f, 0x6c, 0x6f, 0x72, 0x28, 0x2e, 0x31, 0x30, 0x35, 0x2c, 0x20,
|
0x0a, 0x0a, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6c,
|
||||||
0x2e, 0x30, 0x39, 0x38, 0x2c, 0x20, 0x2e, 0x31, 0x33, 0x37, 0x29, 0x0a,
|
0x6f, 0x76, 0x72, 0x2e, 0x65, 0x72, 0x72, 0x68, 0x61, 0x6e, 0x64, 0x28,
|
||||||
0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68,
|
0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x29, 0x0a, 0x20, 0x20, 0x6d,
|
||||||
0x69, 0x63, 0x73, 0x2e, 0x73, 0x65, 0x74, 0x43, 0x6f, 0x6c, 0x6f, 0x72,
|
0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x20, 0x3d, 0x20, 0x64, 0x65, 0x62,
|
||||||
0x28, 0x2e, 0x38, 0x36, 0x33, 0x2c, 0x20, 0x2e, 0x38, 0x36, 0x33, 0x2c,
|
0x75, 0x67, 0x2e, 0x74, 0x72, 0x61, 0x63, 0x65, 0x62, 0x61, 0x63, 0x6b,
|
||||||
0x20, 0x2e, 0x38, 0x36, 0x33, 0x29, 0x0a, 0x20, 0x20, 0x69, 0x66, 0x20,
|
0x28, 0x27, 0x45, 0x72, 0x72, 0x6f, 0x72, 0x3a, 0x5c, 0x6e, 0x27, 0x20,
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74,
|
0x2e, 0x2e, 0x20, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2c, 0x20,
|
||||||
0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68,
|
0x32, 0x29, 0x3a, 0x67, 0x73, 0x75, 0x62, 0x28, 0x27, 0x5c, 0x6e, 0x5b,
|
||||||
0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e, 0x73, 0x65, 0x74, 0x4d, 0x69,
|
0x5e, 0x5c, 0x6e, 0x5d, 0x2b, 0x24, 0x27, 0x2c, 0x20, 0x27, 0x27, 0x29,
|
||||||
0x72, 0x72, 0x6f, 0x72, 0x65, 0x64, 0x28, 0x66, 0x61, 0x6c, 0x73, 0x65,
|
0x3a, 0x67, 0x73, 0x75, 0x62, 0x28, 0x27, 0x5c, 0x74, 0x27, 0x2c, 0x20,
|
||||||
0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61,
|
0x27, 0x27, 0x29, 0x3a, 0x67, 0x73, 0x75, 0x62, 0x28, 0x27, 0x73, 0x74,
|
||||||
0x6c, 0x20, 0x66, 0x6f, 0x6e, 0x74, 0x20, 0x3d, 0x20, 0x6c, 0x6f, 0x76,
|
0x61, 0x63, 0x6b, 0x20, 0x74, 0x72, 0x61, 0x63, 0x65, 0x62, 0x61, 0x63,
|
||||||
0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x67,
|
0x6b, 0x27, 0x2c, 0x20, 0x27, 0x5c, 0x6e, 0x53, 0x74, 0x61, 0x63, 0x6b,
|
||||||
0x65, 0x74, 0x46, 0x6f, 0x6e, 0x74, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x6c,
|
0x27, 0x29, 0x0a, 0x20, 0x20, 0x70, 0x72, 0x69, 0x6e, 0x74, 0x28, 0x6d,
|
||||||
0x6f, 0x63, 0x61, 0x6c, 0x20, 0x70, 0x69, 0x78, 0x65, 0x6c, 0x44, 0x65,
|
0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x29, 0x0a, 0x20, 0x20, 0x69, 0x66,
|
||||||
0x6e, 0x73, 0x69, 0x74, 0x79, 0x20, 0x3d, 0x20, 0x66, 0x6f, 0x6e, 0x74,
|
0x20, 0x6e, 0x6f, 0x74, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72,
|
||||||
0x3a, 0x67, 0x65, 0x74, 0x50, 0x69, 0x78, 0x65, 0x6c, 0x44, 0x65, 0x6e,
|
0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20,
|
||||||
0x73, 0x69, 0x74, 0x79, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63,
|
|
||||||
0x61, 0x6c, 0x20, 0x77, 0x69, 0x64, 0x74, 0x68, 0x20, 0x3d, 0x20, 0x66,
|
|
||||||
0x6f, 0x6e, 0x74, 0x3a, 0x67, 0x65, 0x74, 0x57, 0x69, 0x64, 0x74, 0x68,
|
|
||||||
0x28, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2c, 0x20, 0x2e, 0x35,
|
|
||||||
0x35, 0x20, 0x2a, 0x20, 0x70, 0x69, 0x78, 0x65, 0x6c, 0x44, 0x65, 0x6e,
|
|
||||||
0x73, 0x69, 0x74, 0x79, 0x29, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61,
|
|
||||||
0x6c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x72,
|
|
||||||
0x65, 0x6e, 0x64, 0x65, 0x72, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63,
|
|
||||||
0x73, 0x2e, 0x70, 0x72, 0x69, 0x6e, 0x74, 0x28, 0x6d, 0x65, 0x73, 0x73,
|
|
||||||
0x61, 0x67, 0x65, 0x2c, 0x20, 0x2d, 0x77, 0x69, 0x64, 0x74, 0x68, 0x20,
|
|
||||||
0x2f, 0x20, 0x32, 0x2c, 0x20, 0x30, 0x2c, 0x20, 0x2d, 0x32, 0x30, 0x2c,
|
|
||||||
0x20, 0x31, 0x2c, 0x20, 0x30, 0x2c, 0x20, 0x30, 0x2c, 0x20, 0x30, 0x2c,
|
|
||||||
0x20, 0x30, 0x2c, 0x20, 0x2e, 0x35, 0x35, 0x20, 0x2a, 0x20, 0x70, 0x69,
|
|
||||||
0x78, 0x65, 0x6c, 0x44, 0x65, 0x6e, 0x73, 0x69, 0x74, 0x79, 0x2c, 0x20,
|
|
||||||
0x27, 0x6c, 0x65, 0x66, 0x74, 0x27, 0x29, 0x0a, 0x20, 0x20, 0x65, 0x6e,
|
|
||||||
0x64, 0x0a, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66,
|
|
||||||
0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x0a, 0x20, 0x20,
|
|
||||||
0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x74,
|
|
||||||
0x2e, 0x70, 0x75, 0x6d, 0x70, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20,
|
|
||||||
0x66, 0x6f, 0x72, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x69, 0x6e, 0x20,
|
|
||||||
0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x65, 0x76, 0x65, 0x6e, 0x74, 0x2e, 0x70,
|
|
||||||
0x6f, 0x6c, 0x6c, 0x28, 0x29, 0x20, 0x64, 0x6f, 0x20, 0x69, 0x66, 0x20,
|
|
||||||
0x6e, 0x61, 0x6d, 0x65, 0x20, 0x3d, 0x3d, 0x20, 0x27, 0x71, 0x75, 0x69,
|
|
||||||
0x74, 0x27, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x72, 0x65, 0x74, 0x75,
|
|
||||||
0x72, 0x6e, 0x20, 0x31, 0x20, 0x65, 0x6e, 0x64, 0x20, 0x65, 0x6e, 0x64,
|
|
||||||
0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72,
|
|
||||||
0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x63, 0x6c, 0x65, 0x61, 0x72,
|
|
||||||
0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
|
||||||
0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x6f, 0x72, 0x69,
|
|
||||||
0x67, 0x69, 0x6e, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
|
|
||||||
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65,
|
|
||||||
0x74, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e,
|
|
||||||
0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e, 0x72, 0x65, 0x6e, 0x64,
|
|
||||||
0x65, 0x72, 0x54, 0x6f, 0x28, 0x72, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x29,
|
|
||||||
0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x72, 0x65, 0x6e,
|
|
||||||
0x64, 0x65, 0x72, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f,
|
|
||||||
0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e,
|
|
||||||
0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x28, 0x29, 0x0a, 0x20, 0x20,
|
|
||||||
0x65, 0x6e, 0x64, 0x0a, 0x65, 0x6e, 0x64, 0x0a, 0x0a, 0x66, 0x75, 0x6e,
|
|
||||||
0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x74,
|
|
||||||
0x68, 0x72, 0x65, 0x61, 0x64, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x28, 0x74,
|
|
||||||
0x68, 0x72, 0x65, 0x61, 0x64, 0x2c, 0x20, 0x65, 0x72, 0x72, 0x29, 0x0a,
|
|
||||||
0x20, 0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x28, 0x27, 0x54, 0x68, 0x72,
|
|
||||||
0x65, 0x61, 0x64, 0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x5c, 0x6e, 0x5c,
|
|
||||||
0x6e, 0x27, 0x20, 0x2e, 0x2e, 0x20, 0x65, 0x72, 0x72, 0x2c, 0x20, 0x30,
|
|
||||||
0x29, 0x0a, 0x65, 0x6e, 0x64, 0x0a, 0x0a, 0x72, 0x65, 0x74, 0x75, 0x72,
|
|
||||||
0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29,
|
|
||||||
0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x65, 0x72, 0x72,
|
|
||||||
0x6f, 0x72, 0x65, 0x64, 0x20, 0x3d, 0x20, 0x66, 0x61, 0x6c, 0x73, 0x65,
|
|
||||||
0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x66, 0x75, 0x6e,
|
|
||||||
0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x6e, 0x65, 0x72, 0x72, 0x6f,
|
|
||||||
0x72, 0x28, 0x2e, 0x2e, 0x2e, 0x29, 0x20, 0x69, 0x66, 0x20, 0x6e, 0x6f,
|
|
||||||
0x74, 0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x65, 0x64, 0x20, 0x74, 0x68,
|
|
||||||
0x65, 0x6e, 0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x65, 0x64, 0x20, 0x3d,
|
|
||||||
0x20, 0x74, 0x72, 0x75, 0x65, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
|
|
||||||
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x65, 0x72, 0x72, 0x68, 0x61, 0x6e,
|
|
||||||
0x64, 0x28, 0x2e, 0x2e, 0x2e, 0x29, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x20,
|
|
||||||
0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
|
0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74,
|
||||||
0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
|
0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e,
|
||||||
0x20, 0x31, 0x20, 0x65, 0x6e, 0x64, 0x20, 0x65, 0x6e, 0x64, 0x20, 0x65,
|
0x20, 0x31, 0x20, 0x65, 0x6e, 0x64, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20,
|
||||||
0x6e, 0x64, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x5f,
|
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69,
|
||||||
0x2c, 0x20, 0x74, 0x68, 0x72, 0x65, 0x61, 0x64, 0x20, 0x3d, 0x20, 0x78,
|
0x63, 0x73, 0x2e, 0x72, 0x65, 0x73, 0x65, 0x74, 0x28, 0x29, 0x0a, 0x20,
|
||||||
0x70, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x62,
|
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69,
|
||||||
0x6f, 0x6f, 0x74, 0x2c, 0x20, 0x6f, 0x6e, 0x65, 0x72, 0x72, 0x6f, 0x72,
|
0x63, 0x73, 0x2e, 0x73, 0x65, 0x74, 0x42, 0x61, 0x63, 0x6b, 0x67, 0x72,
|
||||||
0x29, 0x0a, 0x0a, 0x20, 0x20, 0x77, 0x68, 0x69, 0x6c, 0x65, 0x20, 0x74,
|
0x6f, 0x75, 0x6e, 0x64, 0x43, 0x6f, 0x6c, 0x6f, 0x72, 0x28, 0x2e, 0x31,
|
||||||
0x72, 0x75, 0x65, 0x20, 0x64, 0x6f, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c,
|
0x30, 0x35, 0x2c, 0x20, 0x2e, 0x30, 0x39, 0x38, 0x2c, 0x20, 0x2e, 0x31,
|
||||||
0x6f, 0x63, 0x61, 0x6c, 0x20, 0x6f, 0x6b, 0x2c, 0x20, 0x72, 0x65, 0x73,
|
0x33, 0x37, 0x29, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67,
|
||||||
0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x78, 0x70, 0x63, 0x61, 0x6c, 0x6c,
|
0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x73, 0x65, 0x74, 0x43,
|
||||||
0x28, 0x74, 0x68, 0x72, 0x65, 0x61, 0x64, 0x2c, 0x20, 0x6f, 0x6e, 0x65,
|
0x6f, 0x6c, 0x6f, 0x72, 0x28, 0x2e, 0x38, 0x36, 0x33, 0x2c, 0x20, 0x2e,
|
||||||
0x72, 0x72, 0x6f, 0x72, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x69, 0x66,
|
0x38, 0x36, 0x33, 0x2c, 0x20, 0x2e, 0x38, 0x36, 0x33, 0x29, 0x0a, 0x20,
|
||||||
0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x61, 0x6e, 0x64, 0x20,
|
0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61,
|
||||||
0x6f, 0x6b, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x72, 0x65, 0x74, 0x75,
|
0x64, 0x73, 0x65, 0x74, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6c, 0x6f,
|
||||||
0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x0a, 0x20, 0x20,
|
0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e, 0x73,
|
||||||
0x20, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x69, 0x66, 0x20, 0x6e, 0x6f, 0x74,
|
0x65, 0x74, 0x4d, 0x69, 0x72, 0x72, 0x6f, 0x72, 0x65, 0x64, 0x28, 0x66,
|
||||||
0x20, 0x6f, 0x6b, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x74, 0x68, 0x72,
|
0x61, 0x6c, 0x73, 0x65, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20,
|
||||||
0x65, 0x61, 0x64, 0x20, 0x3d, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74,
|
0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x66, 0x6f, 0x6e, 0x74, 0x20, 0x3d,
|
||||||
0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x63, 0x6f, 0x72,
|
0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69,
|
||||||
0x6f, 0x75, 0x74, 0x69, 0x6e, 0x65, 0x2e, 0x79, 0x69, 0x65, 0x6c, 0x64,
|
0x63, 0x73, 0x2e, 0x67, 0x65, 0x74, 0x46, 0x6f, 0x6e, 0x74, 0x28, 0x29,
|
||||||
0x28, 0x29, 0x0a, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x0a, 0x20, 0x20,
|
0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x70, 0x69, 0x78,
|
||||||
0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x31, 0x0a, 0x65, 0x6e, 0x64,
|
0x65, 0x6c, 0x44, 0x65, 0x6e, 0x73, 0x69, 0x74, 0x79, 0x20, 0x3d, 0x20,
|
||||||
0x0a
|
0x66, 0x6f, 0x6e, 0x74, 0x3a, 0x67, 0x65, 0x74, 0x50, 0x69, 0x78, 0x65,
|
||||||
|
0x6c, 0x44, 0x65, 0x6e, 0x73, 0x69, 0x74, 0x79, 0x28, 0x29, 0x0a, 0x20,
|
||||||
|
0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x77, 0x69, 0x64, 0x74, 0x68,
|
||||||
|
0x20, 0x3d, 0x20, 0x66, 0x6f, 0x6e, 0x74, 0x3a, 0x67, 0x65, 0x74, 0x57,
|
||||||
|
0x69, 0x64, 0x74, 0x68, 0x28, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65,
|
||||||
|
0x2c, 0x20, 0x2e, 0x35, 0x35, 0x20, 0x2a, 0x20, 0x70, 0x69, 0x78, 0x65,
|
||||||
|
0x6c, 0x44, 0x65, 0x6e, 0x73, 0x69, 0x74, 0x79, 0x29, 0x0a, 0x20, 0x20,
|
||||||
|
0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
|
||||||
|
0x6f, 0x6e, 0x20, 0x72, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x28, 0x29, 0x0a,
|
||||||
|
0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61,
|
||||||
|
0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x70, 0x72, 0x69, 0x6e, 0x74, 0x28,
|
||||||
|
0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2c, 0x20, 0x2d, 0x77, 0x69,
|
||||||
|
0x64, 0x74, 0x68, 0x20, 0x2f, 0x20, 0x32, 0x2c, 0x20, 0x30, 0x2c, 0x20,
|
||||||
|
0x2d, 0x32, 0x30, 0x2c, 0x20, 0x31, 0x2c, 0x20, 0x30, 0x2c, 0x20, 0x30,
|
||||||
|
0x2c, 0x20, 0x30, 0x2c, 0x20, 0x30, 0x2c, 0x20, 0x2e, 0x35, 0x35, 0x20,
|
||||||
|
0x2a, 0x20, 0x70, 0x69, 0x78, 0x65, 0x6c, 0x44, 0x65, 0x6e, 0x73, 0x69,
|
||||||
|
0x74, 0x79, 0x2c, 0x20, 0x27, 0x6c, 0x65, 0x66, 0x74, 0x27, 0x29, 0x0a,
|
||||||
|
0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75,
|
||||||
|
0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28,
|
||||||
|
0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x65,
|
||||||
|
0x76, 0x65, 0x6e, 0x74, 0x2e, 0x70, 0x75, 0x6d, 0x70, 0x28, 0x29, 0x0a,
|
||||||
|
0x20, 0x20, 0x20, 0x20, 0x66, 0x6f, 0x72, 0x20, 0x6e, 0x61, 0x6d, 0x65,
|
||||||
|
0x20, 0x69, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x65, 0x76, 0x65,
|
||||||
|
0x6e, 0x74, 0x2e, 0x70, 0x6f, 0x6c, 0x6c, 0x28, 0x29, 0x20, 0x64, 0x6f,
|
||||||
|
0x20, 0x69, 0x66, 0x20, 0x6e, 0x61, 0x6d, 0x65, 0x20, 0x3d, 0x3d, 0x20,
|
||||||
|
0x27, 0x71, 0x75, 0x69, 0x74, 0x27, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20,
|
||||||
|
0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x31, 0x20, 0x65, 0x6e, 0x64,
|
||||||
|
0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c, 0x6f, 0x76,
|
||||||
|
0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73, 0x2e, 0x63,
|
||||||
|
0x6c, 0x65, 0x61, 0x72, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x6c,
|
||||||
|
0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68, 0x69, 0x63, 0x73,
|
||||||
|
0x2e, 0x6f, 0x72, 0x69, 0x67, 0x69, 0x6e, 0x28, 0x29, 0x0a, 0x20, 0x20,
|
||||||
|
0x20, 0x20, 0x69, 0x66, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65,
|
||||||
|
0x61, 0x64, 0x73, 0x65, 0x74, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x6c,
|
||||||
|
0x6f, 0x76, 0x72, 0x2e, 0x68, 0x65, 0x61, 0x64, 0x73, 0x65, 0x74, 0x2e,
|
||||||
|
0x72, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x54, 0x6f, 0x28, 0x72, 0x65, 0x6e,
|
||||||
|
0x64, 0x65, 0x72, 0x29, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20,
|
||||||
|
0x20, 0x72, 0x65, 0x6e, 0x64, 0x65, 0x72, 0x28, 0x29, 0x0a, 0x20, 0x20,
|
||||||
|
0x20, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x67, 0x72, 0x61, 0x70, 0x68,
|
||||||
|
0x69, 0x63, 0x73, 0x2e, 0x70, 0x72, 0x65, 0x73, 0x65, 0x6e, 0x74, 0x28,
|
||||||
|
0x29, 0x0a, 0x20, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x65, 0x6e, 0x64, 0x0a,
|
||||||
|
0x0a, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6c, 0x6f,
|
||||||
|
0x76, 0x72, 0x2e, 0x74, 0x68, 0x72, 0x65, 0x61, 0x64, 0x65, 0x72, 0x72,
|
||||||
|
0x6f, 0x72, 0x28, 0x74, 0x68, 0x72, 0x65, 0x61, 0x64, 0x2c, 0x20, 0x65,
|
||||||
|
0x72, 0x72, 0x29, 0x0a, 0x20, 0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x28,
|
||||||
|
0x27, 0x54, 0x68, 0x72, 0x65, 0x61, 0x64, 0x20, 0x65, 0x72, 0x72, 0x6f,
|
||||||
|
0x72, 0x5c, 0x6e, 0x5c, 0x6e, 0x27, 0x20, 0x2e, 0x2e, 0x20, 0x65, 0x72,
|
||||||
|
0x72, 0x2c, 0x20, 0x30, 0x29, 0x0a, 0x65, 0x6e, 0x64, 0x0a, 0x0a, 0x72,
|
||||||
|
0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69,
|
||||||
|
0x6f, 0x6e, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c,
|
||||||
|
0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x65, 0x64, 0x20, 0x3d, 0x20, 0x66,
|
||||||
|
0x61, 0x6c, 0x73, 0x65, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c,
|
||||||
|
0x20, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x20, 0x6f, 0x6e,
|
||||||
|
0x65, 0x72, 0x72, 0x6f, 0x72, 0x28, 0x2e, 0x2e, 0x2e, 0x29, 0x20, 0x69,
|
||||||
|
0x66, 0x20, 0x6e, 0x6f, 0x74, 0x20, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x65,
|
||||||
|
0x64, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20, 0x65, 0x72, 0x72, 0x6f, 0x72,
|
||||||
|
0x65, 0x64, 0x20, 0x3d, 0x20, 0x74, 0x72, 0x75, 0x65, 0x20, 0x72, 0x65,
|
||||||
|
0x74, 0x75, 0x72, 0x6e, 0x20, 0x6c, 0x6f, 0x76, 0x72, 0x2e, 0x65, 0x72,
|
||||||
|
0x72, 0x68, 0x61, 0x6e, 0x64, 0x28, 0x2e, 0x2e, 0x2e, 0x29, 0x20, 0x65,
|
||||||
|
0x6c, 0x73, 0x65, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x66,
|
||||||
|
0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x28, 0x29, 0x20, 0x72, 0x65,
|
||||||
|
0x74, 0x75, 0x72, 0x6e, 0x20, 0x31, 0x20, 0x65, 0x6e, 0x64, 0x20, 0x65,
|
||||||
|
0x6e, 0x64, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x6c, 0x6f, 0x63,
|
||||||
|
0x61, 0x6c, 0x20, 0x5f, 0x2c, 0x20, 0x74, 0x68, 0x72, 0x65, 0x61, 0x64,
|
||||||
|
0x20, 0x3d, 0x20, 0x78, 0x70, 0x63, 0x61, 0x6c, 0x6c, 0x28, 0x6c, 0x6f,
|
||||||
|
0x76, 0x72, 0x2e, 0x62, 0x6f, 0x6f, 0x74, 0x2c, 0x20, 0x6f, 0x6e, 0x65,
|
||||||
|
0x72, 0x72, 0x6f, 0x72, 0x29, 0x0a, 0x0a, 0x20, 0x20, 0x77, 0x68, 0x69,
|
||||||
|
0x6c, 0x65, 0x20, 0x74, 0x72, 0x75, 0x65, 0x20, 0x64, 0x6f, 0x0a, 0x20,
|
||||||
|
0x20, 0x20, 0x20, 0x6c, 0x6f, 0x63, 0x61, 0x6c, 0x20, 0x6f, 0x6b, 0x2c,
|
||||||
|
0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20, 0x3d, 0x20, 0x78, 0x70,
|
||||||
|
0x63, 0x61, 0x6c, 0x6c, 0x28, 0x74, 0x68, 0x72, 0x65, 0x61, 0x64, 0x2c,
|
||||||
|
0x20, 0x6f, 0x6e, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x29, 0x0a, 0x20, 0x20,
|
||||||
|
0x20, 0x20, 0x69, 0x66, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c, 0x74, 0x20,
|
||||||
|
0x61, 0x6e, 0x64, 0x20, 0x6f, 0x6b, 0x20, 0x74, 0x68, 0x65, 0x6e, 0x20,
|
||||||
|
0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x72, 0x65, 0x73, 0x75, 0x6c,
|
||||||
|
0x74, 0x0a, 0x20, 0x20, 0x20, 0x20, 0x65, 0x6c, 0x73, 0x65, 0x69, 0x66,
|
||||||
|
0x20, 0x6e, 0x6f, 0x74, 0x20, 0x6f, 0x6b, 0x20, 0x74, 0x68, 0x65, 0x6e,
|
||||||
|
0x20, 0x74, 0x68, 0x72, 0x65, 0x61, 0x64, 0x20, 0x3d, 0x20, 0x72, 0x65,
|
||||||
|
0x73, 0x75, 0x6c, 0x74, 0x20, 0x65, 0x6e, 0x64, 0x0a, 0x20, 0x20, 0x20,
|
||||||
|
0x20, 0x63, 0x6f, 0x72, 0x6f, 0x75, 0x74, 0x69, 0x6e, 0x65, 0x2e, 0x79,
|
||||||
|
0x69, 0x65, 0x6c, 0x64, 0x28, 0x29, 0x0a, 0x20, 0x20, 0x65, 0x6e, 0x64,
|
||||||
|
0x0a, 0x0a, 0x20, 0x20, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x20, 0x31,
|
||||||
|
0x0a, 0x65, 0x6e, 0x64, 0x0a
|
||||||
};
|
};
|
||||||
unsigned int boot_lua_len = 5605;
|
unsigned int boot_lua_len = 5621;
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <dlfcn.h>
|
#include <dlfcn.h>
|
||||||
#endif
|
#endif
|
||||||
#ifdef LOVR_OVR_MOBILE
|
#ifdef LOVR_USE_OCULUS_MOBILE
|
||||||
#include <android/log.h>
|
#include <android/log.h>
|
||||||
#include <assert.h>
|
#include <assert.h>
|
||||||
#endif
|
#endif
|
||||||
|
@ -38,7 +38,6 @@ void lovrThrow(const char* format, ...) {
|
||||||
fprintf(stderr, "\n");
|
fprintf(stderr, "\n");
|
||||||
va_end(args);
|
va_end(args);
|
||||||
exit(EXIT_FAILURE);
|
exit(EXIT_FAILURE);
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue