COS2614/src/src/threads/life/lifemainwindow.cpp
void stitchReduce(QImage& next, const LifeSlice &slice) {
    if (next.isNull()) 
        next = QImage(boardSize, QImage::Format_Mono);
    QPainter painter(&next);
    painter.drawImage(slice.rect.topLeft(), slice.image);   /* Draw one piece of 
                an image onto another. */
}
//end
//start id=reduce
/** Reduce function */
end
start id=reduce
Reduce function
end start id = reduce Reduce function
void stitchReduce(QImage& next, const LifeSlice &slice) {
    if (next.isNull()) 
        next = QImage(boardSize, QImage::Format_Mono);
    QPainter painter(&next);
    painter.drawImage(slice.rect.topLeft(), slice.image);   
}
void stitchReduce ( QImage & next , const LifeSlice & slice ) { if ( next . isNull ( ) ) next = QImage ( boardSize , QImage :: Format_Mono ) ; QPainter painter ( & next ) ; painter . drawImage ( slice . rect . topLeft ( ) , slice . image ) ; }
end
start id=reduce
Reduce function
end start id = reduce Reduce function
/* Draw one piece of 
                an image onto another. */