diff --git a/src/commandstack.h b/src/commandstack.h index f95b4764..e7a6720f 100644 --- a/src/commandstack.h +++ b/src/commandstack.h @@ -31,7 +31,7 @@ private: int m_i_cur; public: - //GET/SET exec + //GET/SET exec int GetCmdNb() { return m_commands.Count(); } int GetCmd(int i) { @@ -41,7 +41,7 @@ public: return m_commands[i].m1; } - //cmd storage + //cmd storage void AddCmd(int cmd) { m_commands.Push(cmd, m_floats.Count(), m_ints.Count()); } //GETTER diff --git a/src/easymesh/easymesh.cpp b/src/easymesh/easymesh.cpp index ff4b2b5d..d660b663 100644 --- a/src/easymesh/easymesh.cpp +++ b/src/easymesh/easymesh.cpp @@ -41,8 +41,8 @@ EasyMesh::EasyMesh(const EasyMesh& em) m_cursors = em.m_cursors; m_build_data = nullptr; m_gpu_data = GpuEasyMeshData(); - if (em.m_build_data) - m_build_data = new EasyMeshBuildData(*em.m_build_data); + if (em.m_build_data) + m_build_data = new EasyMeshBuildData(*em.m_build_data); if (m_indices.Count() && m_vert.Count() && m_cursors.Count()) m_state = MeshRender::NeedConvert; else @@ -238,8 +238,8 @@ void EasyMesh::MeshConvert(GpuShaderData* new_gpu_sdata) { m_gpu_data.AddGpuData(new_gpu_sdata, this); for (int i = DebugRenderMode::Default; i < DebugRenderMode::Max; i++) - if (!m_gpu_data.HasData(i)) - m_gpu_data.AddGpuData(new DefaultShaderData(DebugRenderMode(i)), this); + if (!m_gpu_data.HasData(i)) + m_gpu_data.AddGpuData(new DefaultShaderData(DebugRenderMode(i)), this); } m_state = MeshRender::CanRender; } diff --git a/src/easymesh/easymeshbuild.cpp b/src/easymesh/easymeshbuild.cpp index a0a43019..14e7fe7b 100644 --- a/src/easymesh/easymeshbuild.cpp +++ b/src/easymesh/easymeshbuild.cpp @@ -184,30 +184,30 @@ void VertexDictionnary::AddVertex(const int vert_id, const vec3 vert_coord) //Will update the given list with all the vertices on the same spot. void VertexDictionnary::RemoveVertex(const int vert_id) { - int j = 0; + int j = 0; for (; j < vertex_list.Count(); j++) if (vertex_list[j].m1 == vert_id) break; - if (vertex_list[j].m3 == VDictType::Master) - { - int jf = -1; - //change all the master ref in the list - for (int i = 0; i < vertex_list.Count(); i++) - { - if (vertex_list[i].m3 == j) - { - if (jf < 0) - { - jf = i; - vertex_list[i].m3 = VDictType::Master; - } - else - vertex_list[i].m3 = jf; - } - } - } - vertex_list.Remove(j); + if (vertex_list[j].m3 == VDictType::Master) + { + int jf = -1; + //change all the master ref in the list + for (int i = 0; i < vertex_list.Count(); i++) + { + if (vertex_list[i].m3 == j) + { + if (jf < 0) + { + jf = i; + vertex_list[i].m3 = VDictType::Master; + } + else + vertex_list[i].m3 = jf; + } + } + } + vertex_list.Remove(j); for (int i = 0; i < master_list.Count(); i++) if (master_list[j] == j) break; diff --git a/src/easymesh/easymeshbuild.h b/src/easymesh/easymeshbuild.h index 4785cf6c..0bc71778 100644 --- a/src/easymesh/easymeshbuild.h +++ b/src/easymesh/easymeshbuild.h @@ -196,7 +196,7 @@ public: m_texcoord_scale = vec2(1.f); m_texcoord_scale2 = vec2(1.f); m_build_flags = 0; - m_i_cmd = 0; + m_i_cmd = 0; m_exec_nb = -1; for (int i = 0; i < MeshType::Max; ++i) { diff --git a/src/easymesh/easymeshrender.cpp b/src/easymesh/easymeshrender.cpp index 8fe0427e..e480d876 100644 --- a/src/easymesh/easymeshrender.cpp +++ b/src/easymesh/easymeshrender.cpp @@ -239,11 +239,11 @@ void GpuEasyMeshData::AddGpuData(GpuShaderData* gpudata, EasyMesh* src_mesh) m_indexcount = indexlist.Count(); } - //init to a minimum of gpudata->m_render_mode size + //init to a minimum of gpudata->m_render_mode size if (m_gpudatas.Count() <= gpudata->m_render_mode) { - int i = m_gpudatas.Count(); - int max = gpudata->m_render_mode + 1; + int i = m_gpudatas.Count(); + int max = gpudata->m_render_mode + 1; m_gpudatas.Reserve(max); for (; i < max; i++) m_gpudatas << nullptr; @@ -378,8 +378,8 @@ void GpuEasyMeshData::SetupVertexData(uint16_t vflags, EasyMesh* src_mesh) //----------------------------------------------------------------------------- void GpuEasyMeshData::RenderMeshData(mat4 const &model, int render_mode) { - ASSERT(0 <= render_mode && render_mode < m_gpudatas.Count(), "render mode is not in the defined range"); - ASSERT(m_gpudatas[render_mode], "gpu datas for this render mode don't exist"); + ASSERT(0 <= render_mode && render_mode < m_gpudatas.Count(), "render mode is not in the defined range"); + ASSERT(m_gpudatas[render_mode], "gpu datas for this render mode don't exist"); GpuShaderData& gpu_sd = *(m_gpudatas[render_mode]); int vdecl_idx = 0; diff --git a/src/easymesh/easymeshrender.h b/src/easymesh/easymeshrender.h index dd7e7d87..e85e2eb0 100644 --- a/src/easymesh/easymeshrender.h +++ b/src/easymesh/easymeshrender.h @@ -90,7 +90,7 @@ public: protected: uint16_t m_vert_decl_flags; Shader* m_shader; - int m_render_mode; + int m_render_mode; Array m_shader_uniform; Array m_shader_attrib; }; @@ -121,7 +121,7 @@ public: //--- void AddGpuData(GpuShaderData* gpudata, class EasyMesh* src_mesh); void RenderMeshData(mat4 const &model, int render_mode=Video::GetDebugRenderMode()); - bool HasData(int render_mode) { return (0 <= render_mode && render_mode < m_gpudatas.Count() && !!m_gpudatas[render_mode]); } + bool HasData(int render_mode) { return (0 <= render_mode && render_mode < m_gpudatas.Count() && !!m_gpudatas[render_mode]); } private: void SetupVertexData(uint16_t vdecl_flags, EasyMesh* src_mesh); diff --git a/src/platform/android/androidapp.cpp b/src/platform/android/androidapp.cpp index bd1e603e..2ff70520 100644 --- a/src/platform/android/androidapp.cpp +++ b/src/platform/android/androidapp.cpp @@ -323,7 +323,7 @@ void android_main(android_app* native_app) { int ident, fdesc, events; struct android_poll_source* source; - + ident = ALooper_pollAll(0, &fdesc, &events, (void**)&source); if (ident >= 0 && source)