项目
在 GitHub 查看


eonist/HybridCamera
关于
Video and photo camera for iOS
设计与媒体可以做什么
- Records video - 🎥
- takes photos - 📷
- Front / Back camera - ↕️
- Hold to record video - ✊
实测星标增长
- 24小时
- 0
- 7天
- 0
- 15天
- 0
- 1个月
- 正在收集历史
各周期内的星标净变化,周期相互重叠,并非每日新增。缺失的测量保持空白。星标代表关注度,不代表软件质量。
README.md
原文
Features:
| Description | |
|---|---|
| Records video | 🎥 |
| takes photos | 📷 |
| Flash on/off | ⚡ |
| Front / Back camera | ↕️ |
| Hold to record video | ✊ |
| Tap to take photo | 👇 |
| Tap to focus / set exposure | 🔎 |
| Pinch to zoom | 👌 |
| Looping video/photo preview | 🔁 |
| Share button | 🔗 |
| Programatic UI | 🤖 |
| Doesn't stop Spotify | 🎶 |
| Stores files in temporary | 💾 |
| Throw oriented code | 💣 |
| Persistent app authorisation | 🚫 |
| Animated record button | 🔴 |
| Callback based | 📞 |
Why use this camera framework
- High codebeat GPA
- Low class scoped variable count (In order to better handle overall state)
- Setup errors can be handled from the POV of the initiator
- Operation errors is handled in the onCapture completion block
- Callback based (as oppose to delegate based) More info
- Easily styleable (The camera view is separate from the UI view)
- No third-party libraries or Sugar
- Entirely programatic (No storyboard)
- Thoroughly documented (Artifacts and sideEffects etc)
- Uses Sindre-lint style guide
- Small footprint, only ~750 LOC (Lines of code)
Notes:
- In order to keep things simple, The UI is CGRect based. Use your own Autolayout distro like SnapKit etc when adding additional UI
Install:
- SPM:
.package(url: "https://github.com/eonist/HybridCamera.git", .branch("master")) - Manual: Open
HybridCamera.xcodeproj
IMPORTANT: Make sure info.plist has these variables
Privacy - Microphone Usage Description
Privacy - Camera Usage Description
Privacy - Photo Library Additions Usage Description
Example:

Example code:
self.view = HybridCamView()
view.camView.onPhotoCaptureComplete = { (image: UIImage?, url: URL?, error: Error?) in
Swift.print("On photo capture complete \(url)")
}
hybridCamView.camView.onVideoCaptureComplete = { (url: URL?, error: Error?) in
Swift.print("On Video capture complete \(url)")
}
Todo:
- Add support for more orientation modes (Currently only supports portrait)
- Add support for error resolution from the POV of initiating the camera
- Make UI with AutoLayout 👈
- Make lib carthage support ✅
- Fix AudioBug ✅
- Fix FontCamera bug w/ IphoneX ✅
- Add Spatial, Chaplin as an option to HybridCam 👈
- Add CI-Travis 👈
Contributors:
探索相关项目
加载中…