blob: 8c26564a804f8a6a4c6d01093e30cab8139d2369 (
plain)
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
#ifndef __ASURA_ENGINE_MESH2D_H__
#define __ASURA_ENGINE_MESH2D_H__
// cpp
#include <vector>
// asura modules
#include <asura-utils/scripting/portable.hpp>
#include <asura-utils/math/vector2.hpp>
// module
#include "../mesh/mesh2d_data.h"
// folder
#include "color.h"
#include "vertex_buffer.h"
#include "index_buffer.h"
namespace AsuraEngine
{
namespace Graphics
{
///
/// 2D meshһЩ㶯
/// https://en.wikipedia.org/wiki/Polygon_mesh
///
class Mesh2D ASURA_FINAL
: public Scripting::Portable<Mesh2D>
{
public:
Mesh2D();
~Mesh2D();
bool Load(AEMesh::Mesh2DData* data);
private:
VertexBuffer* m_VBO; ///< vertex buffer
IndexBuffer* m_IBO; ///< index buffer
luaxport:
LUAX_DECL_FACTORY(Mesh2D);
LUAX_DECL_METHOD(_SetVertex);
};
}
}
#endif
|