DSP

iOS框架介绍——A字头

2019-07-13 16:30发布

1、Accelerate: contains C APIs for vector and matrix math, digital signal processing, large number handling, and image processing。 包含加速数学和DSP函数。 详细:https://developer.apple.com/library/ios/documentation/Accelerate/Reference/AccelerateFWRef/index.html 2、Accounts: The Accounts framework provides access to user accounts stored in the Accounts database. An account stores the login credentials of a particular service, such as Twitter, that can be used as authentication for the service. By implementing the Accounts framework into your app, you do not need to be responsible for storing account logins yourself. Instead, the user can grant access for your app to use their account login credentials, bypassing the need to type their username and password. If no account for a particular service exists in the user’s Accounts database, you can let them create and save an account from within your app。 包含了管理用户系统账户访问的接口。
3、AddressBook: provides access to a centralized contacts database, called the Address Book database, that stores a user’s contacts. Applications such as Mail and Messages use this database to present information about known and unknown persons.IOS9过期,替代者Contacts。
包含了直接访问用户联系人数据库的功能。 https://developer.apple.com/library/ios/documentation/AddressBook/Reference/AddressBook_iPhoneOS_Framework/index.html#//apple_ref/doc/uid/TP40007212
4、AddressBookUI: provides controllers that facilitate displaying, editing, selecting, and creating records in the Address Book database.IOS9过期,替代都ContactsUI。 包含了显示系统定义的联系人选择器和编辑器接口的类。 https://developer.apple.com/library/ios/documentation/AddressBookUI/Reference/AddressBookUI_Framework/index.html#//apple_ref/doc/uid/TP40007082
5、AdSupport: provides apps with access to an identifier that can be used only for serving advertisements, as well as a flag which indicates whether a user has limited ad tracking. Accessing the advertising identifier requires apps to read and honor the opt-out flag。
包含了收集分析的类。
6、ApplicationServices: 应用服务器类。
7、AssetsLibrary: access the pictures and videos managed by the Photos application。IOS9过期,替代者Photos。
包含了访问用户照片和视频的类。 https://developer.apple.com/library/ios/documentation/AssetsLibrary/Reference/AssetsLibraryFramework/index.html#//apple_ref/doc/uid/TP40009730 访问相片顺序:  ALAssetsLibrary->ALAssetsGroup->ALAsset->ALAssetRepresentation->CGImageRef 其中ALAssetsLibrary为相片库,ALAssetsGroup为相册,ALAsset为单个照片资源,ALAssetRepresentation为照片的描述,CGImageRef为照片。 首先在ALAssetsLibrary中按ALAssetsGroupAll遍历ALAssetsGroup,得到各个相册;接着在ALAssetsGroup中拿个相片资源;最后取出照片。 在众多相片中如何访问最近的相片呢?
先来打印ALAssetsGroupName:QQ, Type:Album, Assets count:8 (相册名,类型,相片数量)。
在众多相册中,有一个相册最重要,即所有相册的合集:Name:相机胶卷, Type:Saved Photos, Assets count:100  也许名称不一样,但类型一定是“Saved Photos”,因此,使用 [group.description rangeOfString:@"Saved Photos"].location!=NSNotFound, 查找主相册,在其中NSEnumerationReverse(逆顺遍历即可拿到最新的照片)。 取照片:[UIImage imageWithCGImage:[[asset defaultRepresentation] fullScreenImage]],
assetALAsset已经是单张相片的资源文件了。 最后奉上代码: __block NSMutableArray *albumArr = [NSMutableArray array];
        __block ALAssetsLibrary *asslib = [[ALAssetsLibrary alloc]init];
        [asslib enumerateGroupsWithTypes:ALAssetsGroupAll usingBlock:^(ALAssetsGroup *group, BOOL *stop) {
            if(group && ([group.description rangeOfString:@"Saved Photos"].location!=NSNotFound))
            {
                [group enumerateAssetsWithOptions:NSEnumerationReverse usingBlock:^(ALAsset *result, NSUInteger index, BOOL *stop) {
                    
                    NSString *picstr = [result valueForProperty:ALAssetPropertyType];
                    if ([picstr isEqualToString:ALAssetTypePhoto]) {
                      
                        UIImage *img = [[UIImage alloc]initWithCGImage:[[result defaultRepresentation] fullScreenImage]];
                        if (img) {
                            [albumArr addObject:img];
                            
                        }
                        if (albumArr.count>4) {
                            return  ;
                        }
                        
                    }
                }];
            }
            if (albumArr.count>4) {
                return  ;
            }
        } failureBlock:^(NSError *error) {
            NSLog(@"enumerateGroupsWithTypes failureBlock");
        }];
 
8、AudioToolbox: provides interfaces for recording, playback, and stream parsing. In iOS, the framework provides additional interfaces for managing audio sessions
包含了处理音频流数据和播放、录制音频的接口。 https://developer.apple.com/library/ios/documentation/MusicAudio/Reference/CAAudioTooboxRef/index.html#//apple_ref/doc/uid/TP40002089
9、AudioUnit: provides interfaces for using built-in and custom audio processing plug-ins, known as audio units. In iOS, your application can use the built-in audio units. In OS X, your application can use any built-in or custom audio unit, including those from third parties.
包含加载并使用音频单元的接口。 https://developer.apple.com/library/ios/documentation/AudioUnit/Reference/AudioUnit_Framework/index.html#//apple_ref/doc/uid/TP40007295
10、AVFoundation: an Objective-C interface for managing and playing audio-visual media in iOS and OS X applications。
包含了播放和录制音视频的Objective-C接口。 https://developer.apple.com/library/ios/documentation/AVFoundation/Reference/AVFoundationFramework/index.html#//apple_ref/doc/uid/TP40008072
11、AVKit: provides a high-level interface for playing video content。
包含播放或录制音频的Objective-C接口。 https://developer.apple.com/library/ios/documentation/AVKit/Reference/AVKitFramework/index.html#//apple_ref/doc/uid/TP40013178