I\'m using the camera to show preview only (not to take pictures or record videos).
The app is always in portrait mode (landscape mode is disabled). The camera previ
To force portrait orientation:
set android:screenOrientation="portrait" in your AndroidManifest.xml and call camera.setDisplayOrientation(90); before calling camera.startPreview();
I have not tested on the GS2 but it works on every phone I have tested on.
Note: setDisplayOrientation was added in API Level 8