Merge pull request #12828 from NathanWarden/pixel_stretch_fix

Fixed a bug where clamp_uv was clamping one pixel short, stretching the last pixels.
This commit is contained in:
Juan Linietsky 2017-11-12 08:28:55 -03:00 committed by GitHub
commit 46bbe3a541
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -382,7 +382,7 @@ void main() {
if (clip_rect_uv) {
vec2 half_texpixel = color_texpixel_size * 0.5;
uv = clamp(uv,src_rect.xy+half_texpixel,src_rect.xy+abs(src_rect.zw)-color_texpixel_size);
uv = clamp(uv,src_rect.xy,src_rect.xy+abs(src_rect.zw));
}
#endif