SDXFrameWork 0.13 SDXFrameWork

- Main Page
- Related Pages
- Classes

All Classes Namespaces Functions Variables Enumerations Enumerator Pages
SDX.h
1 //Copyright © 2014 SDXFramework
2 //[License]GNU Affero General Public License, version 3
3 //[Contact]http://sourceforge.jp/projects/dxframework/
4 #pragma once
5
6 #include <vector>
7 #include <string>
8 #include <memory>
9 #include <math.h>
10 #include <algorithm>
11 #include <list>
12 #include <iomanip>
13
14 #include <fstream>
15 #include <sstream>
16 #include <iostream>
17
18 #include <vector>
19 #include <thread>
20 #include <mutex>
21 #include <cmath>
22
24 namespace SDX
25 {
26 const double PAI = 3.1415926535897931;
27 const double DEG = PAI / 180;
28
29 double CompAngle(double 角度A, double 角度B);
30 }
31
32 //モノステートパターン実現のために暫定的に、マクロ使用。変えるかも
33 #define MONO_STATE(a) \
34 a() = default;\
35 ~a() = default;\
36 void operator =(const a& src) = delete;\
37 a(const a& src) = delete;\
38 void operator =(const a&& src) = delete;\
39 a(const a&& src) = delete;
40
41 //Windowsのみ有効なコード
42 #pragma comment(lib, "SDL2.lib")
43
44 #if _MSC_VER > 1800
45 #ifdef _DEBUG
46 #pragma comment(lib, "SDL2main_2015.lib")
47 #else
48 #pragma comment(lib, "SDL2main_2015_MT.lib")
49 #endif
50 #else
51 #ifdef _DEBUG
52 #pragma comment(lib, "SDL2main.lib")
53 #else
54 #pragma comment(lib, "SDL2main_MT.lib")
55 #endif
56 #endif
57
58 #pragma comment(lib, "SDL2_image.lib")
59 #pragma comment(lib, "SDL2_mixer.lib")
60
61 #ifndef OMIT_SDL2_TTF
62 #pragma comment(lib, "SDL2_ttf.lib")
63 #endif
64
65 #pragma execution_character_set("utf-8")//charの文字コードをUTF-8に変更
66
67 #ifdef _DEBUG
68 #pragma comment(linker, "/NODEFAULTLIB:msvcrt.lib")
69 #endif
70
71 #include <SDL.h>
72 #include <SDL_image.h>
73 #include <SDL_mixer.h>
74 #include <SDL_ttf.h>
75
76 #ifdef __ANDROID__
77 #define TABLET
78 #elif defined(__IPHONEOS__)
79 #define TABLET
80 #endif
81
82 #ifdef __WINDOWS__
83 #include<xutility>
84 #else
85 #include <locale.h>
86 #define sprintf_s(a,b,c,d) sprintf(a,c,d)
87 #define localtime_s(a,b) a = localtime(b)
88 #endif
SDX::PAI
const double PAI
円周率
Definition: SDX.h:26
SDX::CompAngle
double CompAngle(double 角度A, double 角度B)
Aから見たBの角度差を-PAI～+PAIで返す.
Definition: SDXafx.h:61
SDX::DEG
const double DEG
ラジアンにおける1℃
Definition: SDX.h:27