[aseprite] 37/51: Fix 'outline' convolution matrices for rendered text
Tobias Hansen
thansen at moszumanska.debian.org
Mon Jul 11 21:35:18 UTC 2016
This is an automated email from the git hooks/post-receive script.
thansen pushed a commit to branch master
in repository aseprite.
commit 71321dfc82ff354a0e0dfe639521e0e76bfa0c28
Author: David Capello <davidcapello at gmail.com>
Date: Fri Jul 1 19:07:01 2016 -0300
Fix 'outline' convolution matrices for rendered text
This issue was originally reported here:
https://twitter.com/vine2D/status/748579114265653248/
---
src/app/util/freetype_utils.cpp | 16 +++++++++++-----
1 file changed, 11 insertions(+), 5 deletions(-)
diff --git a/src/app/util/freetype_utils.cpp b/src/app/util/freetype_utils.cpp
index e4727c5..f8dea74 100644
--- a/src/app/util/freetype_utils.cpp
+++ b/src/app/util/freetype_utils.cpp
@@ -70,14 +70,20 @@ doc::Image* render_text(const std::string& fontfile, int fontsize,
}
}
- doc::put_pixel(
- image, ximg, yimg,
- doc::rgba_blender_normal(
- doc::get_pixel(image, ximg, yimg),
+ int output_alpha = MUL_UN8(doc::rgba_geta(color), alpha, t);
+ if (output_alpha) {
+ doc::color_t output_color =
doc::rgba(doc::rgba_getr(color),
doc::rgba_getg(color),
doc::rgba_getb(color),
- MUL_UN8(doc::rgba_geta(color), alpha, t))));
+ output_alpha);
+
+ doc::put_pixel(
+ image, ximg, yimg,
+ doc::rgba_blender_normal(
+ doc::get_pixel(image, ximg, yimg),
+ output_color));
+ }
}
}
});
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/aseprite.git
More information about the Pkg-games-commits
mailing list