apple sample官方源码

音效处理

混响的wet和dry、声相、速率、声音混合、录制

自定义拍照界面展示

拍照、打开相册、展示图片

加速度计,陀螺仪和设备的运动运动数据的获取

PhotoMap

获取照片的更多信息如地理标记

apple sample官方源码_第1张图片
图片.png
 [queue addOperationWithBlock:^{
            NSData *imageData = [NSData dataWithContentsOfFile:photoPath];
            CGDataProviderRef dataProvider = CGDataProviderCreateWithCFData((CFDataRef)imageData);
            CGImageSourceRef imageSource = CGImageSourceCreateWithDataProvider(dataProvider, NULL);
            NSDictionary *imageProperties = (NSDictionary *)CFBridgingRelease(CGImageSourceCopyPropertiesAtIndex(imageSource,0, NULL));
            
            // check if the image is geotagged
            NSDictionary *gpsInfo = imageProperties[(NSString *)kCGImagePropertyGPSDictionary];
            if (gpsInfo) {
                CLLocationCoordinate2D coord;
                coord.latitude = [gpsInfo[(NSString *)kCGImagePropertyGPSLatitude] doubleValue];
                coord.longitude = [gpsInfo[(NSString *)kCGImagePropertyGPSLongitude] doubleValue];
                if ([gpsInfo[(NSString *)kCGImagePropertyGPSLatitudeRef] isEqualToString:@"S"])
                    coord.latitude = coord.latitude * -1;
                if ([gpsInfo[(NSString *)kCGImagePropertyGPSLongitudeRef] isEqualToString:@"W"])
                    coord.longitude = coord.longitude * -1;
                
                NSString *fileName = [[photoPath lastPathComponent] stringByDeletingPathExtension];
                PhotoAnnotation *photo = [[PhotoAnnotation alloc] initWithImagePath:photoPath title:fileName coordinate:coord];
                
                @synchronized(photos) {
                    [photos addObject:photo];
                }
            }
            
            if (imageSource)
                CFRelease(imageSource);

            if (imageProperties)
                CFRelease(CFBridgingRetain(imageProperties));
            
            if (dataProvider)
                CFRelease(dataProvider);
        }];
    }
    
    [queue waitUntilAllOperationsAreFinished];

HLS直播demo

你可能感兴趣的:(apple sample官方源码)