android - Saving Camera Bitmap to Storage, and Setting Image with Bitmap -


i know basics on how take picture , set imageview.

photo = (bitmap) data.getextras().get("data"); imageview.setimagebitmap(photo); 

i want little more that.

i saving folder on sd card. have done this:

// intent intent intent = new intent(mediastore.action_image_capture); intent.putextra(mediastore.extra_output, uri.fromfile(file)); startactivityforresult(intent, camera_request); 

here next question:

not sure how this: i'd next: next time come activity, i'd check if image exists , assign imageview.

last days faced issue in 1 of applications.

i'll try here explain little bitte have done.

  1. try save picture full path storage area or sharedpreferences.
  2. next time if call activity check if picture exists , if can use it.
  3. prepare in xml layout imageview visibility="gone" , if point (2.) true can change visibility visible , set image in view.
  4. if point (2.) false switch camera view (surfaceview) in order take new picture

Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

css - Make div keyboard-scrollable in jQuery Mobile? -

ruby on rails - Seeing duplicate requests handled with Unicorn -