mirror of
https://github.com/love2d/love.git
synced 2026-08-12 16:40:57 +02:00
Split wrap_Graphics.lua into two files to work around VS2013's 16kB limit for raw string literals.
This commit is contained in:
@@ -45,6 +45,11 @@ static const char graphics_lua[] =
|
||||
#include "wrap_Graphics.lua"
|
||||
;
|
||||
|
||||
// This is in a separate file because VS2013 has a 16KB limit for raw strings..
|
||||
static const char graphics_shader_lua[] =
|
||||
#include "wrap_GraphicsShader.lua"
|
||||
;
|
||||
|
||||
namespace love
|
||||
{
|
||||
namespace graphics
|
||||
@@ -3075,6 +3080,11 @@ extern "C" int luaopen_love_graphics(lua_State *L)
|
||||
else
|
||||
lua_error(L);
|
||||
|
||||
if (luaL_loadbuffer(L, (const char *)graphics_shader_lua, sizeof(graphics_shader_lua), "wrap_GraphicsShader.lua") == 0)
|
||||
lua_call(L, 0, 0);
|
||||
else
|
||||
lua_error(L);
|
||||
|
||||
return n;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user