Bug 433076

Summary: Mirror tool is one pixel off (but not always)
Product: [Applications] krita Reporter: jitspoe
Component: Tool/AssistantsAssignee: Krita Bugs <krita-bugs-null>
Status: RESOLVED DUPLICATE    
Severity: normal CC: tamtamy.tymona, tomtomtomreportingin
Priority: NOR    
Version First Reported In: 4.4.2   
Target Milestone: ---   
Platform: Other   
OS: Other   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description jitspoe 2021-02-17 13:09:08 UTC
SUMMARY
Frequently, when using the mirror tool, the mirrored pixels will be one pixe


STEPS TO REPRODUCE
1. Create a small image (ex: 32x32) to easily observe the issue.
2. Enable the Horizontal Mirror Tool, centered in the image.
3. Select Basic-1 brush and set the scale to something small, like 2px.
4. Draw near the center or edge of the image.

OBSERVED RESULT
Drawn pixels are off by one pixel on the mirrored side.  For example, on the right side, there may be 2 pixels to the center of the image, but on the left side there is only 1.
https://imgur.com/a/NhgEYnG

This does not seem to reproduce on all brushes.  Pixel art brushes seem to mirror correctly.  Sometimes brushes that are normally off by 1 pixel will also mirror correctly.  Behavior is inconsistent.


EXPECTED RESULT
Pixels are mirrored exactly, so a pixel drawn next to the edge will be next to the edge on the mirror.

SOFTWARE/OS VERSIONS
Windows: 10

ADDITIONAL INFORMATION
If this doesn't reproduce, try creating a new document or restarting Krita.  One time all brushes were mirroring properly, but on a later attempt they were off again.
Comment 1 tomtomtomreportingin 2021-03-13 21:18:23 UTC
Can confirm.
Comment 2 Tiar 2021-03-14 00:55:01 UTC

*** This bug has been marked as a duplicate of bug 335238 ***
Comment 3 jitspoe 2021-03-15 06:22:59 UTC
That didn't seem like the same bug, but maybe I'm misunderstanding it.  The image shown on that bug is mirrored and seems to be about sub-pixel precision.  In my case, everything was shifted an entire pixel off.