-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathloader.h
38 lines (30 loc) · 871 Bytes
/
loader.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#ifndef LOADER_H
#define LOADER_H
#include <math.h>
#include <iostream>
#include <fstream>
#include <locale>
using namespace std;
#include "linkedlist.h"
#include "matrix.h"
// Třída pro načítání transformací
class Loader
{
public:
enum TransformType { ttTranslate = 1, ttRotate = 2, ttScale = 3, ttIdentity = 4, ttUnknown = 0};
struct Transform {
Matrix<float> T;
TransformType type;
double p1,p2;
Transform() : T(3,3) { type = ttUnknown; p1 = p2 = 0; }
};
Loader() : transforms() { }
~Loader();
bool load(const char* szFile,int ScalingFactor);
LinkedList<Transform>& getTransforms() { return transforms; }
static const char* getTransformString(TransformType Type);
static TransformType getTransformType(string Name);
private:
LinkedList<Transform> transforms;
};
#endif // LOADER_H