Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Flat style image look sharp #34

Open
fitrh opened this issue Jun 9, 2021 · 4 comments
Open

Flat style image look sharp #34

fitrh opened this issue Jun 9, 2021 · 4 comments

Comments

@fitrh
Copy link

fitrh commented Jun 9, 2021

20210610_030207_full
Take a look to the planet object, the circle look sharp
compared to feh with the same image
20210610_030154_full
Is this expected ? or did i miss something ? i use xwallpaper with --zoom flag

@stoeckmann
Copy link
Owner

stoeckmann commented Jun 10, 2021

It's not expected, but I am not surprised either.

While xwallpaper uses pixman for processing of images, feh uses imlib2. There is no feature to blur or anti-alias images with pixman -- although filter and dither are possible.

I doubt that I can do much about this. But it would be nice if you can give me a link to the original wallpaper and your output of xwallpaper --debug --zoom so I know what kind of resolution you use. Maybe there is something that can be done about the filter settings.

By the way, if you use hsetroot for testing, chances are that you see this sharp output as well. Just like feh, hsetroot uses imlib2 but you can modify the imlib2 settings on the command line.

@fitrh
Copy link
Author

fitrh commented Jun 11, 2021

Oh my bad, i did not look into the source code before and i don't know much about pixman.

By the way, this is the output of xwallpaper --debug --zoom

loading Earth & The Satelite.png
output detected: VGA1, 1366x768+0+0
(randr) screen dimensions: 1366x768+0+0
reusing atom pixmap (1366x768)
composing Earth & The Satelite.png for VGA1 (area 1366x768+0+0) (mode 6)
xcb image (1366x768) to VGA1 (1366x768+0+0)
put image request parameters:
maximum request length allowed for server (32 bits): 4194303
maximum length for row data: 16777188
length of rows in image: 5472
maximum height to send: 3066
put image (1366x768+0+0) to VGA1 (1366x768+0+0)

I can't get where I got the image from, but this image gives the same result.

@stoeckmann
Copy link
Owner

Thank you for supplying an example image. I can easily see the effect and comparing it with feh and hsetroot now.

Unfortunately I have no solution yet. I can adjust the filter with pixman to use a gaussian kernel actually. But to get a result comparable with feh and hsetroot, xwallpaper becomes veeery slow. It is actually the kind of performance you get when opening that file with chromium. My assumption is that it somewhere uses pixman through cairo as well.

So right now I can only recommend to a) scale the image down so the "best" i.e. bilinear filter of pixman already takes effect or b) use feh or hsetroot. I have to admit that imlib2 does a great job here.

When I have a proper solution or when I dived deeper into imlib2 and cairo internals, I'll give an update. :)

@fitrh
Copy link
Author

fitrh commented Jun 14, 2021

Thank you, actually i use xwallpaper because it's performance, maybe i have to dig deeper about pixman

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants