1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 13:07:46 +00:00

PixelPaint: Add luminosity masking for editing masks

This adds a function where editing masks can be refined by selecting
a luminosity range that is applied to the content image and mapped to
the editing mask. This function allows the editing of image regions
that match only certain luminosity values.
This commit is contained in:
Torstennator 2023-06-13 15:49:29 +02:00 committed by Jelle Raaijmakers
parent 660d6f171c
commit dbbf54df2c
6 changed files with 317 additions and 0 deletions

View file

@ -0,0 +1,65 @@
@GUI::Frame {
fill_with_background_color: true
layout: @GUI::VerticalBoxLayout {
margins: [4]
}
@GUI::Widget {
layout: @GUI::VerticalBoxLayout {}
@GUI::Label {
name: "hint_label"
enabled: true
fixed_height: 20
visible: true
text: "Restrict mask to luminosity values:"
text_alignment: "CenterLeft"
}
@GUI::HorizontalRangeSlider {
name: "full_masking"
max: 255
min: 0
lower_range: 25
upper_range: 230
page_step: 10
}
@GUI::Widget {
name: "range_illustration"
}
@GUI::HorizontalRangeSlider {
name: "edge_masking"
max: 255
min: 0
lower_range: 0
upper_range: 255
page_step: 10
}
@GUI::CheckBox {
name: "mask_visibility"
text: "Show layer mask"
}
@GUI::HorizontalSeparator {}
}
@GUI::Widget {
layout: @GUI::HorizontalBoxLayout {}
fixed_height: 22
@GUI::Layout::Spacer {}
@GUI::DialogButton {
name: "apply_button"
text: "OK"
}
@GUI::DialogButton {
name: "cancel_button"
text: "Cancel"
}
}
}