gpu/shaders: update piet-gpu

Changes:
- faster implementation of RGBA output
- fix stroked clips and images

Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
Elias Naur
2021-03-31 19:55:29 +02:00
parent 5e1a662b94
commit ebf2dcea50
6 changed files with 106 additions and 128 deletions
+2 -2
View File
@@ -48,13 +48,13 @@ void main() {
if (element_ix < conf.n_elements) {
AnnotatedTag tag = Annotated_tag(conf.anno_alloc, ref);
switch (tag.tag) {
case Annotated_Image:
case Annotated_BeginClip:
case Annotated_Color:
if (fill_mode_from_flags(tag.flags) != MODE_NONZERO) {
break;
}
// Fall through.
case Annotated_Image:
case Annotated_BeginClip:
PathRef path_ref = PathRef(conf.tile_alloc.offset + element_ix * Path_size);
Path path = Path_read(conf.tile_alloc, path_ref);
sh_row_width[th_ix] = path.bbox.z - path.bbox.x;