Skip to content

Android and iOS: torchOn parameter does not adequately initialize MlKitView #17

@cjohn001

Description

@cjohn001

I would expect that if I bind a boolean to the torchOn parameter of the MlKitView where torchOn is set to true initially, that the torch then gets enabled when the video stream starts.

Example here:
https://github.com/cjohn001/mlkit-test/blob/2d05bd4ce3e1853ba8c54b69ac5edb053f4c32d9/src/app/item/items.component.ts#L19

Unfortunately, the state of torchOn is not reflected by the MlKitView, The initially state when set to true has not the expected effect. Setting the parameter only has an effect after the video stream was started.
I assume the right way would be that the plugin checks the torchOn state after activating the video stream and depending on state also activates the torch.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions