-
Notifications
You must be signed in to change notification settings - Fork 276
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of #1034 - rlhunt:aligned-clip, r=kvark
Adjust aligned gradient stop colors relative to how much they were clamped Previously we were adjusting the colors relative to the entire rect. Then we adjusted the colors relative to the segment rect. We should be adjusting the colors relative to how much they were clamped. Fixes #1030 <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/webrender/1034) <!-- Reviewable:end -->
- Loading branch information
Showing
4 changed files
with
46 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
--- | ||
root: | ||
items: | ||
# an aligned gradient from [0, 400] | ||
- type: gradient | ||
bounds: 0 0 200 400 | ||
start: 100 0 | ||
end: 100 400 | ||
stops: [0.0, green, 1.0, blue] | ||
# manual clipping | ||
- type: rect | ||
bounds: 0 0 200 100 | ||
color: white | ||
- type: rect | ||
bounds: 0 300 200 100 | ||
color: white |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
--- | ||
root: | ||
items: | ||
# an aligned gradient from [0, 400] and clipped to [100, 300] | ||
- type: gradient | ||
bounds: 0 100 200 200 | ||
start: 100 0 | ||
end: 100 400 | ||
stops: [0.0, green, 1.0, blue] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,7 @@ | ||
== premultiplied-aligned.yaml blank.yaml | ||
== premultiplied-angle.yaml blank.yaml | ||
== premultiplied-radial.yaml blank.yaml | ||
|
||
fuzzy(1,300) == stops.yaml stops-ref.png | ||
|
||
== aligned-clip.yaml aligned-clip-ref.yaml |