Bug 1357558
| Summary: | Desktop repainting with 8-bit colours on remote desktop via freerdp on x86_64 | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Red Hat Enterprise Linux 7 | Reporter: | Tomas Hudziec <thudziec> | ||||
| Component: | freerdp | Assignee: | Ondrej Holy <oholy> | ||||
| Status: | CLOSED WONTFIX | QA Contact: | Desktop QE <desktop-qa-list> | ||||
| Severity: | medium | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | 7.3 | CC: | tpelka | ||||
| Target Milestone: | rc | ||||||
| Target Release: | --- | ||||||
| Hardware: | x86_64 | ||||||
| OS: | Linux | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | If docs needed, set a value | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2018-11-19 12:53:45 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Bug Depends On: | 1291254 | ||||||
| Bug Blocks: | |||||||
| Attachments: |
|
||||||
|
Description
Tomas Hudziec
2016-07-18 13:47:28 UTC
Color profiles are swapped when converting from 8bpp to 32bpp, which causes those glitches when moving window...
diff --git a/libfreerdp-codec/color.c b/libfreerdp-codec/color.c
index ff3bacb..23509bd 100644
--- a/libfreerdp-codec/color.c
+++ b/libfreerdp-codec/color.c
@@ -423,3 +423,3 @@ uint8* freerdp_image_convert_8bpp(uint8* srcData, uint8* dstData, int width, int
blue = clrconv->palette->entries[pixel].blue;
- pixel = (clrconv->invert) ? RGB32(red, green, blue) : BGR32(red, green, blue);
+ pixel = (clrconv->invert) ? BGR32(red, green, blue) : RGB32(red, green, blue);
*dst32 = pixel;
The glitches should be fixed with the first diff applied, however the colors are still inverted. Wrong color profile is probably used when updating palette:
diff --git a/libfreerdp-core/update.c b/libfreerdp-core/update.c
index c828b22..06fa4e3 100644
--- a/libfreerdp-core/update.c
+++ b/libfreerdp-core/update.c
@@ -128,5 +128,5 @@ void update_read_palette(rdpUpdate* update, STREAM* s, PALETTE_UPDATE* palette_u
- stream_read_uint8(s, entry->blue);
- stream_read_uint8(s, entry->green);
stream_read_uint8(s, entry->red);
+ stream_read_uint8(s, entry->green);
+ stream_read_uint8(s, entry->blue);
}
However still some icons seem to have corrupted colors and I am not really sure why.
The color handling is broken in some cases in freerdp-1.0 (see also Bug 1308810). It seems that freerdp master has some of those problems already fixed, however backporting such fixes would be pretty complicated, because (not only) color handling was refactored several times and another overhaul is almost done.
It would require a lot of effort to fix it properly and I afraid that the bug doesn't seem to have enough priority to justify the invested effort (same as Bug 1308810). I think that the only reasonable solution is to make a rebase once freerdp-2.0 is released (Bug 1291254).
It is too late for rhel-7.3 anyway, let's reconsider this for rhel-7.4.
Just a few more notes: There are more color glitches with 8bpp if X server depth is 16. Also cursor colors are wrong in some cases for 8bpp. Seems fixed upstream. Let's postpone this to RHEL-7.7. See: https://bugzilla.redhat.com/show_bug.cgi?id=1291254#c11 Still reproducible on RHEL 7.6 with freerdp-1.0.2-15.el7.x86_64. I don't really plan to fix this for freerdp 1.0. We are still postponing this together with Bug 1291254. So let's close this finally as WONTFIX. This will be simply fixed once we rebase. I don't really think that somebody uses 8-bit color depth anyway... |