mirror of
https://github.com/overte-org/overte.git
synced 2025-04-21 17:03:58 +02:00
fault tolerance when 'render' is called prior to loading
This commit is contained in:
parent
0a2cd9537b
commit
ecddf9aa76
1 changed files with 2 additions and 2 deletions
|
@ -203,7 +203,6 @@ namespace
|
|||
|
||||
unsigned getTileIndex(float azimuth, float altitude) const
|
||||
{
|
||||
unsigned result;
|
||||
return discreteAngle(azimuth) % val_k +
|
||||
discreteAngle(altitude + Unit::half_pi()) * val_k;
|
||||
}
|
||||
|
@ -956,7 +955,8 @@ struct Stars::body
|
|||
float new_brightness = val_lod_brightness; // make atomic
|
||||
|
||||
// have it render
|
||||
renderer->render(fov, new_brightness);
|
||||
if (renderer)
|
||||
renderer->render(fov, new_brightness);
|
||||
|
||||
// check in - or dispose if there is a new one
|
||||
// TODO make atomic (CAS)
|
||||
|
|
Loading…
Reference in a new issue