I\'m trying the camera preview on my Android applications. When I try on my real devices, it gives me black screen.
This is my code and it doesn\'t throw any error,
Bit of an odd issue I've just found relating to black camera preview. In my case it turned out to be because I had the manifest options
PARTIAL_WAKE_LOCK and also REQUEST_INSTALL_PACKAGES
Why these affect the camera like this I don't know - or whether it's just related to the device I'm using - but removing these permissions resolved my issue. It's taken me 2 hours of stripping a project down to figure out where the issue came in!