mirror of
https://github.com/luanti-org/luanti.git
synced 2025-11-21 08:55:21 +01:00
Dynamic shadows with the ogles2 driver on OpenGL ES 3.0+ (#16661)
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
#include "l_menu_common.h"
|
||||
|
||||
#include "client/renderingengine.h"
|
||||
#include "client/shadows/dynamicshadowsrender.h"
|
||||
#include "gettext.h"
|
||||
#include "lua_api/l_internal.h"
|
||||
|
||||
@@ -28,6 +29,13 @@ int ModApiMenuCommon::l_get_active_driver(lua_State *L)
|
||||
}
|
||||
|
||||
|
||||
int ModApiMenuCommon::l_driver_supports_shadows(lua_State *L)
|
||||
{
|
||||
lua_pushboolean(L, ShadowRenderer::isSupported(RenderingEngine::get_raw_device()));
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
int ModApiMenuCommon::l_irrlicht_device_supports_touch(lua_State *L)
|
||||
{
|
||||
lua_pushboolean(L, RenderingEngine::get_raw_device()->supportsTouchEvents());
|
||||
@@ -47,6 +55,7 @@ void ModApiMenuCommon::Initialize(lua_State *L, int top)
|
||||
{
|
||||
API_FCT(gettext);
|
||||
API_FCT(get_active_driver);
|
||||
API_FCT(driver_supports_shadows);
|
||||
API_FCT(irrlicht_device_supports_touch);
|
||||
API_FCT(normalize_keycode);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user