photokit
Safe Rust bindings for Apple's Photos framework on macOS.
Status: v0.2.0 covers
PHAsset,PHAssetCollection,PHCollectionList,PHPhotoLibrary,PHImageManager,PHFetchResult,PHChange,PHContentEditingInput,PHContentEditingOutput,PHObjectChangeDetails,PHFetchOptions,PHAssetCreationRequest,PHLivePhoto, andPHCloudIdentifierthrough a multi-file Swift bridge.
Quick start
use *;
Highlights
PHPhotoLibraryauthorization helpers plus summary/detailed change observers.PHAsset,PHAssetCollection, andPHCollectionListfetch helpers with editable capability checks.PHFetchOptionsandPHFetchResult<T>convenience wrappers for filtering and iteration.PHImageManager/PHCachingImageManagerrequest handles for images, image data, live photos, and caching.PHContentEditingInput/PHContentEditingOutputhandles for non-destructive editing workflows.PHAssetCreationRequestbuilder-style asset creation helpers.PHCloudIdentifierbatch lookup helpers for local/cloud identifier mapping.
Coverage audit
See COVERAGE.md for the framework audit, implemented rows, partial rows, and deferred macOS-unavailable or deprecated APIs.
Examples
The crate ships with numbered examples covering every logical area:
01_photokit_smoke02_phasset_fetch03_phasset_collection_fetch04_phcollection_list_fetch05_phphoto_library_authorization06_phimage_manager_requests07_phfetch_result_methods08_phchange_observer09_phcontent_editing_input10_phcontent_editing_output11_phobject_change_details12_phfetch_options_builder13_phasset_creation_request14_phlive_photo15_phcloud_identifier
Run them with:
for; do
done
Verification
for; do ; done
License
Licensed under either of Apache-2.0 or MIT at your option.