47 int thresholdCount)
const;
71 int fillPass (QImage &image,
72 QVector<PixelFillState> &states,
78 QString hashForCoordinates (
int x,
80 int indexCollapse (
int row,
QMap< QString, bool > HashLookup
Quick lookup table for pixel coordinate hashes processed so far.
PixelFillState
Each pixel transitions from unprocessed, to in-process, to processed.
@ PIXEL_FILL_STATE_UNPROCESSED
@ PIXEL_FILL_STATE_IN_PROCESS
@ PIXEL_FILL_STATE_PROCESSED
QQueue< QPoint > QueuedPoints
void fillIsolatedWhitePixels(QImage &image)
Fill in white pixels surrounded by more black pixels than white pixels.
static bool pixelIsBlack(const QImage &image, int x, int y)
Return true if pixel is black in black and white image.
int countBlackPixelsAroundPoint(const QImage &image, int x, int y, int stopCountAt)
Fill triangle between these three points.
void fillHoles(QImage &image, int thresholdCount)
Fill in white holes, surrounded by black pixels, smaller than some threshold number of pixels.
void fillHole(QImage &image, int row, int col, int thresholdCount) const
Fill white hole encompassing (row,col) if number of pixels in that hole is below the threshold.
Pixels()
Single constructor.