GeoreferenceInternalStructures.h 958 B

1234567891011121314151617181920212223242526272829
  1. /*
  2. * Copyright (c) Contributors to the Open 3D Engine Project.
  3. * For complete copyright and license terms please see the LICENSE at the root
  4. * of this distribution.
  5. *
  6. * SPDX-License-Identifier: Apache-2.0 OR MIT
  7. *
  8. */
  9. #pragma once
  10. #include <AzCore/Math/Vector3.h>
  11. namespace Georeferencing::WGS
  12. {
  13. //! Vector3d is a 3D vector with double precision.
  14. //! It is used to represent coordinates in ECEF or ENU coordinate systems.
  15. struct Vector3d
  16. {
  17. Vector3d() = default;
  18. Vector3d(double x, double y, double z);
  19. explicit Vector3d(const AZ::Vector3& xyz);
  20. [[nodiscard]] AZ::Vector3 ToVector3f() const;
  21. Vector3d operator+(Vector3d const& v) const;
  22. Vector3d operator-(Vector3d const& v) const;
  23. double m_x = 0.0; //!< X coordinate in meters.
  24. double m_y = 0.0; //! Y coordinate in meters.
  25. double m_z = 0.0; //! Z coordinate in meters.
  26. };
  27. } // namespace Georeferencing::WGS