mirror of
https://github.com/luanti-org/luanti.git
synced 2025-11-20 16:35:25 +01:00
Reapply "Prefer GL3 driver over legacy GL driver"
This reverts commit 0fa56a9f7c.
This commit is contained in:
4
.github/workflows/lua.yml
vendored
4
.github/workflows/lua.yml
vendored
@@ -37,9 +37,9 @@ jobs:
|
||||
run: |
|
||||
serverconf="profiler.load=true" ./util/test_multiplayer.sh
|
||||
|
||||
- name: Singleplayer test
|
||||
- name: Singleplayer test (legacy GL)
|
||||
run: |
|
||||
xvfb-run ./util/test_singleplayer.sh
|
||||
clientconf="video_driver=opengl" xvfb-run ./util/test_singleplayer.sh
|
||||
|
||||
luacheck:
|
||||
name: "Builtin Luacheck and Unit Tests"
|
||||
|
||||
@@ -2006,7 +2006,7 @@ shader_path (Shader path) path
|
||||
|
||||
# The rendering back-end.
|
||||
# Note: A restart is required after changing this!
|
||||
# OpenGL is the default for desktop, and OGLES2 for Android.
|
||||
# By default OpenGL3 is preferred on desktop, or OGLES2 on Android.
|
||||
video_driver (Video driver) enum ,opengl,opengl3,ogles2
|
||||
|
||||
# Distance in nodes at which transparency depth sorting is enabled.
|
||||
|
||||
@@ -12,12 +12,12 @@ The build system is CMake.
|
||||
|
||||
The following libraries are required to be installed:
|
||||
* zlib, libPNG, libJPEG
|
||||
* OpenGL
|
||||
* or on mobile: OpenGL ES (can be optionally enabled on desktop too)
|
||||
* OpenGL or OpenGL ES
|
||||
* a headless build is possible, but not very useful
|
||||
* SDL2 or SDL3 (see below)
|
||||
|
||||
Aside from standard search options (`ZLIB_INCLUDE_DIR`, `ZLIB_LIBRARY`, ...) the following options are available:
|
||||
* `ENABLE_OPENGL` - Enable OpenGL driver
|
||||
* `ENABLE_OPENGL` - Enable legacy OpenGL driver
|
||||
* `ENABLE_OPENGL3` - Enable OpenGL 3+ driver
|
||||
* `ENABLE_GLES2` - Enable OpenGL ES 2+ driver
|
||||
* `USE_SDL3` (default: `OFF`) - Use the SDL3 device instead of SDL2 (**experimental**)
|
||||
|
||||
@@ -104,7 +104,7 @@ option(ENABLE_OPENGL3 "Enable OpenGL 3+" ${DEFAULT_OPENGL3})
|
||||
if(ANDROID OR EMSCRIPTEN)
|
||||
set(ENABLE_OPENGL FALSE)
|
||||
else()
|
||||
option(ENABLE_OPENGL "Enable OpenGL" TRUE)
|
||||
option(ENABLE_OPENGL "Enable legacy OpenGL" TRUE)
|
||||
endif()
|
||||
|
||||
if(APPLE)
|
||||
@@ -148,13 +148,9 @@ endif()
|
||||
|
||||
# Configuration report
|
||||
|
||||
message(STATUS "OpenGL: ${ENABLE_OPENGL}")
|
||||
message(STATUS "OpenGL (legacy): ${ENABLE_OPENGL}")
|
||||
message(STATUS "OpenGL 3: ${ENABLE_OPENGL3}")
|
||||
if (ENABLE_GLES2)
|
||||
message(STATUS "OpenGL ES 2: ON (unified)")
|
||||
else()
|
||||
message(STATUS "OpenGL ES 2: OFF")
|
||||
endif()
|
||||
message(STATUS "OpenGL ES 2: ${ENABLE_GLES2}")
|
||||
#message(STATUS "WebGL: ${ENABLE_WEBGL1}")
|
||||
|
||||
# Required libs
|
||||
@@ -297,7 +293,7 @@ set(IRRDRVROBJ
|
||||
mt_opengl_loader.cpp
|
||||
)
|
||||
|
||||
# the two legacy drivers
|
||||
# the legacy driver
|
||||
|
||||
if(ENABLE_OPENGL)
|
||||
set(IRRDRVROBJ
|
||||
|
||||
@@ -376,8 +376,8 @@ std::vector<video::E_DRIVER_TYPE> RenderingEngine::getSupportedVideoDrivers()
|
||||
// Only check these drivers. We do not support software and D3D in any capacity.
|
||||
// ordered by preference (best first)
|
||||
static const video::E_DRIVER_TYPE glDrivers[] = {
|
||||
video::EDT_OPENGL,
|
||||
video::EDT_OPENGL3,
|
||||
video::EDT_OPENGL,
|
||||
video::EDT_OGLES2,
|
||||
video::EDT_NULL,
|
||||
};
|
||||
@@ -412,7 +412,7 @@ const VideoDriverInfo &RenderingEngine::getVideoDriverInfo(video::E_DRIVER_TYPE
|
||||
{
|
||||
static const std::unordered_map<int, VideoDriverInfo> driver_info_map = {
|
||||
{(int)video::EDT_NULL, {"null", "NULL Driver"}},
|
||||
{(int)video::EDT_OPENGL, {"opengl", "OpenGL"}},
|
||||
{(int)video::EDT_OPENGL, {"opengl", "OpenGL (legacy)"}},
|
||||
{(int)video::EDT_OPENGL3, {"opengl3", "OpenGL 3+"}},
|
||||
{(int)video::EDT_OGLES2, {"ogles2", "OpenGL ES 2"}},
|
||||
};
|
||||
|
||||
@@ -308,7 +308,7 @@ void set_default_settings()
|
||||
|
||||
// Effects
|
||||
settings->setDefault("enable_post_processing", "true");
|
||||
settings->setDefault("post_processing_texture_bits", "16");
|
||||
settings->setDefault("post_processing_texture_bits", "10");
|
||||
settings->setDefault("directional_colored_fog", "true");
|
||||
settings->setDefault("inventory_items_animations", "false");
|
||||
settings->setDefault("mip_map", "false");
|
||||
|
||||
Reference in New Issue
Block a user