gpt4 book ai didi

iOS8。照片应用程序错误?

转载 作者:塔克拉玛干 更新时间:2023-11-02 20:03:43 25 4
gpt4 key购买 nike

当我在 IOS8 的标准照片应用程序中使用滤镜时,我无法获得完整的元数据。我尝试了两种获取元数据的方法:

[manager requestImageDataForAsset:asset options:options resultHandler:^(NSData *imageData, NSString *dataUTI, UIImageOrientation orientation, NSDictionary *info) {
CIImage *ciimage = [CIImage imageWithData:imageData];
NSMutableDictionary *exif = [NSMutableDictionary dictionary];
[exif addEntriesFromDictionary:ciimage.properties];
}];

[asset requestContentEditingInputWithOptions:editOptions completionHandler:^(PHContentEditingInput *contentEditingInput, NSDictionary *info) {
CIImage *cimage = [CIImage imageWithContentsOfURL:contentEditingInput.fullSizeImageURL];
NSMutableDictionary *exif = [NSMutableDictionary dictionary];
[exif addEntriesFromDictionary:cimage.properties];
}];

我没有发现任何提及应用程序照片的信息。我得到这样的结果总是:

{
ColorModel = RGB;
DPIHeight = 72;
DPIWidth = 72;
Depth = 8;
Orientation = 1;
PixelHeight = 2592;
PixelWidth = 1936;
"{Exif}" = {
ColorSpace = 1;
PixelXDimension = 1936;
PixelYDimension = 2592;
};
"{JFIF}" = {
DensityUnit = 1;
JFIFVersion = (
1,
0,
1
);
XDensity = 72;
YDensity = 72;
};
"{TIFF}" = {
Orientation = 1;
};

有没有人找到解决方案来获取已在照片中编辑过的图像的元数据?

我想看到这样的元数据:

link

最佳答案

我找到了如何获取原始元数据:

PHImageRequestOptions *options = [PHImageRequestOptions new];
options.networkAccessAllowed = YES;
options.synchronous = YES;
options.version = PHImageRequestOptionsVersionOriginal;

[manager requestImageDataForAsset:asset options:options resultHandler:^(NSData *imageData, NSString *dataUTI, UIImageOrientation orientation, NSDictionary *info) {
CIImage *ciimage = [CIImage imageWithData:imageData];
NSMutableDictionary *exif = [NSMutableDictionary dictionary];
[exif addEntriesFromDictionary:ciimage.properties];
}];

关于iOS8。照片应用程序错误?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/26099830/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com