OSDN Git Service
brushlib basic anti-aliasing
Automatically adjust the dab hardness to prevent aliasing.
Most current ink brushes use a low hardness to prevent aliasing, and
are only suitable (fine-tuned) for a given resolution. With this new
code, many brushes can now just set hardness to the maximum (1.0).
Some advanced ink brushes make the hardness depend on speed or pressure,
in order to get better anti-aliasing when the radius changes with
speed or pressure. This is no longer needed and should be disabled
to prevent blur.
Anti-aliasing is enabled by default for all brushes. Existing pixel
brushes and erasers that want to erase 100% and not just 99.9% will
have to disable it.
This is not the perfect anti-aliasing implementation of course; thin
strokes (with radius close to 1px and below) tend to disappear because
of the hardness implementation. This is because the math used in the
implementation is correct mainly for large dabs with high hardness.