Fix BucketAction.

This commit is contained in:
Relintai 2022-06-21 19:21:50 +02:00
parent 50530c4f79
commit 04a8f1d3d2
2 changed files with 2 additions and 12 deletions

View File

@ -49,7 +49,7 @@ void BucketAction::do_action(PaintCanvas *canvas, const Array &data) {
continue;
}
if (canvas->is_alpha_locked() && col.a < 0.00001) {
if (canvas->is_alpha_locked() && col.a < 0.0001) {
continue;
}

View File

@ -476,17 +476,7 @@ PoolVector2iArray PaintCanvas::get_neighbouring_pixels(const int pos_x, const in
to_check_queue.remove(0);
Vector2i p = PaintUtilities::to_2D(idx, _canvas_width);
bool found = false;
PoolIntArray::Read r = checked_queue.read();
for (int i = 0; i < checked_queue.size(); ++i) {
if (r[i] == idx) {
found = true;
break;
}
}
r.release();
if (!found) {
if (checked_queue.contains(idx)) {
continue;
}