diff options
author | Robin Watts <robin.watts@artifex.com> | 2014-01-13 18:11:51 +0000 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2014-01-13 18:20:36 +0000 |
commit | c3305e7280d446737fbad0dba13712385becf7ad (patch) | |
tree | 0ce600578101b976c5b1ce58da1f9c0743c24f15 /source/fitz/time.c | |
parent | a8c6cc692288d6778dfcfe2c29545721e3829b8c (diff) | |
download | mupdf-c3305e7280d446737fbad0dba13712385becf7ad.tar.xz |
Avoid rendering errors caused by linejoins on tiny distances.
If we perform a linejoin that ends up being over an impossibly small
distance, we can get a rendering error. This is caused by trying to
calculate scale = linewidth/sqrtf(len), where len < FLT_EPSILON.
Avoid this by rearranging the code slightly - no extra calculations
required.
Also given that sn == bn at all times within the stroking code, just
remove bn.
Credit for spotting this problem goes to Simon for tracking the
problem with rounding_artifact_due_to_closepath.pdf. My fix just
fixes the problem at a lower level than his does.
Diffstat (limited to 'source/fitz/time.c')
0 files changed, 0 insertions, 0 deletions