1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Drop ENABLE_GLES option

ENABLE_GLES predates forking Irrlicht. Its primary use was to distinguish Irrlicht-ogles from upstream version as Minetest could be compiled with either.
That's not necessary anymore and gets in the way sometimes.
This commit is contained in:
sfan5 2023-03-05 15:10:44 +01:00
parent c26e122485
commit 9d736e8b8b
14 changed files with 33 additions and 82 deletions

View file

@ -34,6 +34,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "render/factory.h"
#include "inputhandler.h"
#include "gettext.h"
#include "filesys.h"
#include "../gui/guiSkin.h"
#if !defined(_WIN32) && !defined(__APPLE__) && !defined(__ANDROID__) && \
@ -51,10 +52,6 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include <winuser.h>
#endif
#if ENABLE_GLES
#include "filesys.h"
#endif
RenderingEngine *RenderingEngine::s_singleton = nullptr;
const float RenderingEngine::BASE_BLOOM_STRENGTH = 1.0f;
@ -136,12 +133,10 @@ RenderingEngine::RenderingEngine(IEventReceiver *receiver)
#ifdef __ANDROID__
params.PrivateData = porting::app_global;
#endif
#if ENABLE_GLES
// there is no standardized path for these on desktop
std::string rel_path = std::string("client") + DIR_DELIM
+ "shaders" + DIR_DELIM + "Irrlicht";
params.OGLES2ShaderPath = (porting::path_share + DIR_DELIM + rel_path + DIR_DELIM).c_str();
#endif
m_device = createDeviceEx(params);
driver = m_device->getVideoDriver();
@ -289,10 +284,8 @@ static bool getWindowHandle(irr::video::IVideoDriver *driver, HWND &hWnd)
const video::SExposedVideoData exposedData = driver->getExposedVideoData();
switch (driver->getDriverType()) {
#if ENABLE_GLES
case video::EDT_OGLES1:
case video::EDT_OGLES2:
#endif
case video::EDT_OPENGL:
hWnd = reinterpret_cast<HWND>(exposedData.OpenGLWin32.HWnd);
break;