Skip to content

Instantly share code, notes, and snippets.

@salmaanahmed
Created January 28, 2019 12:49
Show Gist options
  • Save salmaanahmed/f501bdf6c899d81bd4a8b9e76019db94 to your computer and use it in GitHub Desktop.
Save salmaanahmed/f501bdf6c899d81bd4a8b9e76019db94 to your computer and use it in GitHub Desktop.
func processImageData(completionBlock: (result: Image) -> Void) {
loadWebResource("dataprofile.txt") { dataResource in
loadWebResource("imagedata.dat") { imageResource in
decodeImage(dataResource, imageResource) { imageTmp in
dewarpAndCleanupImage(imageTmp) { imageResult in
completionBlock(imageResult)
}
}
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment