Hello, this function is to read the picture repeatedly, and when the panorama is too large, it will lead to running.
Can be optimized, just read once and then go. will be run faster.
originalPixels, err := worker.GetPixels(reader)
if err != nil {
panic(err)
os.Exit(2)
}
log.Printf("read file: %v ---> finished", originalImagePath)
for _, tileName := range tileNames {
tile := worker.Tile{TileName: tileName, TileSize: tileSize}
go worker.Worker(originalPixels, tile, cacheResult, originalImagePath, done)
}
And how to slove sawtooth

