OSDN Git Service

航路保存機能試作。
[gvonavish/GVONavish.git] / GVONavish / GVONavish / GVONormalizedPoint.h
1 #pragma once
2
3 class GVONormalizedPoint {
4 private:
5         float m_x;
6         float m_y;
7
8 public:
9         GVONormalizedPoint() :
10                 m_x(),
11                 m_y()
12         {
13         }
14         GVONormalizedPoint(float x, float y) :
15                 m_x( x ),
16                 m_y( y )
17         {
18         }
19
20         bool isEqualValue( const GVONormalizedPoint rhs ) const
21         {
22                 return m_x == rhs.m_x && m_y == rhs.m_y;
23         }
24
25         float x() const
26         {
27                 return m_x;
28         }
29
30         float y() const
31         {
32                 return m_y;
33         }
34
35 };
36
37 // \83t\83@\83C\83\8b\93ü\8fo\97Í\97p\82É\83A\83\89\83C\83\81\83\93\83g\8am\94F
38 static_assert(sizeof(GVONormalizedPoint) == (sizeof(float)*2), "bat size.");