开发者

I want to specify the image filename with EXTRA_OUTPUT but I don't want the full size image

so, the way I read the documentation, using EXTRA_OUTPUT tells the camera to save the file in a specific location. That's great, but it also says to get a full size image. That开发者_StackOverflow中文版's not so great. How can I get just a small image but still specify the filename?


After trying to work with the built-in Camera activity for some time now I can advise you not to expect anything good from it because:

  • built-in activity differs from version to version. For example in 2.2 emulator it even crashes when you try to take a (dummy) picture.
  • Camera activity on real devices like Samsung Galaxy S is different, i.e. it not just looks different, it has different code and set of bugs.
  • Original built-in Camera activity has CROP feature, but it is not part of the public API and thus it is not good idea to use it.

So far I fount that to be safe when working with camera I need to: - create my custom camera activity that misses the fancy stuff like filters, etc but is more configurable (I don't have it yet). I've tried to find third party Camera App but every one of them seems to be targeted at normal users not developers, i.e. has many "cool" features but it is slow / bloated / buggy / has bad UI. - create thumbnail images by myself outside of the Camera activity (for more control).

I really hope that I am missing something here and someone will correct me in the comments with appropriate solution...


I ended up just dealing with the large images by always scaling on the read. It would have been nice not to have to do that as I read in more than one place, but ...oh well...

problem solved, although far from elegant.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜