diff options
Diffstat (limited to 'scene/resources/mesh.h')
-rw-r--r-- | scene/resources/mesh.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/scene/resources/mesh.h b/scene/resources/mesh.h index 8b1936ed06..e441b4924a 100644 --- a/scene/resources/mesh.h +++ b/scene/resources/mesh.h @@ -6,6 +6,7 @@ /* http://www.godotengine.org */ /*************************************************************************/ /* Copyright (c) 2007-2017 Juan Linietsky, Ariel Manzur. */ +/* Copyright (c) 2014-2017 Godot Engine contributors (cf. AUTHORS.md) */ /* */ /* Permission is hereby granted, free of charge, to any person obtaining */ /* a copy of this software and associated documentation files (the */ @@ -128,6 +129,8 @@ private: void _recompute_aabb(); protected: + virtual bool _is_generated() const { return false; } + bool _set(const StringName &p_name, const Variant &p_value); bool _get(const StringName &p_name, Variant &r_ret) const; void _get_property_list(List<PropertyInfo> *p_list) const; @@ -189,6 +192,20 @@ public: ~Mesh(); }; +class QuadMesh : public Mesh { + + GDCLASS(QuadMesh, Mesh) + +protected: + virtual bool _is_generated() const { return true; } + static void _bind_methods(); + +public: + void set_material(const Ref<Material> &p_material); + Ref<Material> get_material() const; + QuadMesh(); +}; + VARIANT_ENUM_CAST(Mesh::ArrayType); VARIANT_ENUM_CAST(Mesh::PrimitiveType); VARIANT_ENUM_CAST(Mesh::BlendShapeMode); |