java - Android 2.2 front camera -
android 2.2 want open front camera , take picture. use code:
private camera getfrontcamera() { camera camera = camera.open(); if (camera == null) { return null; } packagemanager pm = context.getpackagemanager(); if (pm.hassystemfeature("android.hardware.camera.front")) { parameters params = camera.getparameters(); params.set("camera-id", 2); camera.setparameters(params); } return camera; }
but since have not worked. how enable front camera on android 2.2?
there no android 2.2 phones shipped front facing camera - first android phones did have front facing camera started android 2.3 - gingerbread per new features of android 2.3.
Comments
Post a Comment