maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   MeeGo / Harmattan (https://talk.maemo.org/forumdisplay.php?f=45)
-   -   QML Image show bad gradient quality (https://talk.maemo.org/showthread.php?t=83784)

Amine27 2012-04-20 21:09

QML Image show bad gradient quality
 
Hi,

Trying to use a background image that have a gradient with QML Image element gives a bad quality in the phone, as in the screenshots bellow:

Original: http://db.tt/FGWEzXhn
In the phone: http://db.tt/3SDeDjT3

With both N9 and N950, the code used (with different options and test) :

Code:

Image {
        fillMode: Image.PreserveAspectCrop
        source: "images/bg.png"
        smooth: true
}

Can anybody help me with this ?

Fuzzillogic 2012-04-20 21:19

Re: QML Image show bad gradient quality
 
I still am unsure whether the N9 supports true color (16.8 million) graphics. I've seen this banding-effect on more occasions. It might be affected by screen dimming as well.

You could try to use a 16bpp image but with dithering applied.

Amine27 2012-04-20 21:34

Re: QML Image show bad gradient quality
 
I forget to note that the N9 Gallery shows the image correctly, just in my application it show it like in the screenshot.

pycage 2012-04-21 12:52

Re: QML Image show bad gradient quality
 
Quote:

Originally Posted by Fuzzillogic (Post 1195086)
I still am unsure whether the N9 supports true color (16.8 million) graphics. I've seen this banding-effect on more occasions.

No, it does not. Try dithering the image before displaying to get better results. I'm pretty sure the gallery applies some dithering to make photos look better on 16bpp.

flopjoke 2012-04-21 16:59

Re: QML Image show bad gradient quality
 
Quote:

Originally Posted by pycage (Post 1195334)
No, it does not. Try dithering the image before displaying to get better results. I'm pretty sure the gallery applies some dithering to make photos look better on 16bpp.

Actually, it does support full 16 million colors. Check here for more info: http://europe.nokia.com/find-product...specifications

You can't really apply dithering filters in real time in a mobile device. Especially not in gallery where you scroll through 8 MP images so fast. I think it's most likely due to the way the image is called by the OS. It looks more like a software problem rather than a hardware problem to me.

CepiPerez 2012-04-21 23:35

Re: QML Image show bad gradient quality
 
Image gallery doesn't use qml
I bet it applies filters in qimage or something like that.
Try to do the same.

pycage 2012-04-22 14:37

Re: QML Image show bad gradient quality
 
Quote:

Originally Posted by flopjoke (Post 1195449)
Actually, it does support full 16 million colors. Check here for more info: http://europe.nokia.com/find-product...specifications

If you want to believe marketing lies more than the actual information output of the display driver...

Quote:

Originally Posted by flopjoke (Post 1195449)
You can't really apply dithering filters in real time in a mobile device.

Of course you can. Dithering from 24bpp to 16bpp is not that CPU-intensive.

dumpystig 2012-04-22 14:55

Re: QML Image show bad gradient quality
 
Quote:

Originally Posted by pycage (Post 1195878)
If you want to believe marketing lies more than the actual information output of the display driver

Which is.....?

ZerionSeven 2012-04-22 16:03

Re: QML Image show bad gradient quality
 
The device is capable of 24-bit color, just configured to run at 16-bit depth.

Code:

~ # xdpyinfo | grep 'depth of root'
  depth of root window:    16 planes

Some time ago I tried changing the X configuration to make the device run at 24-bit depth and it "worked", but some parts of the UI didn't work and everything was much slower.

Anyway, I think you can use QImage::convertToFormat to get 16-bit with dithering.


All times are GMT. The time now is 23:37.

vBulletin® Version 3.8.8