Bug 367943 - In wrap-around mode, dragging a brush with sharpness above or left of canvas is offset by half a pixel.
Summary: In wrap-around mode, dragging a brush with sharpness above or left of canvas ...
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Brush engines (show other bugs)
Version: 3.0.1 Beta
Platform: Appimage Linux
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-08-29 03:49 UTC by Patrick McCarthy
Modified: 2017-11-30 16:51 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
(Video example) (748.37 KB, video/mp4)
2016-08-31 06:51 UTC, mvowada
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick McCarthy 2016-08-29 03:49:21 UTC
When in wrap-around mode, and using a Pixel-type brush that has Sharpness enabled, if you click-drag a brush at a negative coordinate (eg, left or above the main canvas), it will draw at a half pixel offset from that location. This is very, very noticeable with deevad's 5b pixel brush from his recent v8 brush set, and easily tested with it.

If you just do a single click and release, it draws at the correct position.


Reproducible: Always

Steps to Reproduce:
1. Turn on wrap-around mode.
2. Zoom in to something ridiculous like 1600%, to make the bug more apparent.
3. Use a brush with Sharpness enabled. Any strength is okay. deevad's 5b pixel brush works for this.
4. Click-drag on a pixel in negative coordinate space, either above or left of the main canvas. It will be offset.
Comment 1 mvowada 2016-08-31 06:51:30 UTC
Created attachment 100855 [details]
(Video example)

I think I can confirm this behaviour ("Krita 3.0.1 beta" and "Krita 2.9.6" on Ubuntu 14.04 Unity). It happens to me with:

    - grid brushes, 
    - when in wrap around mode,
    - at the far left / top / right sides of the canvas.

Apparently no issues at the far right-bottom side of the canvas. No problems with pixel engine brushes on all sides.
Comment 2 Alvin Wong 2017-11-30 16:51:36 UTC
Git commit b2c4e87d35ab1d04e9cbdc4889b0e93537b638a1 by Alvin Wong.
Committed on 30/11/2017 at 16:46.
Pushed by alvinwong into branch 'master'.

Fix rounding in wrap around mode for KisPainter

This fixes some of the rounding errors with negative coordinates when
painting, for example the pixel brush.
Differential Revision: https://phabricator.kde.org/D8898

M  +79   -86   libs/image/kis_painter.cc

https://commits.kde.org/krita/b2c4e87d35ab1d04e9cbdc4889b0e93537b638a1