XPRA_SCALING_INTERPOLATION=nearest setting doesn't work.
the gdk.INTERP_NEAREST is evaluated as false, so the condition in client/gtk2/pixmap_backing.py doesn't work and don't recognize the setting. Also the warning "Warning: invalid interpolation '%s'" is missing value for the %s placeholder.
But howerer even when I fixed both problems, the picture was still interpolated.
My aim is to have x2 scaling such that thare are 4 same pixels in ouput instead of one pixel in source.
The code you refer to was actually unused and has now been removed: r21963.
Something similar could be implemented using cairo's
But you should be using the opengl backend instead, which should be using 'nearest' by default. Why is opengl disabled? What command lines are you using? What OS? etc.
Screenshot detail of the application
I'm using run_scaled script: https://github.com/kaueraal/run_scaled/blob/master/run_scaled
Even with --opengl=yes, it doesn't look like I want. You can see in the picture that there are gradients. It shoul all look similarly to the top right corner (2x2 pixels of same color) (this mesh looks OK probably only because of the specific mesh pattern)
Here is output from the script:
2019-03-05 10:28:13,097 Xpra gtk2 client version 2.4.3-r21350 64-bit 2019-03-05 10:28:13,098 running on Linux Fedora 29 TwentyNine 2019-03-05 10:28:13,099 window manager is 'GNOME Shell' 2019-03-05 10:28:13,721 GStreamer version 1.14.4 for Python 2.7.15 64-bit 2019-03-05 10:28:13,802 OpenGL_accelerate module loaded 2019-03-05 10:28:13,805 Using accelerated ArrayDatatype 2019-03-05 10:28:14,023 OpenGL enabled with AMD Radeon (TM) R9 390 Series (HAWAII, DRM 3.27.0, 4.20.12-200.fc29.x86_64, LLVM 7.0.1) 2019-03-05 10:28:14,030 keyboard settings: rules=evdev, model=pc105, layout=us 2019-03-05 10:28:14,031 desktop size is 3840x2160 with 1 screen: 2019-03-05 10:28:14,031 :0.0 (1016x572 mm - DPI: 96x95) 2019-03-05 10:28:14,031 monitor 1 (700x390 mm - DPI: 139x140) 2019-03-05 10:28:14,031 upscaled by 200%, virtual screen size: 1920x1080 2019-03-05 10:28:14,031 :0.0 (1016x572 mm - DPI: 48x47) 2019-03-05 10:28:14,031 monitor 1 (700x390 mm - DPI: 69x70) 2019-03-05 10:28:14,379 enabled fast mmap transfers using 256MB shared memory area 2019-03-05 10:28:14,379 enabled remote logging 2019-03-05 10:28:14,379 Xpra X11 server version 2.4.3-r21350 64-bit 2019-03-05 10:28:14,380 running on Linux Fedora 29 TwentyNine 2019-03-05 10:28:14,383 Attached to :78817481 2019-03-05 10:28:14,383 (press Control-C to detach)
Can you include a screenshot, unscaled, of what it should look like? Can you give us an example of an application that can be used to reproduce the problem?
Detail of the application in original scale
How I expect the detail should look like when scaled.
Well I'm trying it with Ultima Online over Wine, but tried it with eog now and still I'm getting interpolation.
use "nearest" instead of "linear"
@janinko: try the patch attached, does it help or make it worse?
I have xpra 2.4.3, and your patch looks for slightly different version (according the line numbers). However making the change didn't help.
I tried playing around in the file and this change did it for me:
@@ -175,9 +175,9 @@ def set_texture_level(target=GL_TEXTURE_RECTANGLE_ARB): #only really needed with some drivers (NVidia) #may cause errors with older drivers: try: - glTexParameteri(target, GL_TEXTURE_MIN_FILTER, GL_NEAREST) + glTexParameteri(target, GL_TEXTURE_MIN_FILTER, GL_LINEAR) except: pass
Your change cannot be used because it makes applications like xterms very hard to read with non-integer scaling values (ie: 125%)
this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/2191