Source/Gorgon/Geometry.h

Sun, 27 Dec 2020 08:00:18 +0200

author
cemkalyoncu
date
Sun, 27 Dec 2020 08:00:18 +0200
branch
4.x-dev
changeset 1530
23a67943a4ee
parent 1525
ab43d641c7c4
child 1589
13038a91c0f4
permissions
-rw-r--r--

* Placeholder scripting types for some geometry classes

1525
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
1 #pragma once
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
2
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
3 #include "Scripting/Reflection.h"
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
4
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
5 namespace Gorgon { namespace Geometry {
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
6
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
7 extern Scripting::Library LibGeometry;
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
8
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
9 namespace Types {
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
10 #define DEFTYPE(name) \
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
11 inline const Scripting::Type &name() { \
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
12 static const Scripting::Type *type = LibGeometry.GetType(#name); \
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
13 return *type; \
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
14 }
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
15
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
16 DEFTYPE(Point)
1530
23a67943a4ee * Placeholder scripting types for some geometry classes
cemkalyoncu
parents: 1525
diff changeset
17 DEFTYPE(Pointf)
23a67943a4ee * Placeholder scripting types for some geometry classes
cemkalyoncu
parents: 1525
diff changeset
18 DEFTYPE(Size)
23a67943a4ee * Placeholder scripting types for some geometry classes
cemkalyoncu
parents: 1525
diff changeset
19 DEFTYPE(Sizef)
1525
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
20
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
21 #undef DEFTYPE
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
22 }
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
23
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
24 void InitializeScripting();
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
25
ab43d641c7c4 * Geometry reflection
cemkalyoncu
parents:
diff changeset
26 } }

mercurial