aboutsummaryrefslogtreecommitdiff
path: root/Client/Source/float2fixed/main.cpp
diff options
context:
space:
mode:
authorchai <chaifix@163.com>2021-12-02 11:41:42 +0800
committerchai <chaifix@163.com>2021-12-02 11:41:42 +0800
commit7a798253441a8bd499d36bd8153b92ab08de8a9f (patch)
tree32e4ee995534a4a8cd7c2e0b530ff02c45217e8f /Client/Source/float2fixed/main.cpp
parentbcc11176480f403ab294de24d61bab993ce2fdfd (diff)
*fixed
Diffstat (limited to 'Client/Source/float2fixed/main.cpp')
-rw-r--r--Client/Source/float2fixed/main.cpp17
1 files changed, 17 insertions, 0 deletions
diff --git a/Client/Source/float2fixed/main.cpp b/Client/Source/float2fixed/main.cpp
new file mode 100644
index 0000000..5c4fa40
--- /dev/null
+++ b/Client/Source/float2fixed/main.cpp
@@ -0,0 +1,17 @@
+#include "fpm/include/fpm/fixed.hpp"
+#include "fpm/include/fpm/ios.hpp"
+#include <iostream>
+
+using namespace std;
+
+typedef fpm::fixed_16_16 fixed16;
+
+int main()
+{
+ fixed16 n = 0.95f;
+ cout << n.raw_value();
+
+ getchar();
+
+ return 0;
+} \ No newline at end of file