Camera : setDisplayOrientation function is not working for Samsung Galaxy ACE with Android 2.3.6

前端 未结 3 660
死守一世寂寞
死守一世寂寞 2020-12-02 19:11

I was trying to create a simple camera application for research. I Read Android Camera Official Document and then started coding. so I did some steps to get it work

3条回答
  •  青春惊慌失措
    2020-12-02 19:42

    I was searching for a solution for hours too. Its really crazy. My solution was to just use the camera preview in landscape mode (in my portrait app) and mask out the parts of the preview I don't need. I did this by overlaying upper and lower pars of my fullscreen preview with some views. Of cause you have to crop the photo you are getting from the camera then, WHICH RESULTS IN LESS RESOLUTION. For my app this was no issue.

    I am totally happy with my solution now- users don't see any difference;

提交回复
热议问题