Skip to content

Commit

Permalink
Prevent AOS circles from clipping with earth
Browse files Browse the repository at this point in the history
  • Loading branch information
arf20 committed Oct 10, 2022
1 parent 91cc2c7 commit 69d3c3b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions representation/graphics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -227,8 +227,8 @@ void render3d() {
xyz_t geo = sat.geo;
geo.height = 0.0f;
xyz_t u_lat = uLat(geo); xyz_t u_lon = uLon(geo); xyz_t u_vert = uVert(geo);
float circler = EARTHR * sin(TORAD * sat.aosRadiusAngle);
float circlec = EARTHR * cos(TORAD * sat.aosRadiusAngle);
float circler = (EARTHR + 5.0f) * sin(TORAD * sat.aosRadiusAngle);
float circlec = (EARTHR + 5.0f) * cos(TORAD * sat.aosRadiusAngle); // draw circles 5km above sea level and +5km radius to prevent clipping
xyz_t P = u_vert * circlec;

float finestep = 5.0f;
Expand Down

0 comments on commit 69d3c3b

Please sign in to comment.