HMS Camera Engine with Super Night Mode

Bayar Şahintekin
Huawei Developers
Published in
2 min readDec 28, 2020

Hello everyone ,

I will introduce you the Camera Engine Super Night Mode in this article .

First of all I want to tell about Super Night Mode ;

Super Night Mode is used for you to take photos with sufficient brightness by using a long exposure at night. It also helps you to take photos that are properly exposed in other dark environments.

Basically you can take great photo in dark .

Integration Process

1. HMS Core Integration

You need to integrate HMS Core to your project. This is mandatory.

You can follow this steps to integrate HMS Core to into you project :

2. Camera Engine Implementation

After HMS Core integration you need to add this implementation to your gradle for using all Camera Engine capabilities.

Development Process

1. Creating Camera View

This view provide us run camera into our application.

2. Initialize Camera Kit

First , we need to an instance from Camera Kit for all operations.

3. Create Mode

We need a mode to using all capabilities. This come is so imortant . Every operation run with this mode. When creating mode we are giving Mode.Type.SUPER_NIGHT_MODE .

While we crating mode we will need this callback for tracking mode status.

in onCreate() method we can obtain mode object. There are other status method.

4. Configure Mode

After creating mode we need o configure mode .

We need 2 callback for tracking mode configuration

5. Capture Picture

Finally we are ready to capture super night mode image.

mMode!!.takePicture()

Summary

We can capture wonderful images in dark by using Camera Engine Super Night Mode. All we need these steps;

  1. Integrate HSM Core
  2. Integrate Camera Engine
  3. Create an Instance from Camera Kit
  4. Create a Mode
  5. Configure Mode
  6. Capture Image.

Result

Before:

After:

References

Demo Project :

--

--