elucideye / drishti

Real time eye tracking for embedded and mobile devices.
BSD 3-Clause "New" or "Revised" License
392 stars 82 forks source link

Black screen for DrishtiFaceFilter on Android #750

Open Evizero opened 5 years ago

Evizero commented 5 years ago

I can build the project and push the debug app to the phone successfully (after doing what is outlined in #748 ), yet when I open the DrishtiFaceFilter app on my android phone I only see a black screen.

Any ideas what I can do to debug/fix this?

headupinclouds commented 5 years ago

I'm not sure what is happening, but the black screen output is one of the more common OpenGL errors. What device and Android version are you using?

Have you looked for facefilter errors in logcat?

Can you provide details for the following?

Can you confirm that frame callbacks are being received in the native C++ layer?

I would probably try to cut out the face tracking and display and just test a simple rgb->grayscale shader. You can get this behavior in the demo app by disabling the tracker allocation here:

https://github.com/elucideye/drishti/blob/c4c74f0d6a1741782acc822ee5933e24e17095a4/src/examples/facefilter/lib/facefilter/renderer/Renderer.cpp#L120-L127

It will skip the tracking on each frame here:

https://github.com/elucideye/drishti/blob/c4c74f0d6a1741782acc822ee5933e24e17095a4/src/examples/facefilter/lib/facefilter/renderer/Renderer.cpp#L67-L78

There are a set of unit tests that are managed with the gauze framework. It will install and launch the tests on your device if it is tethered and visible via adb devices. I'm curious if those are passing on your device. It could help to isolate configuration issues in the C++ layer vs application layer problems in the Android app. You can run these by adding -DRISHTI_BUILD_TESTS=ON DRISHTI_HAS_GPU=ON to the cmake build command (--fwd ... in case of polly.py commands).