hey
my bug is java.lang.OutOfMemoryError: bitmap size exceeds VM budget(Heap Size=18695KB, Allocated=14308KB, Bitmap Size=11730KB)
in android >3 it's ok
but in my other device i get this error in
my questions are:
1 is the size is too big - am i doing something wrong? the bmp is 2-3 mega not 11 mega
2 can i get the heap size and Allocated for the device and reduce the bytes array ?
the only solution for now is to reduce the bmp before upload - but then the quality is not good
tank you all
my bug is java.lang.OutOfMemoryError: bitmap size exceeds VM budget(Heap Size=18695KB, Allocated=14308KB, Bitmap Size=11730KB)
in android >3 it's ok
but in my other device i get this error in
B4X:
'Converts a bytes array to an image (for BLOB fields).
Public Sub BytesToImage(bytes() As Byte) As Bitmap
Dim In As InputStream
In.InitializeFromBytesArray(bytes, 0, bytes.Length)
Dim bmp As Bitmap
bmp.Initialize2(In )
Return bmp
End Sub
my questions are:
1 is the size is too big - am i doing something wrong? the bmp is 2-3 mega not 11 mega
2 can i get the heap size and Allocated for the device and reduce the bytes array ?
the only solution for now is to reduce the bmp before upload - but then the quality is not good
tank you all