Opening Flashlight of Galaxy Nexus

后端 未结 3 588
日久生厌
日久生厌 2020-12-29 13:50

I am developing an app which needs to open the flashlight of my Galaxy Nexus device. I have referred to the post here

LED flashlight on Galaxy Nexus controllable by

相关标签:
3条回答
  • 2020-12-29 14:20

    You need to add this tag in manifest file.

    <uses-feature android:name="android.hardware.camera.flash"/>
    
    0 讨论(0)
  • 2020-12-29 14:24

    you must to set call back mHolder.addCallback(this);

    0 讨论(0)
  • 2020-12-29 14:46

    Try to add :

    android:name="android.permission.FLASHLIGHT"
    android:name="android.hardware.camera.flash
    

    And look this post : How to turn on camera flash light programmatically in Android?

    0 讨论(0)
提交回复
热议问题