FLImaging 7.7.23.4
TPoint.h
1#pragma once
2
10
11#include <stdint.h>
12#include <type_traits>
13#include <typeinfo>
14
15#include "FLLibTags.h"
16
18namespace FLImaging
19{
21 namespace Base
22 {
34 #pragma pack(push, 1)
35 template <typename T>
36 class FL_EXPORT TPoint
37 {
38 public:
43 T x;
44
49 T y;
50
59 {
60 }
61
71 TPoint(const TPoint<int8_t>& tp) : x((T)tp.x), y((T)tp.y)
72 {
73 }
74
84 TPoint(const TPoint<int8_t>* pTp) : x((T)pTp->x), y((T)pTp->y)
85 {
86 }
87
97 TPoint(const TPoint<uint8_t>& tp) : x((T)tp.x), y((T)tp.y)
98 {
99 }
100
110 TPoint(const TPoint<uint8_t>* pTp) : x((T)pTp->x), y((T)pTp->y)
111 {
112 }
113
123 TPoint(const TPoint<int16_t>& tp) : x((T)tp.x), y((T)tp.y)
124 {
125 }
126
136 TPoint(const TPoint<int16_t>* pTp) : x((T)pTp->x), y((T)pTp->y)
137 {
138 }
139
149 TPoint(const TPoint<uint16_t>& tp) : x((T)tp.x), y((T)tp.y)
150 {
151 }
152
162 TPoint(const TPoint<uint16_t>* pTp) : x((T)pTp->x), y((T)pTp->y)
163 {
164 }
165
175 TPoint(const TPoint<int32_t>& tp) : x((T)tp.x), y((T)tp.y)
176 {
177 }
178
188 TPoint(const TPoint<int32_t>* pTp) : x((T)pTp->x), y((T)pTp->y)
189 {
190 }
191
201 TPoint(const TPoint<uint32_t>& tp) : x((T)tp.x), y((T)tp.y)
202 {
203 }
204
214 TPoint(const TPoint<uint32_t>* pTp) : x((T)pTp->x), y((T)pTp->y)
215 {
216 }
217
227 TPoint(const TPoint<int64_t>& tp) : x((T)tp.x), y((T)tp.y)
228 {
229 }
230
240 TPoint(const TPoint<int64_t>* pTp) : x((T)pTp->x), y((T)pTp->y)
241 {
242 }
243
253 TPoint(const TPoint<uint64_t>& tp) : x((T)tp.x), y((T)tp.y)
254 {
255 }
256
266 TPoint(const TPoint<uint64_t>* pTp) : x((T)pTp->x), y((T)pTp->y)
267 {
268 }
269
279 TPoint(const TPoint<float>& tp) : x((T)tp.x), y((T)tp.y)
280 {
281 }
282
292 TPoint(const TPoint<float>* pTp) : x((T)pTp->x), y((T)pTp->y)
293 {
294 }
295
305 TPoint(const TPoint<double>& tp) : x((T)tp.x), y((T)tp.y)
306 {
307 }
308
318 TPoint(const TPoint<double>* pTp) : x((T)pTp->x), y((T)pTp->y)
319 {
320 }
321
322
334 TPoint(int8_t x, int8_t y) : x((T)x), y((T)y)
335 {
336 }
337
349 TPoint(uint8_t x, uint8_t y) : x((T)x), y((T)y)
350 {
351 }
352
364 TPoint(int16_t x, int16_t y) : x((T)x), y((T)y)
365 {
366 }
367
379 TPoint(uint16_t x, uint16_t y) : x((T)x), y((T)y)
380 {
381 }
382
394 TPoint(int32_t x, int32_t y) : x((T)x), y((T)y)
395 {
396 }
397
409 TPoint(uint32_t x, uint32_t y) : x((T)x), y((T)y)
410 {
411 }
412
424 TPoint(int64_t x, int64_t y) : x((T)x), y((T)y)
425 {
426 }
427
439 TPoint(uint64_t x, uint64_t y) : x((T)x), y((T)y)
440 {
441 }
442
454 TPoint(float x, float y) : x((T)x), y((T)y)
455 {
456 }
457
469 TPoint(double x, double y) : x((T)x), y((T)y)
470 {
471 }
472
482 void Set(const TPoint<int8_t>& tp)
483 {
484 x = (T)tp.x;
485 y = (T)tp.y;
486 }
487
497 void Set(const TPoint<int8_t>* pTp)
498 {
499 x = (T)pTp->x;
500 y = (T)pTp->y;
501 }
502
512 void Set(const TPoint<uint8_t>& tp)
513 {
514 x = (T)tp.x;
515 y = (T)tp.y;
516 }
517
527 void Set(const TPoint<uint8_t>* pTp)
528 {
529 x = (T)pTp->x;
530 y = (T)pTp->y;
531 }
532
542 void Set(const TPoint<int16_t>& tp)
543 {
544 x = (T)tp.x;
545 y = (T)tp.y;
546 }
547
557 void Set(const TPoint<int16_t>* pTp)
558 {
559 x = (T)pTp->x;
560 y = (T)pTp->y;
561 }
562
572 void Set(const TPoint<uint16_t>& tp)
573 {
574 x = (T)tp.x;
575 y = (T)tp.y;
576 }
577
587 void Set(const TPoint<uint16_t>* pTp)
588 {
589 x = (T)pTp->x;
590 y = (T)pTp->y;
591 }
592
602 void Set(const TPoint<int32_t>& tp)
603 {
604 x = (T)tp.x;
605 y = (T)tp.y;
606 }
607
617 void Set(const TPoint<int32_t>* pTp)
618 {
619 x = (T)pTp->x;
620 y = (T)pTp->y;
621 }
622
632 void Set(const TPoint<uint32_t>& tp)
633 {
634 x = (T)tp.x;
635 y = (T)tp.y;
636 }
637
647 void Set(const TPoint<uint32_t>* pTp)
648 {
649 x = (T)pTp->x;
650 y = (T)pTp->y;
651 }
652
662 void Set(const TPoint<int64_t>& tp)
663 {
664 x = (T)tp.x;
665 y = (T)tp.y;
666 }
667
677 void Set(const TPoint<int64_t>* pTp)
678 {
679 x = (T)pTp->x;
680 y = (T)pTp->y;
681 }
682
692 void Set(const TPoint<uint64_t>& tp)
693 {
694 x = (T)tp.x;
695 y = (T)tp.y;
696 }
697
707 void Set(const TPoint<uint64_t>* pTp)
708 {
709 x = (T)pTp->x;
710 y = (T)pTp->y;
711 }
712
722 void Set(const TPoint<float>& tp)
723 {
724 x = (T)tp.x;
725 y = (T)tp.y;
726 }
727
737 void Set(const TPoint<float>* pTp)
738 {
739 x = (T)pTp->x;
740 y = (T)pTp->y;
741 }
742
752 void Set(const TPoint<double>& tp)
753 {
754 x = (T)tp.x;
755 y = (T)tp.y;
756 }
757
767 void Set(const TPoint<double>* pTp)
768 {
769 x = (T)pTp->x;
770 y = (T)pTp->y;
771 }
772
784 void Set(int8_t x, int8_t y)
785 {
786 this->x = (T)x;
787 this->y = (T)y;
788 }
789
801 void Set(uint8_t x, uint8_t y)
802 {
803 this->x = (T)x;
804 this->y = (T)y;
805 }
806
818 void Set(int16_t x, int16_t y)
819 {
820 this->x = (T)x;
821 this->y = (T)y;
822 }
823
835 void Set(uint16_t x, uint16_t y)
836 {
837 this->x = (T)x;
838 this->y = (T)y;
839 }
840
852 void Set(int32_t x, int32_t y)
853 {
854 this->x = (T)x;
855 this->y = (T)y;
856 }
857
869 void Set(uint32_t x, uint32_t y)
870 {
871 this->x = (T)x;
872 this->y = (T)y;
873 }
874
886 void Set(int64_t x, int64_t y)
887 {
888 this->x = (T)x;
889 this->y = (T)y;
890 }
891
903 void Set(uint64_t x, uint64_t y)
904 {
905 this->x = (T)x;
906 this->y = (T)y;
907 }
908
920 void Set(float x, float y)
921 {
922 this->x = (T)x;
923 this->y = (T)y;
924 }
925
937 void Set(double x, double y)
938 {
939 this->x = (T)x;
940 this->y = (T)y;
941 }
942
954 const TPoint<T>& operator=(int32_t value)
955 {
956 x = y = (T)value;
957
958 return *this;
959 }
960
972 const TPoint<T>& operator=(int64_t value)
973 {
974 x = y = (T)value;
975
976 return *this;
977 }
978
990 const TPoint<T>& operator=(float value)
991 {
992 x = y = (T)value;
993
994 return *this;
995 }
996
1008 const TPoint<T>& operator=(double value)
1009 {
1010 x = y = (T)value;
1011
1012 return *this;
1013 }
1014
1027 {
1028 x = (T)tp.x;
1029 y = (T)tp.y;
1030
1031 return *this;
1032 }
1033
1046 {
1047 x = (T)tp.x;
1048 y = (T)tp.y;
1049
1050 return *this;
1051 }
1052
1065 {
1066 x = (T)tp.x;
1067 y = (T)tp.y;
1068
1069 return *this;
1070 }
1071
1084 {
1085 x = (T)tp.x;
1086 y = (T)tp.y;
1087
1088 return *this;
1089 }
1090
1102 bool operator==(const TPoint<int32_t>& tp) const
1103 {
1104 return x == (T)tp.x && y == (T)tp.y;
1105 }
1106
1118 bool operator==(const TPoint<int64_t>& tp) const
1119 {
1120 return x == (T)tp.x && y == (T)tp.y;
1121 }
1122
1134 bool operator==(const TPoint<float>& tp) const
1135 {
1136 return x == (T)tp.x && y == (T)tp.y;
1137 }
1138
1150 bool operator==(const TPoint<double>& tp) const
1151 {
1152 return x == (T)tp.x && y == (T)tp.y;
1153 }
1154
1166 bool operator!=(const TPoint<int32_t>& tp) const
1167 {
1168 return x != (T)tp.x || y != (T)tp.y;
1169 }
1170
1182 bool operator!=(const TPoint<int64_t>& tp) const
1183 {
1184 return x != (T)tp.x || y != (T)tp.y;
1185 }
1186
1198 bool operator!=(const TPoint<float>& tp) const
1199 {
1200 return x != (T)tp.x || y != (T)tp.y;
1201 }
1202
1214 bool operator!=(const TPoint<double>& tp) const
1215 {
1216 return x != (T)tp.x || y != (T)tp.y;
1217 }
1218
1230 const TPoint<T>& operator+=(int32_t value)
1231 {
1232 x += (T)value;
1233 y += (T)value;
1234
1235 return *this;
1236 }
1237
1249 const TPoint<T>& operator+=(int64_t value)
1250 {
1251 x += (T)value;
1252 y += (T)value;
1253
1254 return *this;
1255 }
1256
1268 const TPoint<T>& operator+=(float value)
1269 {
1270 x += (T)value;
1271 y += (T)value;
1272
1273 return *this;
1274 }
1275
1287 const TPoint<T>& operator+=(double value)
1288 {
1289 x += (T)value;
1290 y += (T)value;
1291
1292 return *this;
1293 }
1294
1307 {
1308 x += (T)tp.x;
1309 y += (T)tp.y;
1310
1311 return *this;
1312 }
1313
1326 {
1327 x += (T)tp.x;
1328 y += (T)tp.y;
1329
1330 return *this;
1331 }
1332
1345 {
1346 x += (T)tp.x;
1347 y += (T)tp.y;
1348
1349 return *this;
1350 }
1351
1364 {
1365 x += (T)tp.x;
1366 y += (T)tp.y;
1367
1368 return *this;
1369 }
1370
1382 const TPoint<T>& operator-=(int32_t value)
1383 {
1384 x -= (T)value;
1385 y -= (T)value;
1386
1387 return *this;
1388 }
1389
1401 const TPoint<T>& operator-=(int64_t value)
1402 {
1403 x -= (T)value;
1404 y -= (T)value;
1405
1406 return *this;
1407 }
1408
1420 const TPoint<T>& operator-=(float value)
1421 {
1422 x -= (T)value;
1423 y -= (T)value;
1424
1425 return *this;
1426 }
1427
1439 const TPoint<T>& operator-=(double value)
1440 {
1441 x -= (T)value;
1442 y -= (T)value;
1443
1444 return *this;
1445 }
1446
1459 {
1460 x -= (T)tp.x;
1461 y -= (T)tp.y;
1462
1463 return *this;
1464 }
1465
1478 {
1479 x -= (T)tp.x;
1480 y -= (T)tp.y;
1481
1482 return *this;
1483 }
1484
1497 {
1498 x -= (T)tp.x;
1499 y -= (T)tp.y;
1500
1501 return *this;
1502 }
1503
1516 {
1517 x -= (T)tp.x;
1518 y -= (T)tp.y;
1519
1520 return *this;
1521 }
1522
1534 const TPoint<T>& operator*=(int32_t value)
1535 {
1536 x *= (T)value;
1537 y *= (T)value;
1538
1539 return *this;
1540 }
1541
1553 const TPoint<T>& operator*=(int64_t value)
1554 {
1555 x *= (T)value;
1556 y *= (T)value;
1557
1558 return *this;
1559 }
1560
1572 const TPoint<T>& operator*=(float value)
1573 {
1574 x *= (T)value;
1575 y *= (T)value;
1576
1577 return *this;
1578 }
1579
1591 const TPoint<T>& operator*=(double value)
1592 {
1593 x *= (T)value;
1594 y *= (T)value;
1595
1596 return *this;
1597 }
1598
1611 {
1612 x *= (T)tp.x;
1613 y *= (T)tp.y;
1614
1615 return *this;
1616 }
1617
1630 {
1631 x *= (T)tp.x;
1632 y *= (T)tp.y;
1633
1634 return *this;
1635 }
1636
1649 {
1650 x *= (T)tp.x;
1651 y *= (T)tp.y;
1652
1653 return *this;
1654 }
1655
1668 {
1669 x *= (T)tp.x;
1670 y *= (T)tp.y;
1671
1672 return *this;
1673 }
1674
1686 const TPoint<T>& operator/=(int32_t value)
1687 {
1688 x /= (T)value;
1689 y /= (T)value;
1690
1691 return *this;
1692 }
1693
1705 const TPoint<T>& operator/=(int64_t value)
1706 {
1707 x /= (T)value;
1708 y /= (T)value;
1709
1710 return *this;
1711 }
1712
1724 const TPoint<T>& operator/=(float value)
1725 {
1726 x /= (T)value;
1727 y /= (T)value;
1728
1729 return *this;
1730 }
1731
1743 const TPoint<T>& operator/=(double value)
1744 {
1745 x /= (T)value;
1746 y /= (T)value;
1747
1748 return *this;
1749 }
1750
1763 {
1764 x /= (T)tp.x;
1765 y /= (T)tp.y;
1766
1767 return *this;
1768 }
1769
1782 {
1783 x /= (T)tp.x;
1784 y /= (T)tp.y;
1785
1786 return *this;
1787 }
1788
1801 {
1802 x /= (T)tp.x;
1803 y /= (T)tp.y;
1804
1805 return *this;
1806 }
1807
1820 {
1821 x /= (T)tp.x;
1822 y /= (T)tp.y;
1823
1824 return *this;
1825 }
1826
1838 TPoint<T> operator+(int32_t value) const
1839 {
1840 TPoint<T> tpReturn;
1841 tpReturn.x = x + (T)value;
1842 tpReturn.y = y + (T)value;
1843 return tpReturn;
1844 }
1845
1857 TPoint<T> operator+(int64_t value) const
1858 {
1859 TPoint<T> tpReturn;
1860 tpReturn.x = x + (T)value;
1861 tpReturn.y = y + (T)value;
1862 return tpReturn;
1863 }
1864
1876 TPoint<T> operator+(float value) const
1877 {
1878 TPoint<T> tpReturn;
1879 tpReturn.x = x + (T)value;
1880 tpReturn.y = y + (T)value;
1881 return tpReturn;
1882 }
1883
1895 TPoint<T> operator+(double value) const
1896 {
1897 TPoint<T> tpReturn;
1898 tpReturn.x = x + (T)value;
1899 tpReturn.y = y + (T)value;
1900 return tpReturn;
1901 }
1902
1915 {
1916 TPoint<T> tpReturn;
1917 tpReturn.x = x + (T)tp.x;
1918 tpReturn.y = y + (T)tp.y;
1919 return tpReturn;
1920 }
1921
1934 {
1935 TPoint<T> tpReturn;
1936 tpReturn.x = x + (T)tp.x;
1937 tpReturn.y = y + (T)tp.y;
1938 return tpReturn;
1939 }
1940
1953 {
1954 TPoint<T> tpReturn;
1955 tpReturn.x = x + (T)tp.x;
1956 tpReturn.y = y + (T)tp.y;
1957 return tpReturn;
1958 }
1959
1972 {
1973 TPoint<T> tpReturn;
1974 tpReturn.x = x + (T)tp.x;
1975 tpReturn.y = y + (T)tp.y;
1976 return tpReturn;
1977 }
1978
1990 TPoint<T> operator-(int32_t value) const
1991 {
1992 TPoint<T> tpReturn;
1993 tpReturn.x = x - (T)value;
1994 tpReturn.y = y - (T)value;
1995 return tpReturn;
1996 }
1997
2009 TPoint<T> operator-(int64_t value) const
2010 {
2011 TPoint<T> tpReturn;
2012 tpReturn.x = x - (T)value;
2013 tpReturn.y = y - (T)value;
2014 return tpReturn;
2015 }
2016
2028 TPoint<T> operator-(float value) const
2029 {
2030 TPoint<T> tpReturn;
2031 tpReturn.x = x - (T)value;
2032 tpReturn.y = y - (T)value;
2033 return tpReturn;
2034 }
2035
2047 TPoint<T> operator-(double value) const
2048 {
2049 TPoint<T> tpReturn;
2050 tpReturn.x = x - (T)value;
2051 tpReturn.y = y - (T)value;
2052 return tpReturn;
2053 }
2054
2067 {
2068 TPoint<T> tpReturn;
2069 tpReturn.x = x - (T)tp.x;
2070 tpReturn.y = y - (T)tp.y;
2071 return tpReturn;
2072 }
2073
2086 {
2087 TPoint<T> tpReturn;
2088 tpReturn.x = x - (T)tp.x;
2089 tpReturn.y = y - (T)tp.y;
2090 return tpReturn;
2091 }
2092
2105 {
2106 TPoint<T> tpReturn;
2107 tpReturn.x = x - (T)tp.x;
2108 tpReturn.y = y - (T)tp.y;
2109 return tpReturn;
2110 }
2111
2124 {
2125 TPoint<T> tpReturn;
2126 tpReturn.x = x - (T)tp.x;
2127 tpReturn.y = y - (T)tp.y;
2128 return tpReturn;
2129 }
2130
2142 TPoint<T> operator*(int32_t value) const
2143 {
2144 TPoint<T> tpReturn;
2145 tpReturn.x = x * (T)value;
2146 tpReturn.y = y * (T)value;
2147 return tpReturn;
2148 }
2149
2161 TPoint<T> operator*(int64_t value) const
2162 {
2163 TPoint<T> tpReturn;
2164 tpReturn.x = x * (T)value;
2165 tpReturn.y = y * (T)value;
2166 return tpReturn;
2167 }
2168
2180 TPoint<T> operator*(float value) const
2181 {
2182 TPoint<T> tpReturn;
2183 tpReturn.x = x * (T)value;
2184 tpReturn.y = y * (T)value;
2185 return tpReturn;
2186 }
2187
2199 TPoint<T> operator*(double value) const
2200 {
2201 TPoint<T> tpReturn;
2202 tpReturn.x = x * (T)value;
2203 tpReturn.y = y * (T)value;
2204 return tpReturn;
2205 }
2206
2219 {
2220 TPoint<T> tpReturn;
2221 tpReturn.x = x * (T)tp.x;
2222 tpReturn.y = y * (T)tp.y;
2223 return tpReturn;
2224 }
2225
2238 {
2239 TPoint<T> tpReturn;
2240 tpReturn.x = x * (T)tp.x;
2241 tpReturn.y = y * (T)tp.y;
2242 return tpReturn;
2243 }
2244
2257 {
2258 TPoint<T> tpReturn;
2259 tpReturn.x = x * (T)tp.x;
2260 tpReturn.y = y * (T)tp.y;
2261 return tpReturn;
2262 }
2263
2276 {
2277 TPoint<T> tpReturn;
2278 tpReturn.x = x * (T)tp.x;
2279 tpReturn.y = y * (T)tp.y;
2280 return tpReturn;
2281 }
2282
2294 TPoint<T> operator/(int32_t value) const
2295 {
2296 TPoint<T> tpReturn;
2297 tpReturn.x = x / (T)value;
2298 tpReturn.y = y / (T)value;
2299 return tpReturn;
2300 }
2301
2313 TPoint<T> operator/(int64_t value) const
2314 {
2315 TPoint<T> tpReturn;
2316 tpReturn.x = x / (T)value;
2317 tpReturn.y = y / (T)value;
2318 return tpReturn;
2319 }
2320
2332 TPoint<T> operator/(float value) const
2333 {
2334 TPoint<T> tpReturn;
2335 tpReturn.x = x / (T)value;
2336 tpReturn.y = y / (T)value;
2337 return tpReturn;
2338 }
2339
2351 TPoint<T> operator/(double value) const
2352 {
2353 TPoint<T> tpReturn;
2354 tpReturn.x = x / (T)value;
2355 tpReturn.y = y / (T)value;
2356 return tpReturn;
2357 }
2358
2371 {
2372 TPoint<T> tpReturn;
2373 tpReturn.x = x / (T)tp.x;
2374 tpReturn.y = y / (T)tp.y;
2375 return tpReturn;
2376 }
2377
2390 {
2391 TPoint<T> tpReturn;
2392 tpReturn.x = x / (T)tp.x;
2393 tpReturn.y = y / (T)tp.y;
2394 return tpReturn;
2395 }
2396
2409 {
2410 TPoint<T> tpReturn;
2411 tpReturn.x = x / (T)tp.x;
2412 tpReturn.y = y / (T)tp.y;
2413 return tpReturn;
2414 }
2415
2428 {
2429 TPoint<T> tpReturn;
2430 tpReturn.x = x / (T)tp.x;
2431 tpReturn.y = y / (T)tp.y;
2432 return tpReturn;
2433 }
2434
2448 friend TPoint<T> operator+(int32_t value, const TPoint<T>& tp)
2449 {
2450 return TPoint<T>((T)value + tp.x, (T)value + tp.y);
2451 }
2452
2466 friend TPoint<T> operator+(int64_t value, const TPoint<T>& tp)
2467 {
2468 return TPoint<T>((T)value + tp.x, (T)value + tp.y);
2469 }
2470
2484 friend TPoint<T> operator+(float value, const TPoint<T>& tp)
2485 {
2486 return TPoint<T>((T)value + tp.x, (T)value + tp.y);
2487 }
2488
2502 friend TPoint<T> operator+(double value, const TPoint<T>& tp)
2503 {
2504 return TPoint<T>((T)value + tp.x, (T)value + tp.y);
2505 }
2506
2520 friend TPoint<T> operator-(int32_t value, const TPoint<T>& tp)
2521 {
2522 return TPoint<T>((T)value - tp.x, (T)value - tp.y);
2523 }
2524
2538 friend TPoint<T> operator-(int64_t value, const TPoint<T>& tp)
2539 {
2540 return TPoint<T>((T)value - tp.x, (T)value - tp.y);
2541 }
2542
2556 friend TPoint<T> operator-(float value, const TPoint<T>& tp)
2557 {
2558 return TPoint<T>((T)value - tp.x, (T)value - tp.y);
2559 }
2560
2574 friend TPoint<T> operator-(double value, const TPoint<T>& tp)
2575 {
2576 return TPoint<T>((T)value - tp.x, (T)value - tp.y);
2577 }
2578
2592 friend TPoint<T> operator*(int32_t value, const TPoint<T>& tp)
2593 {
2594 return TPoint<T>((T)value * tp.x, (T)value * tp.y);
2595 }
2596
2610 friend TPoint<T> operator*(int64_t value, const TPoint<T>& tp)
2611 {
2612 return TPoint<T>((T)value * tp.x, (T)value * tp.y);
2613 }
2614
2628 friend TPoint<T> operator*(float value, const TPoint<T>& tp)
2629 {
2630 return TPoint<T>((T)value * tp.x, (T)value * tp.y);
2631 }
2632
2646 friend TPoint<T> operator*(double value, const TPoint<T>& tp)
2647 {
2648 return TPoint<T>((T)value * tp.x, (T)value * tp.y);
2649 }
2650
2664 friend TPoint<T> operator/(int32_t value, const TPoint<T>& tp)
2665 {
2666 return TPoint<T>((T)value / tp.x, (T)value / tp.y);
2667 }
2668
2682 friend TPoint<T> operator/(int64_t value, const TPoint<T>& tp)
2683 {
2684 return TPoint<T>((T)value / tp.x, (T)value / tp.y);
2685 }
2686
2700 friend TPoint<T> operator/(float value, const TPoint<T>& tp)
2701 {
2702 return TPoint<T>((T)value / tp.x, (T)value / tp.y);
2703 }
2704
2718 friend TPoint<T> operator/(double value, const TPoint<T>& tp)
2719 {
2720 return TPoint<T>((T)value / tp.x, (T)value / tp.y);
2721 }
2722 };
2723 #pragma pack(pop)
2724
2725 typedef TPoint<int8_t> TPointC;
2726 typedef TPoint<uint8_t> TPointUC;
2727 typedef TPoint<int16_t> TPointS;
2728 typedef TPoint<uint16_t> TPointUS;
2729 typedef TPoint<int32_t> TPointL;
2730 typedef TPoint<uint32_t> TPointUL;
2731 typedef TPoint<int64_t> TPointLL;
2732 typedef TPoint<uint64_t> TPointULL;
2733 typedef TPoint<float> TPointF;
2734 typedef TPoint<double> TPointD;
2735 }
2736}
const TPoint< T > & operator-=(int32_t value)
뺄셈 대입 연산자
Definition TPoint.h:1382
TPoint(const TPoint< double > &tp)
복사 생성자
Definition TPoint.h:305
void Set(const TPoint< int8_t > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:482
const TPoint< T > & operator=(double value)
대입 연산자
Definition TPoint.h:1008
TPoint< T > operator*(const TPoint< double > &tp) const
곱셈 연산자
Definition TPoint.h:2275
friend TPoint< T > operator+(int32_t value, const TPoint< T > &tp)
덧셈 연산자
Definition TPoint.h:2448
const TPoint< T > & operator-=(const TPoint< float > &tp)
뺄셈 대입 연산자
Definition TPoint.h:1496
TPoint< T > operator/(int64_t value) const
나눗셈 연산자
Definition TPoint.h:2313
void Set(const TPoint< float > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:737
const TPoint< T > & operator+=(double value)
덧셈 대입 연산자
Definition TPoint.h:1287
TPoint(float x, float y)
초기화 생성자
Definition TPoint.h:454
TPoint(int8_t x, int8_t y)
초기화 생성자
Definition TPoint.h:334
TPoint(int16_t x, int16_t y)
초기화 생성자
Definition TPoint.h:364
TPoint< T > operator*(double value) const
곱셈 연산자
Definition TPoint.h:2199
int8_t x
Definition TPoint.h:43
const TPoint< T > & operator-=(float value)
뺄셈 대입 연산자
Definition TPoint.h:1420
const TPoint< T > & operator*=(const TPoint< int32_t > &tp)
곱셈 대입 연산자
Definition TPoint.h:1610
bool operator!=(const TPoint< int64_t > &tp) const
부등 연산자
Definition TPoint.h:1182
const TPoint< T > & operator-=(const TPoint< int32_t > &tp)
뺄셈 대입 연산자
Definition TPoint.h:1458
const TPoint< T > & operator+=(const TPoint< float > &tp)
덧셈 대입 연산자
Definition TPoint.h:1344
void Set(uint16_t x, uint16_t y)
좌표를 설정합니다.
Definition TPoint.h:835
const TPoint< T > & operator=(int64_t value)
대입 연산자
Definition TPoint.h:972
void Set(uint64_t x, uint64_t y)
좌표를 설정합니다.
Definition TPoint.h:903
const TPoint< T > & operator+=(const TPoint< double > &tp)
덧셈 대입 연산자
Definition TPoint.h:1363
TPoint< T > operator*(int64_t value) const
곱셈 연산자
Definition TPoint.h:2161
friend TPoint< T > operator/(int32_t value, const TPoint< T > &tp)
나눗셈 연산자
Definition TPoint.h:2664
void Set(const TPoint< uint16_t > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:587
friend TPoint< T > operator-(int32_t value, const TPoint< T > &tp)
뺄셈 연산자
Definition TPoint.h:2520
TPoint< T > operator/(float value) const
나눗셈 연산자
Definition TPoint.h:2332
const TPoint< T > & operator=(const TPoint< float > &tp)
대입 연산자
Definition TPoint.h:1064
bool operator!=(const TPoint< float > &tp) const
부등 연산자
Definition TPoint.h:1198
friend TPoint< T > operator*(int32_t value, const TPoint< T > &tp)
곱셈 연산자
Definition TPoint.h:2592
const TPoint< T > & operator+=(const TPoint< int64_t > &tp)
덧셈 대입 연산자
Definition TPoint.h:1325
const TPoint< T > & operator*=(const TPoint< int64_t > &tp)
곱셈 대입 연산자
Definition TPoint.h:1629
bool operator==(const TPoint< double > &tp) const
동일성 연산자
Definition TPoint.h:1150
TPoint< T > operator-(float value) const
뺄셈 연산자
Definition TPoint.h:2028
TPoint< T > operator*(float value) const
곱셈 연산자
Definition TPoint.h:2180
friend TPoint< T > operator+(float value, const TPoint< T > &tp)
덧셈 연산자
Definition TPoint.h:2484
TPoint< T > operator-(int32_t value) const
뺄셈 연산자
Definition TPoint.h:1990
const TPoint< T > & operator-=(double value)
뺄셈 대입 연산자
Definition TPoint.h:1439
friend TPoint< T > operator*(float value, const TPoint< T > &tp)
곱셈 연산자
Definition TPoint.h:2628
friend TPoint< T > operator/(double value, const TPoint< T > &tp)
나눗셈 연산자
Definition TPoint.h:2718
TPoint< T > operator*(const TPoint< float > &tp) const
곱셈 연산자
Definition TPoint.h:2256
friend TPoint< T > operator+(int64_t value, const TPoint< T > &tp)
덧셈 연산자
Definition TPoint.h:2466
TPoint< T > operator*(const TPoint< int32_t > &tp) const
곱셈 연산자
Definition TPoint.h:2218
const TPoint< T > & operator/=(float value)
나눗셈 대입 연산자
Definition TPoint.h:1724
void Set(const TPoint< double > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:752
void Set(const TPoint< double > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:767
TPoint< T > operator+(double value) const
덧셈 연산자
Definition TPoint.h:1895
TPoint< T > operator-(const TPoint< double > &tp) const
뺄셈 연산자
Definition TPoint.h:2123
TPoint< T > operator/(int32_t value) const
나눗셈 연산자
Definition TPoint.h:2294
TPoint(uint32_t x, uint32_t y)
초기화 생성자
Definition TPoint.h:409
void Set(const TPoint< uint32_t > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:632
TPoint(const TPoint< uint32_t > &tp)
복사 생성자
Definition TPoint.h:201
TPoint(const TPoint< int16_t > *pTp)
복사 생성자
Definition TPoint.h:136
const TPoint< T > & operator/=(int32_t value)
나눗셈 대입 연산자
Definition TPoint.h:1686
void Set(const TPoint< float > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:722
TPoint< T > operator-(double value) const
뺄셈 연산자
Definition TPoint.h:2047
friend TPoint< T > operator/(int64_t value, const TPoint< T > &tp)
나눗셈 연산자
Definition TPoint.h:2682
const TPoint< T > & operator*=(double value)
곱셈 대입 연산자
Definition TPoint.h:1591
const TPoint< T > & operator=(const TPoint< int64_t > &tp)
대입 연산자
Definition TPoint.h:1045
const TPoint< T > & operator/=(const TPoint< float > &tp)
나눗셈 대입 연산자
Definition TPoint.h:1800
void Set(const TPoint< uint16_t > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:572
void Set(const TPoint< uint32_t > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:647
TPoint(const TPoint< uint32_t > *pTp)
복사 생성자
Definition TPoint.h:214
const TPoint< T > & operator-=(const TPoint< double > &tp)
뺄셈 대입 연산자
Definition TPoint.h:1515
bool operator==(const TPoint< float > &tp) const
동일성 연산자
Definition TPoint.h:1134
TPoint< T > operator+(const TPoint< int32_t > &tp) const
덧셈 연산자
Definition TPoint.h:1914
TPoint(const TPoint< int16_t > &tp)
복사 생성자
Definition TPoint.h:123
TPoint< T > operator/(const TPoint< double > &tp) const
나눗셈 연산자
Definition TPoint.h:2427
TPoint(const TPoint< float > &tp)
복사 생성자
Definition TPoint.h:279
TPoint(const TPoint< double > *pTp)
복사 생성자
Definition TPoint.h:318
TPoint(const TPoint< uint8_t > &tp)
복사 생성자
Definition TPoint.h:97
const TPoint< T > & operator=(const TPoint< int32_t > &tp)
대입 연산자
Definition TPoint.h:1026
const TPoint< T > & operator/=(const TPoint< double > &tp)
나눗셈 대입 연산자
Definition TPoint.h:1819
void Set(uint8_t x, uint8_t y)
좌표를 설정합니다.
Definition TPoint.h:801
TPoint(const TPoint< uint64_t > &tp)
복사 생성자
Definition TPoint.h:253
friend TPoint< T > operator*(double value, const TPoint< T > &tp)
곱셈 연산자
Definition TPoint.h:2646
void Set(const TPoint< int8_t > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:497
TPoint< T > operator/(const TPoint< int32_t > &tp) const
나눗셈 연산자
Definition TPoint.h:2370
TPoint(const TPoint< float > *pTp)
복사 생성자
Definition TPoint.h:292
TPoint(const TPoint< int64_t > &tp)
복사 생성자
Definition TPoint.h:227
int8_t y
Definition TPoint.h:49
const TPoint< T > & operator/=(const TPoint< int64_t > &tp)
나눗셈 대입 연산자
Definition TPoint.h:1781
TPoint(int32_t x, int32_t y)
초기화 생성자
Definition TPoint.h:394
const TPoint< T > & operator+=(const TPoint< int32_t > &tp)
덧셈 대입 연산자
Definition TPoint.h:1306
void Set(int16_t x, int16_t y)
좌표를 설정합니다.
Definition TPoint.h:818
void Set(const TPoint< uint8_t > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:512
TPoint(const TPoint< uint16_t > *pTp)
복사 생성자
Definition TPoint.h:162
const TPoint< T > & operator=(int32_t value)
대입 연산자
Definition TPoint.h:954
TPoint< T > operator-(const TPoint< int64_t > &tp) const
뺄셈 연산자
Definition TPoint.h:2085
const TPoint< T > & operator*=(const TPoint< float > &tp)
곱셈 대입 연산자
Definition TPoint.h:1648
TPoint(int64_t x, int64_t y)
초기화 생성자
Definition TPoint.h:424
friend TPoint< T > operator*(int64_t value, const TPoint< T > &tp)
곱셈 연산자
Definition TPoint.h:2610
TPoint(double x, double y)
초기화 생성자
Definition TPoint.h:469
TPoint(uint8_t x, uint8_t y)
초기화 생성자
Definition TPoint.h:349
TPoint< T > operator+(int64_t value) const
덧셈 연산자
Definition TPoint.h:1857
bool operator!=(const TPoint< double > &tp) const
부등 연산자
Definition TPoint.h:1214
void Set(int8_t x, int8_t y)
좌표를 설정합니다.
Definition TPoint.h:784
TPoint(const TPoint< int8_t > &tp)
복사 생성자
Definition TPoint.h:71
friend TPoint< T > operator/(float value, const TPoint< T > &tp)
나눗셈 연산자
Definition TPoint.h:2700
void Set(double x, double y)
좌표를 설정합니다.
Definition TPoint.h:937
TPoint< T > operator+(int32_t value) const
덧셈 연산자
Definition TPoint.h:1838
bool operator!=(const TPoint< int32_t > &tp) const
부등 연산자
Definition TPoint.h:1166
TPoint(const TPoint< int32_t > *pTp)
복사 생성자
Definition TPoint.h:188
TPoint< T > operator-(const TPoint< float > &tp) const
뺄셈 연산자
Definition TPoint.h:2104
void Set(const TPoint< uint64_t > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:707
void Set(int64_t x, int64_t y)
좌표를 설정합니다.
Definition TPoint.h:886
TPoint< T > operator+(const TPoint< double > &tp) const
덧셈 연산자
Definition TPoint.h:1971
const TPoint< T > & operator/=(double value)
나눗셈 대입 연산자
Definition TPoint.h:1743
void Set(const TPoint< uint64_t > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:692
TPoint(const TPoint< uint16_t > &tp)
복사 생성자
Definition TPoint.h:149
const TPoint< T > & operator*=(const TPoint< double > &tp)
곱셈 대입 연산자
Definition TPoint.h:1667
bool operator==(const TPoint< int32_t > &tp) const
동일성 연산자
Definition TPoint.h:1102
void Set(uint32_t x, uint32_t y)
좌표를 설정합니다.
Definition TPoint.h:869
TPoint< T > operator-(const TPoint< int32_t > &tp) const
뺄셈 연산자
Definition TPoint.h:2066
TPoint(const TPoint< uint8_t > *pTp)
복사 생성자
Definition TPoint.h:110
void Set(float x, float y)
좌표를 설정합니다.
Definition TPoint.h:920
TPoint(uint16_t x, uint16_t y)
초기화 생성자
Definition TPoint.h:379
friend TPoint< T > operator+(double value, const TPoint< T > &tp)
덧셈 연산자
Definition TPoint.h:2502
const TPoint< T > & operator+=(float value)
덧셈 대입 연산자
Definition TPoint.h:1268
friend TPoint< T > operator-(int64_t value, const TPoint< T > &tp)
뺄셈 연산자
Definition TPoint.h:2538
TPoint()
기본 생성자
Definition TPoint.h:58
TPoint(uint64_t x, uint64_t y)
초기화 생성자
Definition TPoint.h:439
TPoint(const TPoint< int32_t > &tp)
복사 생성자
Definition TPoint.h:175
const TPoint< T > & operator-=(int64_t value)
뺄셈 대입 연산자
Definition TPoint.h:1401
const TPoint< T > & operator=(const TPoint< double > &tp)
대입 연산자
Definition TPoint.h:1083
friend TPoint< T > operator-(float value, const TPoint< T > &tp)
뺄셈 연산자
Definition TPoint.h:2556
bool operator==(const TPoint< int64_t > &tp) const
동일성 연산자
Definition TPoint.h:1118
const TPoint< T > & operator+=(int64_t value)
덧셈 대입 연산자
Definition TPoint.h:1249
TPoint< T > operator*(const TPoint< int64_t > &tp) const
곱셈 연산자
Definition TPoint.h:2237
TPoint< T > operator+(float value) const
덧셈 연산자
Definition TPoint.h:1876
const TPoint< T > & operator*=(int64_t value)
곱셈 대입 연산자
Definition TPoint.h:1553
const TPoint< T > & operator/=(int64_t value)
나눗셈 대입 연산자
Definition TPoint.h:1705
void Set(const TPoint< int64_t > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:662
TPoint(const TPoint< int8_t > *pTp)
복사 생성자
Definition TPoint.h:84
TPoint(const TPoint< int64_t > *pTp)
복사 생성자
Definition TPoint.h:240
void Set(const TPoint< int16_t > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:542
TPoint< T > operator+(const TPoint< int64_t > &tp) const
덧셈 연산자
Definition TPoint.h:1933
TPoint< T > operator/(const TPoint< int64_t > &tp) const
나눗셈 연산자
Definition TPoint.h:2389
void Set(const TPoint< int32_t > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:617
const TPoint< T > & operator+=(int32_t value)
덧셈 대입 연산자
Definition TPoint.h:1230
friend TPoint< T > operator-(double value, const TPoint< T > &tp)
뺄셈 연산자
Definition TPoint.h:2574
const TPoint< T > & operator=(float value)
대입 연산자
Definition TPoint.h:990
void Set(const TPoint< int64_t > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:677
TPoint< T > operator+(const TPoint< float > &tp) const
덧셈 연산자
Definition TPoint.h:1952
void Set(int32_t x, int32_t y)
좌표를 설정합니다.
Definition TPoint.h:852
TPoint< T > operator/(const TPoint< float > &tp) const
나눗셈 연산자
Definition TPoint.h:2408
void Set(const TPoint< int16_t > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:557
const TPoint< T > & operator*=(float value)
곱셈 대입 연산자
Definition TPoint.h:1572
TPoint< T > operator*(int32_t value) const
곱셈 연산자
Definition TPoint.h:2142
const TPoint< T > & operator-=(const TPoint< int64_t > &tp)
뺄셈 대입 연산자
Definition TPoint.h:1477
const TPoint< T > & operator*=(int32_t value)
곱셈 대입 연산자
Definition TPoint.h:1534
TPoint< T > operator/(double value) const
나눗셈 연산자
Definition TPoint.h:2351
TPoint(const TPoint< uint64_t > *pTp)
복사 생성자
Definition TPoint.h:266
const TPoint< T > & operator/=(const TPoint< int32_t > &tp)
나눗셈 대입 연산자
Definition TPoint.h:1762
void Set(const TPoint< uint8_t > *pTp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:527
TPoint< T > operator-(int64_t value) const
뺄셈 연산자
Definition TPoint.h:2009
void Set(const TPoint< int32_t > &tp)
지정된 점 객체의 좌표를 설정합니다.
Definition TPoint.h:602
Definition AESCryptography.h:18