blackberry camera Application
I am implementing camera application using then example comes with blackberry plugin for eclipse named "CameraDemo" the p开发者_JAVA百科roblem is that when the screen loses focus It does not display the camera view istead of it shows like this
has anybody faced such problem whats the solution?This way of taking picture (using the Player
and VideoControl.getSnapshot()
) does not work nice on all BB models. I'd even say it works nice only on a narrow set of BB models. So if you are going to use your app on a wide range of BB models, then this is not the right way to go.
Instead to take a picture use a built-in Camera app. Here is a starting point on how to do that.
Basically you invoke the built-in Camera app and listen for the file-system changes to detect a new image file path. Then you need to close the built-in Camera app somehow - it's possible to do that by simulating two 'Esc' button presses.
Yes, this sounds a bit hacky/over-complicated, but that's how BB engeneers arranged that for us. :) BTW, this is actually not so bad if compare with Android where different device manufactorers violate the common rules and implement the Camera app in their specific way so you are not able to write the code once covering all Androids.
精彩评论