Closed yakra closed 5 years ago
URLs & other strings Examine deleting waypoint URLs (and using string::shrink_to_fit) once parsed to conserve RAM, if needed. This would probably require a significant amount of CPU time. Only do it if RAM use is a BIG problem. Similarly, labels. Vectors can shrink_to_fit too...
WRT the OP, float is not enough for 6 decimal places, rather, enough for 6 sig figs; double is in fact required. Closing for housekeeping purposes; I can always come back to URLs if need be.
tmtools_waypoint_slim
Ditching the gisplunge-only variables, and changing latitude & longitude from double to float (sufficient precision for 6 decimal places) would save 56 bytes per waypoint. * 500k waypoints ~= 28 MB. Hm. Putting it that way, that's a drop in the bucket. It may not be worth maintaining two versions of multiple files (waypoint.cpp, highway.cpp) or complicating things with a bunch of preprocessor definitions & ifdefs.