0

I am using this code...

   iv.setOnClickListener(new View.OnClickListener() {


            @Override
            public void onClick(View v) {

                Intent cameraIntent ;

                    cameraIntent = new Intent(android.provider.MediaStore.ACTION_IMAGE_CAPTURE);
                    startActivityForResult(cameraIntent, CAMERA_REQUEST);


            }
        });

      public void onActivityResult(int requestCode, int resultCode, Intent data) {
        super.onActivityResult(requestCode, resultCode, data);
        if (requestCode == CAMERA_REQUEST && resultCode == Activity.RESULT_OK) {
            Bitmap picture = (Bitmap) data.getExtras().get("data");

            iv.setImageBitmap(picture); 
        }
}

The Image that store to bitmap is very poor clarity. Only 4kb. How can i increase the clarity of the image ?

Arpit Patel
  • 7,212
  • 5
  • 56
  • 67
  • You got this because you get thumbnail image of picture for getting complete image look at http://stackoverflow.com/a/10382217/4684984 also read https://developer.android.com/training/camera/photobasics.html – Multidots Solutions Nov 17 '16 at 05:42
  • try this tutorial https://achorniy.wordpress.com/2010/04/26/howto-launch-android-camera-using-intents/ – Raju Nov 17 '16 at 05:47

1 Answers1

0

Have you tried this line

 cameraIntent.putExtra(MediaStore.EXTRA_OUTPUT, photoURI);

see official doc HERE

Arpit Patel
  • 7,212
  • 5
  • 56
  • 67