Skip to content

Screen Flashlight

Screen Flashlight briefly covers LIQA with a white screen before requesting a full-resolution still photo. It can add light to a face when the user is holding a phone close enough for the display to help.

Enable it with the screen-flashlight attribute:

tsx
tsx
<hautai-liqa license="LICENSE_KEY_PROVIDED_BY_HAUT.AI" preset="face" sources="front_camera" screen-flashlight > </hautai-liqa>
tsx
<hautai-liqa license="LICENSE_KEY_PROVIDED_BY_HAUT.AI" preset="face" sources="front_camera" screen-flashlight > </hautai-liqa>

An empty attribute, screen-flashlight="true", and screen-flashlight="1" enable the feature. Use screen-flashlight="false" or screen-flashlight="0" to disable it. The default is false.

Supported flows

Screen Flashlight is used only when all of these conditions are met:

  • The selected preset is face or face-180.
  • LIQA is capturing from the front camera. In face-180, the feature is applied independently to the front, left, and right captures.
  • The current camera track is live and the browser exposes a working ImageCapture.takePhoto() implementation.

It is not used for the back camera, upload, companion capture, or the hair and photo presets. The same behavior applies in Shadow DOM and use-iframe="true" integrations.

Runtime behavior and fallback

LIQA checks support before showing the white screen. On a supported capture it waits for the white screen to paint, gives the camera exposure 300 ms to react, and then calls ImageCapture.takePhoto().

Browser support alone does not guarantee that every camera driver can complete a still-photo request. LIQA therefore treats Screen Flashlight as best-effort:

  • If the API is unavailable, LIQA uses its regular video-frame capture without showing the white screen.
  • If the still-photo request or image decode fails or takes longer than two seconds, LIQA removes the white screen first and then uses the regular capture path.
  • If the session, camera, or face-180 side changes while a request is running, LIQA discards the stale result instead of attaching it to the new capture.

The still photo is decoded with image orientation applied, center-cropped to the visible camera viewport, kept unmirrored, and limited to LIQA's current capture-resolution envelope and a maximum output dimension of 4096 px.

Browser availability

BrowserFirst version with the required Image Capture API
Chrome on AndroidChrome 59
Safari on iPhone and iPadSafari / iOS / iPadOS 18.4

Chrome documents Image Capture as available from Chrome 59 on Android and desktop. WebKit added the API in Safari 18.4, including Safari on iOS and iPadOS 18.4.

Embedded Android WebViews, iOS WKWebViews, camera drivers, and permission policies can differ from the standalone browsers. LIQA performs runtime detection and falls back automatically; do not use only the browser version to decide whether capture will succeed.

Lighting limitations

Screen Flashlight renders white content but cannot raise the device's hardware brightness. Manual brightness, auto-brightness, Night Shift, True Tone, battery-saving modes, display size, distance from the face, and ambient light all affect the result. It does not activate the physical LED camera flash.

The feature also does not bypass Required Lighting or Photo Quality Check. LIQA still needs to reach its live capture conditions before Screen Flashlight runs, and the captured photo is still evaluated under the configured post-capture policy.