Useful open source libraries for IPhone Development

December 21st, 2008 / in IPhone / by keremk /

It’s been almost 3 months since the IPhone SDK’s infamous NDA restrictions were lifted, and there are now a good set of open source libraries available for the IPhone. In this post I will go through the ones that I know of one way or another. If you are aware of more high quality open source projects, please let me know in the comments so that I can update this post.

JSON Library

Currently, there are 3 choices that I know of:

JSON Framework: I used this one in one of my projects, and did not run into problems. Recently after the update to the new SDK 2.2, you may need to make a quick change to your project as outlined at the end of this discussion.

Touch JSON: This one is from the same project owners as the TouchXML.

Blake Seely’s BSJSONAdditions: This one is little older and intended for the Mac originally. According to the author of the JSON Framework a little slower as per his performance benchmarks

DOM XML Library

IPhone SDK includes an event driven (SAX based) XML parser called NSXMLParser. But if you need DOM style parser, you are out of luck unless you use the libxml2 library directly. There is no MacOS X equivalent of NSXML on the IPhone.

However luckily there are at least 2 options that I know of that you might use if you really need the DOM tree:

TouchXML: Open source lightweight replacement for Cocoa’s NSXML cluster of classes based on libxml2.

Matt Gallagher: Wrote a lightweight wrapper on top of libxml2 and describes this in his blog entry.

However note that in a memory and CPU constrained environment like IPhone, it does make more sense to use an event driven parser (probably why Apple decided not to include NSXML in the first place). There is a recent SDK sample called XMLPerformance that shows parsing large number of items in an efficient way using both the NSXMLParser and the lower level SAX parser provided in libxml2.

Google Data APIs

So you would like to access Picasa, Google Calendar, Google Contacts and more… Well there is a very comprehensive ObjectiveC Client Library that you can include as a static library in your applications.

Twitter

Craig Hockenberry of the awesome Twitterific fame, made the source code of the Mobile Twitterific available to serve as a “Best Practices” document. There you can find how to connect to Twitter, get and post tweets etc.

Flickr

Unfortunately the well-known Cocoa API for Flickr is still not ported to the IPhone. However it looks like they are working on porting it to IPhone as of November 2008.

Game Engines

There are at least 3 game engines that I know of:

2D Gaming - Cocos 2D: This one is intended for 2D games, demos and other graphical/interactive applications. It is a port from the Python based cocos2d design. It uses Open ES 1.1, instead of the Quartz 2D and integrates the Chipmunk 2d physics engine.

3D Gaming - SIO2 Interactive: A 3D engine written in C using OpenGL ES.

3D Gaming - Oolong Engine: Mainly written in C++ with some ObjectiveC. Based on OpenGL ES 1.1 and includes the Bullet 3D physics engine.

You can also take a look at some IPhone game source code:

Tris: The source code for the Tetris clone that was pulled out of the Appstore earlier.

Molecules: This is not a game, but serves as a good tutorial for OpenGL ES development.

Unit Testing and Mock Frameworks

As of IPhone SDK 2.2, Apple now includes the OCUnit. This was discussed in the Stanford IPhone Application Programming course and you can download the presentation and the sample. So right of the bat you are now set up for unit testing, no more excuses.

Google actually has a more comprehensive framework in their Google Toolbox for Mac that even includes support for UI testing.

There is also a mock object framework called OCMock that is designed for MacOS X Cocoa, but with a little bit of work you can get that to work for your IPhone projects.

 

 

 

原文出处:http://www.codingventures.com/2008/12/useful-open-source-libraries-for-iphone-development/

root@CHUN:~# sudo amdgpu-install --list-usecase If --usecase option is not present, the default selection is "dkms,graphics,opencl,hip" Available use cases: dkms (to only install the kernel mode driver) - Kernel mode driver (included in all usecases) graphics (for users of graphics applications) - Open source Mesa 3D graphics and multimedia libraries multimedia (for users of open source multimedia) - Open source Mesa 3D multimedia libraries workstation (for users of legacy WS applications) - Open source multimedia libraries - Closed source (legacy) OpenGL rocm (for users and developers requiring full ROCm stack) - OpenCL (ROCr/KFD based) runtime - HIP runtimes - Machine learning framework - All ROCm libraries and applications wsl (for using ROCm in a WSL context) - ROCr WSL runtime library (Ubuntu 22.04 only) rocmdev (for developers requiring ROCm runtime and profiling/debugging tools) - HIP runtimes - OpenCL runtime - Profiler, Tracer and Debugger tools rocmdevtools (for developers requiring ROCm profiling/debugging tools) - Profiler, Tracer and Debugger tools amf (for users of AMF based multimedia) - AMF closed source multimedia library lrt (for users of applications requiring ROCm runtime) - ROCm Compiler and device libraries - ROCr runtime and thunk opencl (for users of applications requiring OpenCL on Vega or later products) - ROCr based OpenCL - ROCm Language runtime openclsdk (for application developers requiring ROCr based OpenCL) - ROCr based OpenCL - ROCm Language runtime - development and SDK files for ROCr based OpenCL hip (for users of HIP runtime on AMD products) - HIP runtimes hiplibsdk (for application developers requiring HIP on AMD products) - HIP runtimes - ROCm math libraries - HIP development libraries openmpsdk (for users of openmp/flang on AMD products) - OpenMP runtime and devel packages mllib (for users executing machine learning workloads) - MIOpen hip/tensile libraries - Clang OpenCL - MIOpen kernels mlsdk (for developers executing machine learning workloads) - MIOpen development libraries - Clang OpenCL development libraries - MIOpen kernels asan (for users of ASAN enabled ROCm packages) - ASAN enabled OpenCL (ROCr/KFD based) runtime - ASAN enabled HIP runtimes - ASAN enabled Machine learning framework - ASAN enabled ROCm libraries 怎么执行全部安装
最新发布
06-04
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值