I've been using MKMapSnapshotter to capture image snapshots of maps. In iOS 13 I only get grey boxes. Is anybody else seeing this? Is this a bug or am I doing something wrong?
Here's what I do:
MKMapSnapshotOptions *snapshotterOptions = [MKMapSnapshotOptions new];
snapshotterOptions.region = MKCoordinateRegionMakeWithDistance(coordinate, 300, 300);
snapshotterOptions.mapType = MKMapTypeStandard;
snapshotterOptions.showsPointsOfInterest = NO;
snapshotterOptions.showsBuildings = NO;
snapshotterOptions.size = snapshotSize;
snapshotterOptions.scale = UIScreen.mainScreen.scale;
MKMapSnapshotter *snapshotter = [[MKMapSnapshotter alloc] initWithOptions:snapshotterOptions];
[snapshotter startWithCompletionHandler:^(MKMapSnapshot *snapshot, NSError *error) {
// Some error checking here. The error is nil.
[self saveMapImage:snapshot.image];
}];