@@ -60,7 +60,7 @@ public: | |||||
} | } | ||||
private: | private: | ||||
Array<vec2> m_vertices; | |||||
array<vec2> m_vertices; | |||||
Shader *m_shader; | Shader *m_shader; | ||||
ShaderAttrib m_coord; | ShaderAttrib m_coord; | ||||
VertexDeclaration *m_vdecl; | VertexDeclaration *m_vdecl; | ||||
@@ -118,8 +118,8 @@ public: | |||||
private: | private: | ||||
float m_angle; | float m_angle; | ||||
mat4 m_matrix; | mat4 m_matrix; | ||||
Array<vec3,vec3> m_mesh; | |||||
Array<uint16_t> m_lines_indices, m_faces_indices; | |||||
array<vec3,vec3> m_mesh; | |||||
array<uint16_t> m_lines_indices, m_faces_indices; | |||||
Shader *m_shader; | Shader *m_shader; | ||||
ShaderAttrib m_coord, m_color; | ShaderAttrib m_coord, m_color; | ||||
@@ -68,7 +68,7 @@ public: | |||||
} | } | ||||
private: | private: | ||||
Array<vec2> m_vertices; | |||||
array<vec2> m_vertices; | |||||
Shader *m_shader; | Shader *m_shader; | ||||
ShaderAttrib m_coord; | ShaderAttrib m_coord; | ||||
ShaderUniform m_time_uni; | ShaderUniform m_time_uni; | ||||
@@ -96,14 +96,14 @@ public: | |||||
} | } | ||||
private: | private: | ||||
Array<vec2> m_vertices; | |||||
array<vec2> m_vertices; | |||||
Texture *m_texture; | Texture *m_texture; | ||||
Shader *m_shader; | Shader *m_shader; | ||||
ShaderAttrib m_coord; | ShaderAttrib m_coord; | ||||
ShaderUniform m_texture_uni; | ShaderUniform m_texture_uni; | ||||
VertexDeclaration *m_vdecl; | VertexDeclaration *m_vdecl; | ||||
VertexBuffer *m_vbo; | VertexBuffer *m_vbo; | ||||
Array<uint8_t> m_heightmap; | |||||
array<uint8_t> m_heightmap; | |||||
int m_frames; | int m_frames; | ||||
bool m_ready; | bool m_ready; | ||||
}; | }; | ||||
@@ -144,7 +144,7 @@ public: | |||||
private: | private: | ||||
Shader* m_custom_shader; | Shader* m_custom_shader; | ||||
Array<EasyMesh, mat4, float> m_gears; | |||||
array<EasyMesh, mat4, float> m_gears; | |||||
float m_angle; | float m_angle; | ||||
mat4 m_mat; | mat4 m_mat; | ||||
Camera *m_camera; | Camera *m_camera; | ||||
@@ -88,7 +88,7 @@ private: | |||||
static int const SPRITE_COUNT = 192; | static int const SPRITE_COUNT = 192; | ||||
static int const FRAME_COUNT = 16; | static int const FRAME_COUNT = 16; | ||||
Array<vec3, float> m_sprites; | |||||
array<vec3, float> m_sprites; | |||||
bool m_ready; | bool m_ready; | ||||
}; | }; | ||||
@@ -218,8 +218,8 @@ private: | |||||
float m_pitch_angle; | float m_pitch_angle; | ||||
float m_yaw_angle; | float m_yaw_angle; | ||||
mat4 m_matrix; | mat4 m_matrix; | ||||
Array<vec3,vec3> m_mesh; | |||||
Array<uint16_t> m_lines_indices, m_faces_indices; | |||||
array<vec3,vec3> m_mesh; | |||||
array<uint16_t> m_lines_indices, m_faces_indices; | |||||
Shader *m_shader; | Shader *m_shader; | ||||
ShaderAttrib m_coord, m_color; | ShaderAttrib m_coord, m_color; | ||||
@@ -128,7 +128,7 @@ public: | |||||
} | } | ||||
private: | private: | ||||
Array<vec2> m_vertices; | |||||
array<vec2> m_vertices; | |||||
Shader *m_shader; | Shader *m_shader; | ||||
ShaderAttrib m_coord; | ShaderAttrib m_coord; | ||||
ShaderUniform m_uni_flag, m_uni_point, m_uni_color, m_uni_texture; | ShaderUniform m_uni_flag, m_uni_point, m_uni_color, m_uni_texture; | ||||
@@ -532,7 +532,7 @@ private: | |||||
ivec2 m_size, m_window_size, m_oldmouse; | ivec2 m_size, m_window_size, m_oldmouse; | ||||
double m_window2world; | double m_window2world; | ||||
dvec2 m_texel2world; | dvec2 m_texel2world; | ||||
Array<u8vec4> m_pixels, m_palette; | |||||
array<u8vec4> m_pixels, m_palette; | |||||
Shader *m_shader; | Shader *m_shader; | ||||
ShaderAttrib m_vertexattrib, m_texattrib; | ShaderAttrib m_vertexattrib, m_texattrib; | ||||
@@ -113,7 +113,7 @@ public: | |||||
for (int i = 0; i < MaxFboType; ++i) | for (int i = 0; i < MaxFboType; ++i) | ||||
{ | { | ||||
m_fbos.Push(new Framebuffer(Video::GetSize()), 0, Array<ShaderUniform>(), Array<ShaderAttrib>() ); | |||||
m_fbos.Push(new Framebuffer(Video::GetSize()), 0, array<ShaderUniform>(), array<ShaderAttrib>() ); | |||||
if (i == SrcVoronoiFbo) | if (i == SrcVoronoiFbo) | ||||
{ | { | ||||
@@ -394,8 +394,8 @@ public: | |||||
private: | private: | ||||
Controller* m_controller; | Controller* m_controller; | ||||
Array<vec3, vec2> voronoi_points; | |||||
Array<vec2> m_vertices; | |||||
array<vec3, vec2> voronoi_points; | |||||
array<vec2> m_vertices; | |||||
Shader *m_screen_shader; | Shader *m_screen_shader; | ||||
ShaderAttrib m_screen_coord; | ShaderAttrib m_screen_coord; | ||||
ShaderUniform m_screen_texture; | ShaderUniform m_screen_texture; | ||||
@@ -403,7 +403,7 @@ private: | |||||
VertexDeclaration *m_vdecl; | VertexDeclaration *m_vdecl; | ||||
VertexBuffer *m_vbo; | VertexBuffer *m_vbo; | ||||
Array<Framebuffer *, Shader *, Array<ShaderUniform>, Array<ShaderAttrib> > m_fbos; | |||||
array<Framebuffer *, Shader *, array<ShaderUniform>, array<ShaderAttrib> > m_fbos; | |||||
Framebuffer *temp_buffer; | Framebuffer *temp_buffer; | ||||
int mode; | int mode; | ||||
@@ -272,7 +272,7 @@ void BtPhysTest::InitApp() | |||||
#if USE_ROPE | #if USE_ROPE | ||||
{ | { | ||||
Array<PhysicsObject*> RopeElements; | |||||
array<PhysicsObject*> RopeElements; | |||||
for (int i = 0; i < 14; i++) | for (int i = 0; i < 14; i++) | ||||
{ | { | ||||
PhysicsObject* new_physobj = new PhysicsObject(m_simulation, 1000.f, | PhysicsObject* new_physobj = new PhysicsObject(m_simulation, 1000.f, | ||||
@@ -68,12 +68,12 @@ private: | |||||
bool m_ready; | bool m_ready; | ||||
lol::phys::Simulation* m_simulation; | lol::phys::Simulation* m_simulation; | ||||
Array<EasyConstraint*> m_constraint_list; | |||||
Array<PhysicsObject*, float> m_physobj_list; | |||||
Array<PhysicsObject*> m_ground_list; | |||||
Array<PhysicsObject*> m_platform_list; | |||||
Array<PhysicsObject*> m_character_list; | |||||
Array<PhysicsObject*> m_stairs_list; | |||||
array<EasyConstraint*> m_constraint_list; | |||||
array<PhysicsObject*, float> m_physobj_list; | |||||
array<PhysicsObject*> m_ground_list; | |||||
array<PhysicsObject*> m_platform_list; | |||||
array<PhysicsObject*> m_character_list; | |||||
array<PhysicsObject*> m_stairs_list; | |||||
float m_loop_value; | float m_loop_value; | ||||
float m_target_timer; | float m_target_timer; | ||||
@@ -165,7 +165,7 @@ public: | |||||
} | } | ||||
} | } | ||||
Array<vec3> m_targets; | |||||
array<vec3> m_targets; | |||||
}; | }; | ||||
class MeshViewer : public WorldEntity | class MeshViewer : public WorldEntity | ||||
@@ -581,7 +581,7 @@ public: | |||||
if (new_ssetup->Compile(mesh.C()) && new_ssetup->m_lights.Count()) | if (new_ssetup->Compile(mesh.C()) && new_ssetup->m_lights.Count()) | ||||
{ | { | ||||
//Store current light datas, in World | //Store current light datas, in World | ||||
Array<LightData> light_datas; | |||||
array<LightData> light_datas; | |||||
for (int i = 0; i < m_ssetup->m_lights.Count(); ++i) | for (int i = 0; i < m_ssetup->m_lights.Count(); ++i) | ||||
light_datas << LightData(m_ssetup->m_lights[i]->GetPosition(), m_ssetup->m_lights[i]->GetColor()); | light_datas << LightData(m_ssetup->m_lights[i]->GetPosition(), m_ssetup->m_lights[i]->GetColor()); | ||||
@@ -890,7 +890,7 @@ public: | |||||
private: | private: | ||||
SceneSetup* m_ssetup; | SceneSetup* m_ssetup; | ||||
Array<LightData> m_light_datas; | |||||
array<LightData> m_light_datas; | |||||
Controller* m_controller; | Controller* m_controller; | ||||
short m_input_usage; | short m_input_usage; | ||||
mat4 m_mat; | mat4 m_mat; | ||||
@@ -927,12 +927,12 @@ private: | |||||
int m_mesh_render; | int m_mesh_render; | ||||
int m_mesh_id; | int m_mesh_id; | ||||
float m_mesh_id1; | float m_mesh_id1; | ||||
Array<EasyMesh*, EasyMesh*> m_meshes; | |||||
Array<EasyMesh*> m_gizmos; | |||||
array<EasyMesh*, EasyMesh*> m_meshes; | |||||
array<EasyMesh*> m_gizmos; | |||||
//File data | //File data | ||||
String m_file_name; | String m_file_name; | ||||
Array<String> m_cmdlist; | |||||
array<String> m_cmdlist; | |||||
float m_stream_update_time; | float m_stream_update_time; | ||||
float m_stream_update_timer; | float m_stream_update_timer; | ||||
@@ -43,12 +43,12 @@ private: | |||||
bool m_ready; | bool m_ready; | ||||
//lol::phys::Simulation* m_simulation; | //lol::phys::Simulation* m_simulation; | ||||
//Array<EasyConstraint*> m_constraint_list; | |||||
//Array<PhysicsObject*, float> m_physobj_list; | |||||
//Array<PhysicsObject*> m_ground_list; | |||||
//Array<PhysicsObject*> m_platform_list; | |||||
//Array<PhysicsObject*> m_character_list; | |||||
//Array<PhysicsObject*> m_stairs_list; | |||||
//array<EasyConstraint*> m_constraint_list; | |||||
//array<PhysicsObject*, float> m_physobj_list; | |||||
//array<PhysicsObject*> m_ground_list; | |||||
//array<PhysicsObject*> m_platform_list; | |||||
//array<PhysicsObject*> m_character_list; | |||||
//array<PhysicsObject*> m_stairs_list; | |||||
float m_loop_value; | float m_loop_value; | ||||
float m_target_timer; | float m_target_timer; | ||||
@@ -130,9 +130,9 @@ public: | |||||
m_is_character(false), | m_is_character(false), | ||||
m_is_phys(false) | m_is_phys(false) | ||||
{ | { | ||||
Array<char const *> MeshRand; | |||||
Array<int> MeshLimit; | |||||
Array<int> MeshType; | |||||
array<char const *> MeshRand; | |||||
array<int> MeshLimit; | |||||
array<int> MeshType; | |||||
MeshLimit << 0; | MeshLimit << 0; | ||||
@@ -142,13 +142,13 @@ protected: | |||||
Simulation* m_owner_simulation; | Simulation* m_owner_simulation; | ||||
//Base/Attachment logic | //Base/Attachment logic | ||||
Array<EasyPhysic*> m_based_physic_list; //List of objects based on this : this object moves, its based object MoveStep with it. | |||||
array<EasyPhysic*> m_based_physic_list; //List of objects based on this : this object moves, its based object MoveStep with it. | |||||
EasyPhysic* m_base_physic; //Base for this object : The base moves, the object moves with it. | EasyPhysic* m_base_physic; //Base for this object : The base moves, the object moves with it. | ||||
bool m_base_lock_location; //when this is TRUE, location moves with rotation change. | bool m_base_lock_location; //when this is TRUE, location moves with rotation change. | ||||
bool m_base_lock_rotation; //when this is TRUE, rotation moves with rotation change. | bool m_base_lock_rotation; //when this is TRUE, rotation moves with rotation change. | ||||
//Touch logic | //Touch logic | ||||
Array<EasyPhysic*> m_touching_physic; //Maintained by ghost objects | |||||
array<EasyPhysic*> m_touching_physic; //Maintained by ghost objects | |||||
}; | }; | ||||
} /* namespace phys */ | } /* namespace phys */ | ||||
@@ -48,10 +48,10 @@ struct RayCastResult | |||||
m_hit_fraction_list.Empty(); | m_hit_fraction_list.Empty(); | ||||
} | } | ||||
Array<EasyPhysic*> m_collider_list; | |||||
Array<vec3> m_hit_normal_list; | |||||
Array<vec3> m_hit_point_list; | |||||
Array<float> m_hit_fraction_list; | |||||
array<EasyPhysic*> m_collider_list; | |||||
array<vec3> m_hit_normal_list; | |||||
array<vec3> m_hit_point_list; | |||||
array<float> m_hit_fraction_list; | |||||
short int m_collision_filter_group; | short int m_collision_filter_group; | ||||
short int m_collision_filter_mask; | short int m_collision_filter_mask; | ||||
@@ -334,7 +334,7 @@ private: | |||||
//Adds the given EasyPhysic to the correct list. | //Adds the given EasyPhysic to the correct list. | ||||
void ObjectRegistration(bool AddObject, EasyPhysic* NewEP, eEasyPhysicType CurType) | void ObjectRegistration(bool AddObject, EasyPhysic* NewEP, eEasyPhysicType CurType) | ||||
{ | { | ||||
Array<EasyPhysic*>* SearchList = NULL; | |||||
array<EasyPhysic*>* SearchList = NULL; | |||||
switch(CurType) | switch(CurType) | ||||
{ | { | ||||
case EEPT_Dynamic: | case EEPT_Dynamic: | ||||
@@ -388,7 +388,7 @@ private: | |||||
} | } | ||||
void ObjectRegistration(bool AddObject, EasyConstraint* NewEC) | void ObjectRegistration(bool AddObject, EasyConstraint* NewEC) | ||||
{ | { | ||||
Array<EasyConstraint*>* SearchList = NULL; | |||||
array<EasyConstraint*>* SearchList = NULL; | |||||
SearchList = &m_constraint_list; | SearchList = &m_constraint_list; | ||||
if (AddObject) | if (AddObject) | ||||
@@ -411,12 +411,12 @@ private: | |||||
} | } | ||||
//Easy Physics body List | //Easy Physics body List | ||||
Array<EasyPhysic*> m_dynamic_list; | |||||
Array<EasyPhysic*> m_static_list; | |||||
Array<EasyPhysic*> m_ghost_list; | |||||
Array<EasyPhysic*> m_collision_object_list; | |||||
Array<EasyPhysic*> m_character_controller_list; | |||||
Array<EasyConstraint*> m_constraint_list; | |||||
array<EasyPhysic*> m_dynamic_list; | |||||
array<EasyPhysic*> m_static_list; | |||||
array<EasyPhysic*> m_ghost_list; | |||||
array<EasyPhysic*> m_collision_object_list; | |||||
array<EasyPhysic*> m_character_controller_list; | |||||
array<EasyConstraint*> m_constraint_list; | |||||
//Easy Physics data storage | //Easy Physics data storage | ||||
float m_timestep; | float m_timestep; | ||||
@@ -40,8 +40,8 @@ public: | |||||
//-- | //-- | ||||
vec4 m_clear_color; | vec4 m_clear_color; | ||||
Array<Light *> m_lights; | |||||
Array<String, String> m_custom_cmd; | |||||
array<Light *> m_lights; | |||||
array<String, String> m_custom_cmd; | |||||
bool m_show_gizmo; | bool m_show_gizmo; | ||||
bool m_show_lights; | bool m_show_lights; | ||||
}; | }; | ||||
@@ -38,7 +38,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayPush) | LOLUNIT_TEST(ArrayPush) | ||||
{ | { | ||||
Array<int> a; | |||||
array<int> a; | |||||
a.Push(0); | a.Push(0); | ||||
a.Push(1); | a.Push(1); | ||||
a.Push(2); | a.Push(2); | ||||
@@ -52,19 +52,19 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayInitializer) | LOLUNIT_TEST(ArrayInitializer) | ||||
{ | { | ||||
Array<int> a({ 2, 4, 6 }); | |||||
array<int> a({ 2, 4, 6 }); | |||||
LOLUNIT_ASSERT_EQUAL(a[0], 2); | LOLUNIT_ASSERT_EQUAL(a[0], 2); | ||||
LOLUNIT_ASSERT_EQUAL(a[1], 4); | LOLUNIT_ASSERT_EQUAL(a[1], 4); | ||||
LOLUNIT_ASSERT_EQUAL(a[2], 6); | LOLUNIT_ASSERT_EQUAL(a[2], 6); | ||||
Array<int> b = { 2, 4, 6 }; | |||||
array<int> b = { 2, 4, 6 }; | |||||
LOLUNIT_ASSERT_EQUAL(b[0], 2); | LOLUNIT_ASSERT_EQUAL(b[0], 2); | ||||
LOLUNIT_ASSERT_EQUAL(b[1], 4); | LOLUNIT_ASSERT_EQUAL(b[1], 4); | ||||
LOLUNIT_ASSERT_EQUAL(b[2], 6); | LOLUNIT_ASSERT_EQUAL(b[2], 6); | ||||
Array<int, float> c = { { 2, 3.0f }, | |||||
array<int, float> c = { { 2, 3.0f }, | |||||
{ 4, 5.0f }, | { 4, 5.0f }, | ||||
{ 6, 7.0f } }; | { 6, 7.0f } }; | ||||
@@ -78,7 +78,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayPushWithShift) | LOLUNIT_TEST(ArrayPushWithShift) | ||||
{ | { | ||||
Array<int> a; | |||||
array<int> a; | |||||
a << 0 << 1 << 2 << 3; | a << 0 << 1 << 2 << 3; | ||||
LOLUNIT_ASSERT_EQUAL(a[0], 0); | LOLUNIT_ASSERT_EQUAL(a[0], 0); | ||||
@@ -89,10 +89,10 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayCopy) | LOLUNIT_TEST(ArrayCopy) | ||||
{ | { | ||||
Array<int> a; | |||||
array<int> a; | |||||
a << 0 << 1 << 2 << 3; | a << 0 << 1 << 2 << 3; | ||||
Array<int> b = a; | |||||
array<int> b = a; | |||||
LOLUNIT_ASSERT_EQUAL(b[0], 0); | LOLUNIT_ASSERT_EQUAL(b[0], 0); | ||||
LOLUNIT_ASSERT_EQUAL(b[1], 1); | LOLUNIT_ASSERT_EQUAL(b[1], 1); | ||||
@@ -102,7 +102,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayRemove) | LOLUNIT_TEST(ArrayRemove) | ||||
{ | { | ||||
Array<int> a; | |||||
array<int> a; | |||||
a << 0 << 1 << 2 << 3; | a << 0 << 1 << 2 << 3; | ||||
a.Remove(1); | a.Remove(1); | ||||
@@ -111,7 +111,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_ASSERT_EQUAL(a[1], 2); | LOLUNIT_ASSERT_EQUAL(a[1], 2); | ||||
LOLUNIT_ASSERT_EQUAL(a[2], 3); | LOLUNIT_ASSERT_EQUAL(a[2], 3); | ||||
Array<int> b; | |||||
array<int> b; | |||||
b << 0 << 1 << 2 << 3; | b << 0 << 1 << 2 << 3; | ||||
b.Remove(-2); | b.Remove(-2); | ||||
@@ -123,7 +123,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayRemoveSwap) | LOLUNIT_TEST(ArrayRemoveSwap) | ||||
{ | { | ||||
Array<int> a; | |||||
array<int> a; | |||||
a << 0 << 1 << 2 << 3; | a << 0 << 1 << 2 << 3; | ||||
a.RemoveSwap(1); | a.RemoveSwap(1); | ||||
@@ -132,7 +132,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_ASSERT_EQUAL(a[1], 3); | LOLUNIT_ASSERT_EQUAL(a[1], 3); | ||||
LOLUNIT_ASSERT_EQUAL(a[2], 2); | LOLUNIT_ASSERT_EQUAL(a[2], 2); | ||||
Array<int> b; | |||||
array<int> b; | |||||
b << 0 << 1 << 2 << 3; | b << 0 << 1 << 2 << 3; | ||||
b.Remove(1, 2); | b.Remove(1, 2); | ||||
@@ -143,7 +143,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(EightElements) | LOLUNIT_TEST(EightElements) | ||||
{ | { | ||||
Array<int, long, float, double, unsigned, char, bool, void *> a; | |||||
array<int, long, float, double, unsigned, char, bool, void *> a; | |||||
a.Push(1, 2, 3.f, 4.0, 5, 'a', true, 0); | a.Push(1, 2, 3.f, 4.0, 5, 'a', true, 0); | ||||
LOLUNIT_ASSERT_EQUAL(a[0].m1, 1); | LOLUNIT_ASSERT_EQUAL(a[0].m1, 1); | ||||
@@ -158,7 +158,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArraySwap) | LOLUNIT_TEST(ArraySwap) | ||||
{ | { | ||||
Array<int, int> a; | |||||
array<int, int> a; | |||||
a.Push(10, 20); | a.Push(10, 20); | ||||
a.Push(30, 40); | a.Push(30, 40); | ||||
a.Swap(0, 1); | a.Swap(0, 1); | ||||
@@ -171,7 +171,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayInsert) | LOLUNIT_TEST(ArrayInsert) | ||||
{ | { | ||||
Array<int> a; | |||||
array<int> a; | |||||
a << 1 << 2; | a << 1 << 2; | ||||
a.Insert(5, 0); | a.Insert(5, 0); | ||||
@@ -195,11 +195,11 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayConcat) | LOLUNIT_TEST(ArrayConcat) | ||||
{ | { | ||||
Array<int> a, b; | |||||
array<int> a, b; | |||||
a << 0 << 1; | a << 0 << 1; | ||||
b << 2 << 3; | b << 2 << 3; | ||||
Array<int> c = a + b; | |||||
array<int> c = a + b; | |||||
LOLUNIT_ASSERT_EQUAL(c[0], 0); | LOLUNIT_ASSERT_EQUAL(c[0], 0); | ||||
LOLUNIT_ASSERT_EQUAL(c[1], 1); | LOLUNIT_ASSERT_EQUAL(c[1], 1); | ||||
LOLUNIT_ASSERT_EQUAL(c[2], 2); | LOLUNIT_ASSERT_EQUAL(c[2], 2); | ||||
@@ -208,7 +208,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
LOLUNIT_TEST(ArrayAppend) | LOLUNIT_TEST(ArrayAppend) | ||||
{ | { | ||||
Array<int> a, b; | |||||
array<int> a, b; | |||||
a << 0 << 1; | a << 0 << 1; | ||||
b << 2 << 3; | b << 2 << 3; | ||||
@@ -232,7 +232,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
TrackedObj::m_ctor = 0; | TrackedObj::m_ctor = 0; | ||||
TrackedObj::m_dtor = 0; | TrackedObj::m_dtor = 0; | ||||
{ | { | ||||
Array<TrackedObj> a; | |||||
array<TrackedObj> a; | |||||
a.Push(TrackedObj()); | a.Push(TrackedObj()); | ||||
} | } | ||||
@@ -241,7 +241,7 @@ LOLUNIT_FIXTURE(ArrayTest) | |||||
TrackedObj::m_ctor = 0; | TrackedObj::m_ctor = 0; | ||||
TrackedObj::m_dtor = 0; | TrackedObj::m_dtor = 0; | ||||
{ | { | ||||
Array<TrackedObj> a; | |||||
array<TrackedObj> a; | |||||
a.Resize(2); | a.Resize(2); | ||||
a.Resize(4); | a.Resize(4); | ||||
@@ -536,7 +536,7 @@ LOLUNIT_FIXTURE(QuaternionTest) | |||||
} | } | ||||
private: | private: | ||||
Array<vec3, vec3> m_vectorpairs; | |||||
array<vec3, vec3> m_vectorpairs; | |||||
}; | }; | ||||
} /* namespace lol */ | } /* namespace lol */ | ||||
@@ -106,6 +106,6 @@ template<typename T> struct Matrix | |||||
int m_cols, m_rows; | int m_cols, m_rows; | ||||
private: | private: | ||||
Array<T> m_data; | |||||
array<T> m_data; | |||||
}; | }; | ||||
@@ -96,7 +96,7 @@ void RemezSolver::Init() | |||||
m_control.Resize(m_order + 2); | m_control.Resize(m_order + 2); | ||||
/* Pick up x_i where error will be 0 and compute f(x_i) */ | /* Pick up x_i where error will be 0 and compute f(x_i) */ | ||||
Array<real> fxn; | |||||
array<real> fxn; | |||||
for (int i = 0; i < m_order + 1; i++) | for (int i = 0; i < m_order + 1; i++) | ||||
{ | { | ||||
m_zeroes[i] = (real)(2 * i - m_order) / (real)(m_order + 1); | m_zeroes[i] = (real)(2 * i - m_order) / (real)(m_order + 1); | ||||
@@ -109,7 +109,7 @@ void RemezSolver::Init() | |||||
for (int i = 0; i < m_order + 1; i++) | for (int i = 0; i < m_order + 1; i++) | ||||
{ | { | ||||
/* Compute the powers of x_i */ | /* Compute the powers of x_i */ | ||||
Array<real> powers; | |||||
array<real> powers; | |||||
powers.Push(real(1.0)); | powers.Push(real(1.0)); | ||||
for (int n = 1; n < m_order + 1; n++) | for (int n = 1; n < m_order + 1; n++) | ||||
powers.Push(powers.Last() * m_zeroes[i]); | powers.Push(powers.Last() * m_zeroes[i]); | ||||
@@ -239,7 +239,7 @@ real RemezSolver::FindExtrema() | |||||
void RemezSolver::Step() | void RemezSolver::Step() | ||||
{ | { | ||||
/* Pick up x_i where error will be 0 and compute f(x_i) */ | /* Pick up x_i where error will be 0 and compute f(x_i) */ | ||||
Array<real> fxn; | |||||
array<real> fxn; | |||||
for (int i = 0; i < m_order + 2; i++) | for (int i = 0; i < m_order + 2; i++) | ||||
fxn.Push(EvalFunc(m_control[i])); | fxn.Push(EvalFunc(m_control[i])); | ||||
@@ -249,7 +249,7 @@ void RemezSolver::Step() | |||||
for (int i = 0; i < m_order + 2; i++) | for (int i = 0; i < m_order + 2; i++) | ||||
{ | { | ||||
/* Compute the powers of x_i */ | /* Compute the powers of x_i */ | ||||
Array<real> powers; | |||||
array<real> powers; | |||||
powers.Push(real(1.0)); | powers.Push(real(1.0)); | ||||
for (int n = 1; n < m_order + 1; n++) | for (int n = 1; n < m_order + 1; n++) | ||||
powers.Push(powers.Last() * m_control[i]); | powers.Push(powers.Last() * m_control[i]); | ||||
@@ -307,7 +307,7 @@ void RemezSolver::PrintPoly() | |||||
/* Transform Chebyshev polynomial weights into powers of X^i | /* Transform Chebyshev polynomial weights into powers of X^i | ||||
* in the [-1..1] range. */ | * in the [-1..1] range. */ | ||||
Array<real> bn; | |||||
array<real> bn; | |||||
for (int i = 0; i < m_order + 1; i++) | for (int i = 0; i < m_order + 1; i++) | ||||
{ | { | ||||
@@ -319,7 +319,7 @@ void RemezSolver::PrintPoly() | |||||
/* Transform a polynomial in the [-1..1] range into a polynomial | /* Transform a polynomial in the [-1..1] range into a polynomial | ||||
* in the [a..b] range. */ | * in the [a..b] range. */ | ||||
Array<real> k1p, k2p, an; | |||||
array<real> k1p, k2p, an; | |||||
for (int i = 0; i < m_order + 1; i++) | for (int i = 0; i < m_order + 1; i++) | ||||
{ | { | ||||
@@ -44,9 +44,9 @@ private: | |||||
private: | private: | ||||
int m_order; | int m_order; | ||||
lol::Array<lol::real> m_coeff; | |||||
lol::Array<lol::real> m_zeroes; | |||||
lol::Array<lol::real> m_control; | |||||
lol::array<lol::real> m_coeff; | |||||
lol::array<lol::real> m_zeroes; | |||||
lol::array<lol::real> m_control; | |||||
RealFunc *m_func, *m_weight; | RealFunc *m_func, *m_weight; | ||||
lol::real m_k1, m_k2, m_invk1, m_invk2, m_epsilon; | lol::real m_k1, m_k2, m_invk1, m_invk2, m_epsilon; | ||||
@@ -18,7 +18,7 @@ au Syntax cpp | |||||
" Some custom container types | " Some custom container types | ||||
au Syntax cpp | au Syntax cpp | ||||
\ syn keyword cType | \ syn keyword cType | ||||
\ hash map array2d array3d | |||||
\ array array2d array3d hash map | |||||
" GLSL types and the Lol Engine extensions | " GLSL types and the Lol Engine extensions | ||||
au Syntax cpp | au Syntax cpp | ||||