Optimaze with new mbed os for study
Dependencies: TS_DISCO_F746NG BSP_DISCO_F746NG Graphics
Diff: RadarDemo/Location.h
- Revision:
- 0:d8b9955d2b36
- Child:
- 1:5e49b46de1b0
diff -r 000000000000 -r d8b9955d2b36 RadarDemo/Location.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/RadarDemo/Location.h Fri Nov 04 01:02:37 2016 +0000 @@ -0,0 +1,48 @@ +// +// Location.h +// + +#pragma once + +class Location +{ +public: + Location(); + Location(float x, float y, float height); + + /// <summary> + /// Sets the location. + /// </summary> + /// <param name="x">The x position win world coordinates in [km].</param> + /// <param name="y">The y position win world coordinates in [km].</param> + /// <param name="height">Target height in [km].</param> + void SetLocation(float x, float y, float height); + + /// <summary> + /// Sets the location angular. + /// </summary> + /// <param name="distance">The distance.</param> + /// <param name="azimuth">The azimuth.</param> + /// <param name="elevation">The elevation.</param> + void SetLocationAngular(float distance, float azimuth, float elevation); + + float GetX(); + float GetY(); + float GetHeight(); + + float GetDistance(); + float GetAzimuth(); + float GetElevation(); + + void ToAngular(); + void ToCartesian(); + +private: + float _x; + float _y; + float _h; + float _distance; + float _azimuth; + float _elevation; +}; +