xpra icon
Bug tracker and wiki

Opened 4 weeks ago

Closed 4 weeks ago

Last modified 4 weeks ago

#2238 closed defect (fixed)

Server not respecting clients encodings

Reported by: Mark Harkin Owned by: Mark Harkin
Priority: major Milestone:
Component: java Version: trunk
Keywords: Cc:

Description

I'm trying to slowly revive the java client (https://github.com/mjharkin/xpra-client) from (https://github.com/jksiezni/xpra-client).

I'm focusing on PNG encoding which seems to work fairly well.

However, I'm seeing RGB draw packets coming through even though PNG is the only encoding listed in the clients hello request. I can force it server side by setting the env variable XPRA_HARDCODED_ENCODING but is there anyway to do this from the client? I would have expected the server to strictly follow the encodings listed by the client?

I can also get some server side logging if needed.

Change History (3)

comment:1 Changed 4 weeks ago by Antoine Martin

Owner: changed from Antoine Martin to Mark Harkin

Because of the PNG header, small regions end up being bigger when compressed with PNG than they would as rgb+lz4.
The server always assumes that rgb encoding is always available.
When it doesn't make sense to use png, it will automatically switch to rgb.

PNG is also a bad idea because it is a CPU pig, and nowhere near as efficient as WEBP or JPEG.
You should really consider using something better.
If you want to see what is being used and for what region, you can enable -d compress on the server, or paint boxes on the client (#760).

Last edited 4 weeks ago by Antoine Martin (previous) (diff)

comment:2 Changed 4 weeks ago by Mark Harkin

Resolution: fixed
Status: newclosed

Thanks, yes I guessed as much was just looking for a quick work around.

I'm chasing a lossless setup, so I guess I'll look into getting RGB and LZ4 working, thanks for the pointers.

comment:3 Changed 4 weeks ago by Antoine Martin

I'm chasing a lossless setup

--quality=100 is all you need.
The server will choose between PNG, RGB and WEBP lossless as appropriate.

Note: See TracTickets for help on using tickets.