Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/younatics/MediaBrowser

🏞 A simple iOS photo and video browser with optional grid view, captions and selections written in Swift5.0
https://github.com/younatics/MediaBrowser

gallery media photo photobrowser swift5 video

Last synced: 10 days ago
JSON representation

🏞 A simple iOS photo and video browser with optional grid view, captions and selections written in Swift5.0

Awesome Lists containing this project

README

        

![title](https://github.com/younatics/MediaBrowser/blob/master/Images/MediaBrowser_w.png?raw=true)


License: MIT
Swift
iOS 8.1+
CocoaPods
CocoaDocs
Carthage
ReadMe-KR

## Intoduction
🏞 **MediaBrowser**λŠ” `UIImage`, `PHAsset` λ˜λŠ” `URLs`을 μ‚¬μš©ν•˜λŠ” `라이브러리 Assets`, `μ›Ή λΉ„λ””μ˜€/이미지` λ˜λŠ” `둜컬 파일`을 ν•˜λ‚˜ μ΄μƒμ˜ μ‚¬μ§„μ΄λ‚˜ μ˜μƒλ₯Ό 보여 μ€λ‹ˆλ‹€.
MediaBrowserλŠ” μ›Ήμ—μ„œ μ‚¬μ§„μ˜ λ‹€μš΄λ‘œλ“œ 및 캐싱을 μ²˜λ¦¬ν•©λ‹ˆλ‹€. 사진을 ν™•λŒ€ μΆ•μ†Œν• μˆ˜ 있으며 μΊ‘μ…˜μ„ 선택 ν• μˆ˜ μžˆμŠ΅λ‹ˆλ‹€. μ‚¬μš©μžκ°€ 메인 μ΄λ―Έμ§€λ·°λ‚˜ κ·Έλ¦¬λ“œμ—μ„œ ν•˜λ‚˜ μ΄μƒμ˜ 사진을 선택 ν• μˆ˜ μžˆλŠ”λ°μ—λ„ μ“Έμˆ˜ μžˆμŠ΅λ‹ˆλ‹€.

λ˜ν•œ λ―Έλ””μ–΄λΈŒλΌμš°μ €λŠ”
Also, MediaBrowser 캐싱에 λŒ€ν•΄μ„œ [SDWebImage](https://github.com/rs/SDWebImage) μ΅œμ‹  버전을 μ‚¬μš©ν•˜λ©°, [MWPhotoBrowser](https://github.com/mwaterfall/MWPhotoBrowser)에 영ν–₯을 λ°›μ•˜μŠ΅λ‹ˆλ‹€.

| Single Photo | Multiple Photos And Video |
| ------------- | ------------------------ |
| ![SinglePhoto](https://github.com/younatics/MediaBrowser/blob/master/Images/SinglePhoto.gif?raw=true) | ![MultiplePhotosAndVideo](https://github.com/younatics/MediaBrowser/blob/master/Images/MultiplePhotosAndVideo.gif?raw=true) |
| Multiple Photo Grid | Multiple Photo Selection |
| ![MultiplePhotoGrid](https://github.com/younatics/MediaBrowser/blob/master/Images/MultiplePhotoGrid.gif?raw=true) | ![PhotoSelection](https://github.com/younatics/MediaBrowser/blob/master/Images/PhotoSelection.gif?raw=true) |
| Web Photos | Web Photos Grid |
| ![WebPhotos](https://github.com/younatics/MediaBrowser/blob/master/Images/WebPhotos.gif?raw=true) | ![WebPhotoGrid](https://github.com/younatics/MediaBrowser/blob/master/Images/WebPhotoGrid.gif?raw=true) |

## Requirements
`MediaBrowser` λŠ” μŠ€μœ„ν”„νŠΈ 3으둜 μž‘μ„± λ˜μ—ˆμœΌλ©° iOS 8.1이상이 μš”κ΅¬ λ©λ‹ˆλ‹€.

## μ‚¬μš©λ²•
### κΈ°λ³Έ

Get `MediaBrowser` and set `MediaBrowserDelegate`
```Swift
let browser = MediaBrowser(delegate: self)
self.navigationController?.pushViewController(browser, animated: true)

//MediaBrowserDelegate
func numberOfMedia(in mediaBrowser: MediaBrowser) -> Int {
return mediaArray.count
}

func media(for mediaBrowser: MediaBrowser, at index: Int) -> Media {
if index < mediaArray.count {
return mediaArray[index]
}
return DemoData.localMediaPhoto(imageName: "MotionBookIcon", caption: "Photo at index is Wrong")
}
```

## μ„€μΉ˜λ²•
### Cocoapods
```ruby
pod 'MediaBrowser'
```
### Carthage
```
github "younatics/MediaBrowser"
```

## References
#### μ• ν”Œλ¦¬μΌ€μ΄μ…˜μ—μ„œ μ‚¬μš©ν•˜μ‹ λ‹€λ©΄ PRν•΄μ£Όμ‹œκ±°λ‚˜ μ•Œλ €μ£Όμ„Έμš”

## Updates
μ—…λ°μ΄νŠΈ 상세 사항은 [CHANGELOG](https://github.com/younatics/MediaBrowser/blob/master/CHANGELOG.md)λ₯Ό μ°Έκ³ ν•΄μ£Όμ„Έμš”

## Author
[younatics πŸ‡°πŸ‡·](http://younatics.github.io)

## License
**MediaBrowser**λŠ” MITλΌμ΄μ„ΌμŠ€λ₯Ό λ”°λ¦…λ‹ˆλ‹€. [LICENSE](https://github.com/younatics/MediaBrowser/blob/master/LICENSE)λ₯Ό μ°Έκ³  ν•΄μ£Όμ„Έμš”