void ofApp::draw(){
// for testing whether the image can display correctly.
// image.draw(0, 0);
for (int i = 0; i < gridSize; i++) {
for (int j = 0; j < gridSize; j++) {
if (grid[i][j]) {
ofSetColor(255);
} else {
ofSetColor(0);
}
ofDrawRectangle(i*cellSize , j*cellSize , cellSize, cellSize);
// ofDrawRectangle(i , j , cellSize, cellSize);
}
}
}