B4J Question Switching from native ImageView to B4XImageView degraded image quality

Alessandro71

Well-Known Member
Licensed User
Longtime User
Converting my B4X code from native ImageView to B4XImageView I noticed that on B4J resizing quality is worse
Here's a screen capture for example

ImageView
1623692377874.png


B4XImageView
1623692431796.png


code is pretty simple

B4X:
m_logo = XUIViewsUtils.CreateB4XImageView
m_logo.mBackgroundColor = xui.Color_Transparent
m_logo.Load(File.DirAssets, filename)

As a side note, resize quality showed no difference on B4A, while it actually improved a lot in B4i, compared to native ImageView which was populated with xui.LoadBitmapResize
 

Erel

B4X founder
Staff member
Licensed User
Longtime User
B4XImageView = ImageView + some features.

You are seeing two different ways to scale down the image. By default, B4XImageView keeps the original image size and lets the native ImageView scaling feature. In this case the scaling of B4XBitmap looks a bit better.
You are free to use it:
B4X:
m_logo.Bitmap = xui.LoadBitmapResize(File.DirAssets, filename, m_logopcc.Width, m_logopcc.Height, True)
 
Upvote 0
Top