infinum / Android-GoldenEye

A wrapper for Camera1 and Camera2 API which exposes simple to use interface.
Apache License 2.0
375 stars 53 forks source link

Regarding video recording preview. #47

Open shwetachauhan-simform opened 4 years ago

shwetachauhan-simform commented 4 years ago

Can I remove left and right space while we record video? While record video I want preview in autofit. Is it possible?

domagojkorman commented 4 years ago

Hi @shwetachauhan-simform ,

You should be able to set AUTO_FIT or AUTO_FILL scaling depending on your needs.

https://github.com/infinum/Android-GoldenEye/blob/28d0416602432227d099f6bbf9e2d544401d59ca/goldeneye/src/main/java/co/infinum/goldeneye/config/SizeConfig.kt#L48

previewScale is accessed via config as all other properties.

ShwetaChauhan18 commented 4 years ago

Yes, that’s working after video recording complete but while we are recording video screen width become small and there is black space in left and right?

Is it possible while recording is ongoing? Your library works perfect as per my app requirement only issue is this.

shwetachauhan-simform commented 4 years ago

ok, got it. Thanks @domagojkorman

But if I set

config.previewScale = PreviewScale.AUTO_FILL

on click of start record video preview became zoom