Skip to content

Instantly share code, notes, and snippets.

@Danyaga
Created June 18, 2019 09:29
Show Gist options
  • Save Danyaga/2ea0d8b8c416e8fe6ad18b28c634990e to your computer and use it in GitHub Desktop.
Save Danyaga/2ea0d8b8c416e8fe6ad18b28c634990e to your computer and use it in GitHub Desktop.
override fun onStart() {
super.onStart()
this.goldenEye?.availableCameras
?.find { it.facing == Facing.BACK }
?.run {
this@Activity.goldenEye?.open(
this@Activity.textureView,
this,
onReady = { this@Activity.goldenEye?.config?.flashMode = FlashMode.OFF },
onError = { this@Activity.goldenEye = null }
)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment