Skip to content

Commit

Permalink
#5532: Extend brush interface by IBrush::clear() to remove all faces
Browse files Browse the repository at this point in the history
  • Loading branch information
codereader committed Mar 6, 2021
1 parent 173d857 commit 0ab2977
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
3 changes: 3 additions & 0 deletions include/ibrush.h
Expand Up @@ -231,6 +231,9 @@ class IBrush
// Add a new face to this brush, using the given plane, texdef matrix and shader name
virtual IFace& addFace(const Plane3& plane, const Matrix4& texDef, const std::string& shader) = 0;

// Removes all faces from this brush
virtual void clear() = 0;

// Returns true when this brush has no faces
virtual bool empty() const = 0;

Expand Down
2 changes: 1 addition & 1 deletion radiantcore/brush/Brush.h
Expand Up @@ -255,7 +255,7 @@ class Brush :
void pop_back();
void erase(std::size_t index);

void clear();
void clear() override;

std::size_t getNumFaces() const;

Expand Down

0 comments on commit 0ab2977

Please sign in to comment.