Android Question seeking to reduce the size of a picture

mvera

Active Member
Licensed User
Longtime User
hello, continued looking redice one jpg picture, now enconte the following library

https://www.b4x.com/android/forum/threads/advanced-camera-library-v1-00.9383/

but remained unable to lower the weight of a photo that is about 2m

B4X:
Sub Camera1_PictureTaken (Data () As Byte)
   
     camera1.PictureSize (10,10) 'add this
     camera1.Quality = 50 'add this
     camera1.StartPreview
     Dim out As OutputStream

     File.OpenOutput out = (File.DirRootExternal, "Image.jpg", False)
     out.WriteBytes (Data 0, Data.Length)
     out.Close
     ToastMessageShow ("Image saved:" & File.Combine (File.DirRootExternal, "Image.jpg"), True)

   
End Sub
[/ code]

But add camera1.PictureSize and camera1.Quality I do not see any change in the size of the photo.

Thank you.
 
Top