11 CGDataProviderRef data_provider = CGImageGetDataProvider(cgImage);
12 pixel_data_ = CGDataProviderCopyData(data_provider);
16 CFRelease(pixel_data_);
17 CGImageRelease(cg_image_);
21 return CFDataGetBytePtr(pixel_data_);
25 return CGImageGetHeight(cg_image_);
29 return CGImageGetWidth(cg_image_);
33 return CGImageGetBytesPerRow(cg_image_);
39 [NSURL fileURLWithPath:[NSString stringWithUTF8String:
path.c_str()]];
40 CGImageDestinationRef destination = CGImageDestinationCreateWithURL(
41 (__bridge CFURLRef)output_url, kUTTypePNG, 1,
nullptr);
42 if (destination !=
nullptr) {
43 CGImageDestinationAddImage(destination, cg_image_,
44 (__bridge CFDictionaryRef) @{});
46 if (CGImageDestinationFinalize(destination)) {
50 CFRelease(destination);
DEF_SWITCHES_START aot vmservice shared library Name of the *so containing AOT compiled Dart assets for launching the service isolate vm snapshot The VM snapshot data that will be memory mapped as read only SnapshotAssetPath must be present isolate snapshot The isolate snapshot data that will be memory mapped as read only SnapshotAssetPath must be present cache dir path