From c1234c1c2d0abbce8c11e44f72cd323076fa6b58 Mon Sep 17 00:00:00 2001 From: scttgs0 Date: Sun, 31 Mar 2024 21:34:31 -0500 Subject: [PATCH] maintenance: clean up --- src/BuildTiles/Main/tgconstruct_elevation.cxx | 2 +- src/BuildTiles/Main/tgconstruct_math.cxx | 2 +- src/BuildTiles/Main/tglandclass.cxx | 4 ++-- src/BuildTiles/Parallel/client.cxx | 6 ++---- src/BuildTiles/Parallel/server.cxx | 1 - src/Lib/Array/rectify_height.cxx | 1 - src/Lib/Array/testarray.cxx | 1 - src/Lib/terragear/TNT/tnt_math_utils.h | 1 - src/Lib/terragear/clipper.cpp | 7 +++---- src/Lib/terragear/tg_polygon.cxx | 1 - 10 files changed, 9 insertions(+), 17 deletions(-) diff --git a/src/BuildTiles/Main/tgconstruct_elevation.cxx b/src/BuildTiles/Main/tgconstruct_elevation.cxx index 1c884ff6..86737cc5 100644 --- a/src/BuildTiles/Main/tgconstruct_elevation.cxx +++ b/src/BuildTiles/Main/tgconstruct_elevation.cxx @@ -67,7 +67,7 @@ void TGConstruct::LoadElevationArray(bool add_nodes) // fix the elevations of the geodetic nodes // This should be done in the nodes class itself, except for the need for the triangle type -// hopefully, this will get better when we have the area lookup via superpoly... +// hopefully, this will get better when we have the area lookup via super-poly... void TGConstruct::CalcElevations(void) { std::vector raw_nodes; diff --git a/src/BuildTiles/Main/tgconstruct_math.cxx b/src/BuildTiles/Main/tgconstruct_math.cxx index 50436518..9f57a244 100644 --- a/src/BuildTiles/Main/tgconstruct_math.cxx +++ b/src/BuildTiles/Main/tgconstruct_math.cxx @@ -69,7 +69,7 @@ SGVec3f TGConstruct::calc_normal(double area, const SGVec3d& p1, const SGVec3d& void TGConstruct::calc_normals(std::vector& geod_nodes, std::vector& wgs84_nodes, tgPolygon& poly) { - // for each face in the superpoly, calculate a face normal + // for each face in the super-poly, calculate a face normal SGVec3f normal; for (unsigned int tri = 0; tri < poly.Triangles(); tri++) { diff --git a/src/BuildTiles/Main/tglandclass.cxx b/src/BuildTiles/Main/tglandclass.cxx index 475d63fe..ca31c8fc 100644 --- a/src/BuildTiles/Main/tglandclass.cxx +++ b/src/BuildTiles/Main/tglandclass.cxx @@ -1,9 +1,9 @@ -// TGLandclass.cxx -- Class toSimnplify dealing with shape heiarchy: +// TGLandclass.cxx -- Class to simplify dealing with shape heirarchy: // landclass contains each area (layer) of a tile // Each area is a list of shapes // A shape has 1 or more segments // (when the shape represents line data) -// And the segment is a superpoly, containing +// And the segment is a super-poly, containing // - a polygon, triangulation, point normals, face normals, etc. // // Written by Curtis Olson, started May 1999. diff --git a/src/BuildTiles/Parallel/client.cxx b/src/BuildTiles/Parallel/client.cxx index 24b1938a..fad623d0 100644 --- a/src/BuildTiles/Parallel/client.cxx +++ b/src/BuildTiles/Parallel/client.cxx @@ -23,7 +23,6 @@ # include # include # include -# include // bcopy() on Irix #endif #include #include @@ -33,7 +32,6 @@ #include #include // atoi() -#include // bcopy(), sterror() #include @@ -255,7 +253,7 @@ static bool must_generate( const SGBucket& b ) { } -// build the specified tile, return true if contruction completed +// build the specified tile, return true if construction completed // successfully bool construct_tile( const SGBucket& b, const string& result_file, @@ -418,7 +416,7 @@ int main(int argc, char *argv[]) { // check if the master switch is on check_master_switch(); - // niceness policy: This whole process should run niced. But + // niceness policy: This whole process should run nicely. But // additionally, if there is interactive use, we will sleep // for 60 seconds between each tile to stagger out the load // and impose less of an impact on the machine. diff --git a/src/BuildTiles/Parallel/server.cxx b/src/BuildTiles/Parallel/server.cxx index 9ed50efa..01d3f1a6 100644 --- a/src/BuildTiles/Parallel/server.cxx +++ b/src/BuildTiles/Parallel/server.cxx @@ -12,7 +12,6 @@ #include #include -#include #ifdef _MSC_VER # include typedef int socklen_t; diff --git a/src/Lib/Array/rectify_height.cxx b/src/Lib/Array/rectify_height.cxx index 6c26220c..635bc194 100644 --- a/src/Lib/Array/rectify_height.cxx +++ b/src/Lib/Array/rectify_height.cxx @@ -31,7 +31,6 @@ #include #include -#include #include #include "array.hxx" diff --git a/src/Lib/Array/testarray.cxx b/src/Lib/Array/testarray.cxx index d544ef26..8f59272d 100644 --- a/src/Lib/Array/testarray.cxx +++ b/src/Lib/Array/testarray.cxx @@ -11,7 +11,6 @@ #include #include -#include #include #include "array.hxx" diff --git a/src/Lib/terragear/TNT/tnt_math_utils.h b/src/Lib/terragear/TNT/tnt_math_utils.h index 4d81950f..444c7623 100644 --- a/src/Lib/terragear/TNT/tnt_math_utils.h +++ b/src/Lib/terragear/TNT/tnt_math_utils.h @@ -10,7 +10,6 @@ namespace TNT { -using namespace std; /** @returns hypotenuse of real (non-complex) scalars a and b by avoiding underflow/overflow diff --git a/src/Lib/terragear/clipper.cpp b/src/Lib/terragear/clipper.cpp index fa8cad96..46f64bae 100644 --- a/src/Lib/terragear/clipper.cpp +++ b/src/Lib/terragear/clipper.cpp @@ -1636,7 +1636,7 @@ bool Clipper::ExecuteInternal() void Clipper::SetWindingCount(TEdge &edge) { TEdge *e = edge.PrevInAEL; - //find the edge of the same polytype that immediately preceeds 'edge' in AEL + //find the edge of the same polytype that immediately precedes 'edge' in AEL while (e && ((e->PolyTyp != edge.PolyTyp) || (e->WindDelta == 0))) e = e->PrevInAEL; if (!e) { @@ -2691,7 +2691,7 @@ void Clipper::ProcessHorizontal(TEdge *horzEdge) { //this code block inserts extra coords into horizontal edges (in output - //polygons) whereever maxima touch these horizontal edges. This helps + //polygons) wherever maxima touch these horizontal edges. This helps //'simplifying' polygons (ie if the Simplify property is set). if (m_Maxima.size() > 0) { @@ -3546,7 +3546,7 @@ bool Clipper::JoinPoints(Join *j, OutRec* outRec1, OutRec* outRec2) if (op2b->Next == op2 || op2b->Next == op1) return false; //a flat 'polygon' cInt Left, Right; - //Op1 --> Op1b & Op2 --> Op2b are the extremites of the horizontal edges + //Op1 --> Op1b & Op2 --> Op2b are the extremities of the horizontal edges if (!GetOverlap(op1->Pt.X, op1b->Pt.X, op2->Pt.X, op2b->Pt.X, Left, Right)) return false; @@ -4136,7 +4136,6 @@ void ClipperOffset::DoOffset(double delta) } else { - k = 1; m_sinA = 0; if (node.m_endtype == EndType::OpenSquare) DoSquare(0, 1); diff --git a/src/Lib/terragear/tg_polygon.cxx b/src/Lib/terragear/tg_polygon.cxx index dbc94e71..37f06bd0 100644 --- a/src/Lib/terragear/tg_polygon.cxx +++ b/src/Lib/terragear/tg_polygon.cxx @@ -175,7 +175,6 @@ SGGeod InterpolateElevation( const SGGeod& dst_node, const SGGeod& start, const return SGGeod::fromDegM( dst_node.getLongitudeDeg(), dst_node.getLatitudeDeg(), dest_elevation ); } - void tgPolygon::InheritElevations( const tgPolygon& source ) { UniqueSGGeodSet src_nodes;