Bug 199378 - [GStreamer] Video quality with gstreamer-vaapi is bad
Summary: [GStreamer] Video quality with gstreamer-vaapi is bad
Status: RESOLVED WORKSFORME
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: Other
Hardware: Unspecified Linux
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-07-01 14:02 PDT by grmat
Modified: 2022-10-18 09:20 PDT (History)
11 users (show)

See Also:


Attachments
Screenshot Epiphany (88.88 KB, image/png)
2019-07-01 14:02 PDT, grmat
no flags Details
Screenshot Firefox (106.97 KB, image/png)
2019-07-01 14:02 PDT, grmat
no flags Details
Screenshot Intel (113.90 KB, image/png)
2019-07-11 06:26 PDT, grmat
no flags Details
mpv screenshot (96.63 KB, image/png)
2019-07-11 06:27 PDT, grmat
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description grmat 2019-07-01 14:02:14 PDT
Using GNOME Web 3.32.3 (WebKitGTK+ 2.24.2)

The Video quality is bad. Attached are screenshots from Epiphany using WebKitGTK+ and Firefox for comparison.

Test site: https://www.w3schools.com/html/tryit.asp?filename=tryhtml5_video

open the direct video url to make sure the video isn't scaled: https://www.w3schools.com/html/mov_bbb.mp4



Redirected from https://gitlab.gnome.org/GNOME/epiphany/issues/834
Comment 1 grmat 2019-07-01 14:02:35 PDT
Created attachment 373260 [details]
Screenshot Epiphany
Comment 2 grmat 2019-07-01 14:02:47 PDT
Created attachment 373261 [details]
Screenshot Firefox
Comment 3 Michael Catanzaro 2019-07-01 14:15:02 PDT
FWIW: I see the good result (like your Firefox image) in Ephy Tech Preview.
Comment 5 grmat 2019-07-02 00:23:59 PDT
I currently can't build a newer version. There is nothing wrong with the resolution.

It is related with vaapi. The artifacts aren't as bad on Intel hardware (initial screenshot is from AMD), but the colours are wrong. Uninstalling gstreamer-vaapi "solves" the issue, however the colours are still oversaturated in comparison to Chromium and Firefox, which look identical to my eye.
Comment 6 Alicia Boya García 2019-07-02 02:05:14 PDT
I would say the colors are the same, the problem is the Epiphany one is being painted with a half pixels offset, resulting in blur.
Comment 7 Alicia Boya García 2019-07-02 02:05:42 PDT
(at least in the attached screenshots)
Comment 8 grmat 2019-07-02 02:09:07 PDT
Yes, I haven't attached screenshots with Intel hardware yet. I can post some later, but I'm not sure this would be no separate issue.
Comment 9 Michael Catanzaro 2019-07-02 05:55:50 PDT
(In reply to grmat from comment #5)
> I currently can't build a newer version. There is nothing wrong with the
> resolution.

Sorry, that was a spammer pretending to leave a relevant comment.
Comment 10 Michael Catanzaro 2019-07-02 05:59:33 PDT
So either we fix bug #197752 and mark this as a dup, or we take responsibility for fixing vaapi bugs like this....
Comment 11 grmat 2019-07-02 06:29:34 PDT
Sorry for the dup. I haven't searched for vaapi before filing.

I can't contribute technically and I'm not deep into this topic. Just from a user POV, it would be a shame if vaapi was blacklisted. I actually put hope in smaller webkit based browsers like epiphany because the major browser vendors fail to support hardware accel video on Linux for years.

Can you say that it's the driver's fault? Then I'll report the quality issues to AMD as well.

I also don't know how much Webkit can do or whether there is room for configuration. What I can say is that I'm using VAAPI with mpv all the time and it doesn't show any quality issues at all.

I actually just tested the above linked video with mpv+vaapi on the AMD hardware and the frame looks identical to the Firefox one.
Comment 13 grmat 2019-07-11 06:26:19 PDT
Created attachment 373918 [details]
Screenshot Intel

Using gstreamer-vaapi in Epiphany on Intel, the video looks oversaturated
Comment 14 grmat 2019-07-11 06:27:35 PDT
Created attachment 373919 [details]
mpv screenshot

mpv, which also uses VA-API btw, for reference.
Comment 15 Philippe Normand 2022-06-29 05:22:22 PDT
Is this still an issue?

BTW, PSA: in 2.38 gstreamer-vaapi decoders will not be used, unless the WEBKIT_GST_ENABLE_LEGACY_VAAPI env var is set to 1. The new stateless va decoders will be used, supposing their rank is high enough, which can be ensured by setting this env var: GST_PLUGIN_FEATURE_RANK=vah264dec:MAX
Comment 16 Philippe Normand 2022-08-16 11:53:34 PDT
Please give this a try with the new decoder has mentioned in previous comment. Feel free to re-open if the issue is still happening.