For aliased brushes, treat size between 0 and 1 as 1

Krita’s anti-alias toggle on brush presets has been great for pixel art brushes, but there’s still one problem that affects even the brushes that come in the resource packs: if a brush’s calculated size is below 1 (or maybe 0.5?), it’ll get aliased away to nothingness even if it’s part of a longer brush stroke, causing thin brush strokes to be dotty rather than coherent. The included brushes try to get around this by setting a minimum on the size pressure curve, but this only works well for a specific brush size, and when if one changes the brush size without adjusting the pressure curve, this leads to low-pressure areas that are either full of gaps or are too thick, rather than tapering nicely to 1px as one would hope.

If there was a minimum size on the brush that always kept it visible, it would be much easier to work with pixel art brushes of varying sizes. In the title, I suggested a size of 1, which would work nicely for simple shapes (circles, squares), but not for complex shapes. The ideal solution, I think, would be an absolute minimum size setting that one can adjust according to the intent of the brush, and this could be useful for anti-aliased brushes as well. But, a 1px minimum size for aliased brushes would be a good compromise that works for the most common scenarios.

An illustration of the problem with the current aliasing:

Here I’m using a brush with its minimum pressure set to 10%, so when the brush is at size 10px, the lowest pressures produce a 1px-ish line that looks fine (drawn with light pressure on left). But what if I want a thinner stroke than 10px? The natural thing to do is reduce the brush size, and that’s what I did for the stroke on the right - but whoops, 10% of 3px is very small, so a lot of the pixels in the thin part of the stroke aren’t drawn at all:

So, if I want my 3px brush to make nice lines, I need to change its pressure curve to have a 33% minimum. Beautiful (left)! But what if I then want to draw a thicker shape, say 7px? I increase the brush size (right) and… 33% of that is chunky, I cannot draw a line tapering from 7px to 1px.

For comparison, here are similar strokes drawn in another program, using the same preset and just changing the size (7px and 3px respectively). No gaps, no thick tails, because it aliases differently.

Currently the only ways to always have nice tapering strokes of varying sizes on anti-aliased brushes in Krita are

  • Have presets with different pressure curves for every size one may want to use
  • Get really good at pressure control so you can always use the same large brush even for thin lines

Neither of these is very practical. An absolute minimum size, whether as a setting for all brushes or as a hard-coded 1px for aliased brushes, would be an easier-to-use remedy.

1 Like

Regarding the nice line in the last example, that probably requires this feature request - Pixel perfect line setting for pixel art brushes - Develop / Feature Requests - Krita Artists

2 Likes

When drawing with a tablet, as is implicit for this issue since it deals with pressure curves, Krita already produces nice lines.

(Of course, a pixel-friendly mode would be nice and I support that request! But it’s not required to produce the results in my last example, and is orthogonal to this issue.)

1 Like

In Clip Studio Paint there is a checkbox toggle in the Brush Preset settings to make 1px the smallest size. This is something that could apply to other brush types as well, so there’s one idea.

The reason I mention this is because there are situations where you may want to toggle the 1px setting on and off for aliased brushes.

Image description: The Sub Tool Detail pop up dialog with an aliased G-Pen selected. The Brush Size panel is selected. A checkbox is toggled to specify the brush size should be “At least 1 pixel”.

I previously posted a message:

2 Likes

It would be a good idea if this would be merged with this Feature request?
Btw, i forget to ask @eishiya the other day if this feature request would allow to change or improve the brush engine , more specifically the Pixel engine?
Most of the brushes they are used in Krita, are the ones who have the pixel engine and texture. With this Aliased Brushes would be the ideal?
Because the correct behavior of the Aliased brushes would be the first stroke that you put in this image right?

I always noticed that most of brushes lost the stroke when you reduced the size.
Like you first example.
If its posible can you gave is a mockup image for this feature and how would be work in Krita settings? maybe in the brush editor i guess? Please correct me if i am wrong.