1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-14 00:55:20 +02:00

Unify OpenGL ES support

This commit is contained in:
sfan5
2019-07-25 00:01:25 +02:00
parent 526a9e4b66
commit ca363d3ef8
8 changed files with 39 additions and 21 deletions

View File

@@ -30,6 +30,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "client/renderingengine.h"
#include "settings.h"
#include "camera.h" // CameraModes
#include "config.h"
Sky::Sky(s32 id, ITextureSource *tsrc):
@@ -44,7 +45,7 @@ Sky::Sky(s32 id, ITextureSource *tsrc):
video::SMaterial mat;
mat.Lighting = false;
#ifdef __ANDROID__
#if ENABLE_GLES
mat.ZBuffer = video::ECFN_DISABLED;
#else
mat.ZBuffer = video::ECFN_NEVER;
@@ -273,7 +274,7 @@ void Sky::render()
// Stars are only drawn when brighter than skycolor
if (starcolor.getBlue() < m_skycolor.getBlue())
break;
#ifdef __ANDROID__
#if ENABLE_GLES
u16 indices[SKY_STAR_COUNT * 3];
video::S3DVertex vertices[SKY_STAR_COUNT * 3];
for (u32 i = 0; i < SKY_STAR_COUNT; i++) {