M micro Well-Known Member Licensed User Longtime User Dec 30, 2020 #1 Hi to all i am using the example of erel with canvas to trace the mouse movement on a B4xView(Pane) and save it as Bitmap on a B4xImageView Thi's is the result B4X: Copy imgTrace.Bitmap = cvsDrawing.CreateBitmap then I save the image as a blob in a database B4X: Copy Dim base as String = Base64EncodeDecodeImage.Base64ImageToString2(imgTrace.Bitmap) When I reload the image from the database, I find the black background, classic of a PNG with a transparent background. How can i bring back the Bitmap with a white background? Changing the pixels? And if before capturing the canvas I transform the bitmap into jpeg Thanks to all.
Hi to all i am using the example of erel with canvas to trace the mouse movement on a B4xView(Pane) and save it as Bitmap on a B4xImageView Thi's is the result B4X: Copy imgTrace.Bitmap = cvsDrawing.CreateBitmap then I save the image as a blob in a database B4X: Copy Dim base as String = Base64EncodeDecodeImage.Base64ImageToString2(imgTrace.Bitmap) When I reload the image from the database, I find the black background, classic of a PNG with a transparent background. How can i bring back the Bitmap with a white background? Changing the pixels? And if before capturing the canvas I transform the bitmap into jpeg Thanks to all.
Erel B4X founder Staff member Licensed User Longtime User Dec 31, 2020 #2 Make it white: Code: Copy B4XCanvas.DrawRect(B4XCanvas.TargetRect, xui.Color_White, True, 0) Upvote 0
M micro Well-Known Member Licensed User Longtime User Dec 31, 2020 #3 Erel said: Make it white: Code: Copy B4XCanvas.DrawRect(B4XCanvas.TargetRect, xui.Color_White, True, 0) Click to expand... Thanks Erel, now work fine. Upvote 0
Erel said: Make it white: Code: Copy B4XCanvas.DrawRect(B4XCanvas.TargetRect, xui.Color_White, True, 0) Click to expand... Thanks Erel, now work fine.
TILogistic Expert Licensed User Longtime User Dec 31, 2020 #4 See sample Signature Image to base64 and base64 to Image: B4J and B4A Lienzo para firma electronica con el dedo www.b4x.com Upvote 0
See sample Signature Image to base64 and base64 to Image: B4J and B4A Lienzo para firma electronica con el dedo www.b4x.com