summaryrefslogtreecommitdiffstats
path: root/scene/resources/multimesh.h
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-03-05 16:44:50 +0100
committerRémi Verschelde <rverschelde@gmail.com>2017-03-05 16:44:50 +0100
commit5dbf1809c6e3e905b94b8764e99491e608122261 (patch)
tree5e5a5360db15d86d59ec8c6e4f7eb511388c5a9a /scene/resources/multimesh.h
parent45438e9918d421b244bfd7776a30e67dc7f2d3e3 (diff)
downloadredot-engine-5dbf1809c6e3e905b94b8764e99491e608122261.tar.gz
A Whole New World (clang-format edition)
I can show you the code Pretty, with proper whitespace Tell me, coder, now when did You last write readable code? I can open your eyes Make you see your bad indent Force you to respect the style The core devs agreed upon A whole new world A new fantastic code format A de facto standard With some sugar Enforced with clang-format A whole new world A dazzling style we all dreamed of And when we read it through It's crystal clear That now we're in a whole new world of code
Diffstat (limited to 'scene/resources/multimesh.h')
-rw-r--r--scene/resources/multimesh.h24
1 files changed, 10 insertions, 14 deletions
diff --git a/scene/resources/multimesh.h b/scene/resources/multimesh.h
index c86b33adcf..1ecf76142a 100644
--- a/scene/resources/multimesh.h
+++ b/scene/resources/multimesh.h
@@ -34,10 +34,10 @@
class MultiMesh : public Resource {
- GDCLASS( MultiMesh, Resource );
+ GDCLASS(MultiMesh, Resource);
RES_BASE_EXTENSION("mmsh");
-public:
+public:
enum TransformFormat {
TRANSFORM_2D = VS::MULTIMESH_TRANSFORM_2D,
TRANSFORM_3D = VS::MULTIMESH_TRANSFORM_3D
@@ -48,26 +48,24 @@ public:
COLOR_8BIT = VS::MULTIMESH_COLOR_8BIT,
COLOR_FLOAT = VS::MULTIMESH_COLOR_FLOAT,
};
+
private:
Ref<Mesh> mesh;
RID multimesh;
TransformFormat transform_format;
ColorFormat color_format;
-
protected:
-
static void _bind_methods();
- void _set_transform_array(const PoolVector<Vector3>& p_array);
+ void _set_transform_array(const PoolVector<Vector3> &p_array);
PoolVector<Vector3> _get_transform_array() const;
- void _set_color_array(const PoolVector<Color>& p_array);
+ void _set_color_array(const PoolVector<Color> &p_array);
PoolVector<Color> _get_color_array() const;
public:
-
- void set_mesh(const Ref<Mesh>& p_mesh);
+ void set_mesh(const Ref<Mesh> &p_mesh);
Ref<Mesh> get_mesh() const;
void set_color_format(ColorFormat p_color_format);
@@ -79,10 +77,10 @@ public:
void set_instance_count(int p_count);
int get_instance_count() const;
- void set_instance_transform(int p_instance, const Transform& p_transform);
+ void set_instance_transform(int p_instance, const Transform &p_transform);
Transform get_instance_transform(int p_instance) const;
- void set_instance_color(int p_instance, const Color& p_color);
+ void set_instance_color(int p_instance, const Color &p_color);
Color get_instance_color(int p_instance) const;
virtual Rect3 get_aabb() const;
@@ -91,11 +89,9 @@ public:
MultiMesh();
~MultiMesh();
-
};
-
-VARIANT_ENUM_CAST( MultiMesh::TransformFormat );
-VARIANT_ENUM_CAST( MultiMesh::ColorFormat);
+VARIANT_ENUM_CAST(MultiMesh::TransformFormat);
+VARIANT_ENUM_CAST(MultiMesh::ColorFormat);
#endif // MULTI_MESH_H