Set brightness/contrast in video capture using And

2020-06-03 04:45发布

问题:

I made a video capture app with Camera2 API by following this guide,

Is there a provision to change brightness/contrast/exposure settings of the video programatically? I'm trying to capture some low-lit video footage, and I wish to increase the exposure.

The documentation here seems to apply only for still pictures.

Any such way for video capture, using Camera2 API?

回答1:

All the configuration that you need should be in CaptureRequest, for example for brightness here.

So, to implement it with the guide you follow, it's in the part 5. of the main steps listed in the readme, you need to use the CaptureRequest.Builder created here to set all the configuration that you want, with CaptureRequest.Builder#set(Key<T> key, T value) and the fields from CaptureRequest !