[![CI Status](http://img.shields.io/travis/Pedro Fabrino/Findr.svg?style=flat)](https://travis-ci.org/Pedro Fabrino/Findr)
Findr was developed in a AIS Hackathon
Findr is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod "Findr" , :git => 'https://github.com/fatalhck/findr/releases/tag/0.4.2'
Lucas Neves, Pedro Fabrino, Jonathan Nobre
Victor Cotrim Luciano Almeida
- Create a Capture Session with FindrViewController and verify if result don't have any error
let result = FindrViewController.createCaptureSession()
if result.error != nil {
// present alert error
return
}
- Create an empty FindrAnottation array
- Create an FindrAnottation and seed this with location, title and active then
let annotation = FindrAnnotation()
annotation.location = some CLLocation object
annotation.title = some title
annotation.active = true
- Append annotation to empty FindrAnnotations array
- Init FindrViewController and set the data source to self
let arViewController = FindrViewController()
arViewController.dataSource = self
- Set the FindrAnottations array to instanciated FindrViewController
arViewController.setAnnotations(annotations)
- Present then
self.present(arViewController, animated: true, completion: nil)
- Make an extension of ARDataSource and implements this method:
func ar(_ findrViewController: FindrViewController, viewForAnnotation: FindrAnnotation) -> FindrAnnotationView {
let annotation = FindrAnnotationView(frame: YOUR FRAME CONFIGURATION)
annotation.backgroundColor = UIColor.red
annotation.annotation = viewForAnnotation
return annotation
}
Findr is available under the MIT license. See the LICENSE file for more info.