diff --git a/src/common/config.h b/src/common/config.h index b0109462d..75844c127 100644 --- a/src/common/config.h +++ b/src/common/config.h @@ -31,9 +31,6 @@ #if defined(__APPLE__) # define LOVE_MACOSX 1 #endif -#if defined(macintosh) -# define LOVE_MACOS 1 -#endif // Endianness. #if defined(__i386__) || defined(__i386) diff --git a/src/common/runtime.cpp b/src/common/runtime.cpp index 64660088c..895540e1b 100644 --- a/src/common/runtime.cpp +++ b/src/common/runtime.cpp @@ -130,7 +130,7 @@ std::string luax_checkstring(lua_State *L, int idx) return std::string(str, len); } -void luax_pushstring(lua_State *L, std::string str) +void luax_pushstring(lua_State *L, const std::string &str) { lua_pushlstring(L, str.data(), str.size()); } @@ -466,11 +466,15 @@ StringMap::Entry typeEntries[] = {"ParticleSystem", GRAPHICS_PARTICLE_SYSTEM_ID}, {"SpriteBatch", GRAPHICS_SPRITE_BATCH_ID}, {"Canvas", GRAPHICS_CANVAS_ID}, + {"Shader", GRAPHICS_SHADER_ID}, // Image {"ImageData", IMAGE_IMAGE_DATA_ID}, {"CompressedData", IMAGE_COMPRESSED_DATA_ID}, + // Math + {"RandomGenerator", MATH_RANDOM_GENERATOR_ID}, + // Audio {"Source", AUDIO_SOURCE_ID}, diff --git a/src/common/runtime.h b/src/common/runtime.h index 052307aaf..4114eee3d 100644 --- a/src/common/runtime.h +++ b/src/common/runtime.h @@ -156,7 +156,7 @@ std::string luax_checkstring(lua_State *L, int idx); * @param L The Lua state. * @param str The string to push. **/ -void luax_pushstring(lua_State *L, std::string str); +void luax_pushstring(lua_State *L, const std::string &str); /** * Require at least 'min' number of items on the stack. diff --git a/src/modules/graphics/opengl/Canvas.cpp b/src/modules/graphics/opengl/Canvas.cpp index 3c0b0fe4f..9fb7d0f79 100644 --- a/src/modules/graphics/opengl/Canvas.cpp +++ b/src/modules/graphics/opengl/Canvas.cpp @@ -421,7 +421,7 @@ bool Canvas::isSupported() bool Canvas::isHDRSupported() { - return GLEE_VERSION_3_0 || GLEE_ARB_texture_float; + return GLEE_VERSION_3_0 || (isSupported() && GLEE_ARB_texture_float); } bool Canvas::isMultiCanvasSupported()