Tweaked opengl terrain tessellation to speed up rendering
This commit is contained in:
parent
84e9d6c896
commit
44c03e46a9
2 changed files with 4 additions and 4 deletions
|
@ -203,15 +203,15 @@ void ExplorerChunkTerrain::updatePriority(CameraDefinition* camera)
|
||||||
{
|
{
|
||||||
_texture_wanted_size = 2;
|
_texture_wanted_size = 2;
|
||||||
}
|
}
|
||||||
else if (distance_to_camera < 50.0)
|
else if (distance_to_camera < 60.0)
|
||||||
{
|
{
|
||||||
_texture_wanted_size = _texture_max_size;
|
_texture_wanted_size = _texture_max_size;
|
||||||
}
|
}
|
||||||
else if (distance_to_camera < 100.0)
|
else if (distance_to_camera < 140.0)
|
||||||
{
|
{
|
||||||
_texture_wanted_size = _texture_max_size / 4;
|
_texture_wanted_size = _texture_max_size / 4;
|
||||||
}
|
}
|
||||||
else if (distance_to_camera < 200.0)
|
else if (distance_to_camera < 300.0)
|
||||||
{
|
{
|
||||||
_texture_wanted_size = _texture_max_size / 8;
|
_texture_wanted_size = _texture_max_size / 8;
|
||||||
}
|
}
|
||||||
|
|
|
@ -58,7 +58,7 @@ void OpenGLTerrain::initialize()
|
||||||
program->addFragmentSource("terrain");
|
program->addFragmentSource("terrain");
|
||||||
|
|
||||||
// Add terrain chunks
|
// Add terrain chunks
|
||||||
int chunks = 20;
|
int chunks = 12;
|
||||||
double size = 800.0;
|
double size = 800.0;
|
||||||
double chunksize = size / (double) chunks;
|
double chunksize = size / (double) chunks;
|
||||||
double start = -size / 2.0;
|
double start = -size / 2.0;
|
||||||
|
|
Loading…
Reference in a new issue