Bug 159621 - Red and blue colors are swapped in video rendered through WebGL when GSTREAMER_GL is enabled
Summary: Red and blue colors are swapped in video rendered through WebGL when GSTREAME...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on: 159673
Blocks:
  Show dependency treegraph
 
Reported: 2016-07-11 07:04 PDT by Olivier Blin
Modified: 2016-09-22 05:57 PDT (History)
6 users (show)

See Also:


Attachments
Patch (2.73 KB, patch)
2016-07-11 07:09 PDT, Olivier Blin
no flags Details | Formatted Diff | Diff
Patch (3.14 KB, text/plain)
2016-07-11 08:56 PDT, Olivier Blin
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Olivier Blin 2016-07-11 07:04:49 PDT
When a video is rendered through WebGL, and GSTREAMER_GL is enabled, red and blue colors are swapped.
This occurs for example with the following videos:
http://www.scirra.com/labs/bugs/webglvideo/
http://www.dailymotion.com/embed/video/x4jiicp?autoplay=1

This seems to be because ImageGStreamerCairo expects video frames in either BGRA or ARGB, while when GSTREAMER_GL is enabled, createVideoSinkGL() forces a RGBA format.
Without GSTREAMER_GL, the rendering is fine since VideoSinkGStreamer uses either BGRA or ARGB.
Comment 1 Olivier Blin 2016-07-11 07:09:14 PDT
Created attachment 283315 [details]
Patch
Comment 2 Olivier Blin 2016-07-11 07:10:02 PDT
This patch fixes the issue for me, but I am not sure if this can cause performance regression.
Comment 3 WebKit Commit Bot 2016-07-11 07:45:18 PDT
Comment on attachment 283315 [details]
Patch

Clearing flags on attachment: 283315

Committed r203059: <http://trac.webkit.org/changeset/203059>
Comment 4 WebKit Commit Bot 2016-07-11 07:45:22 PDT
All reviewed patches have been landed.  Closing bug.
Comment 5 Olivier Blin 2016-07-11 08:56:05 PDT
Reopening to attach new patch.
Comment 6 Olivier Blin 2016-07-11 08:56:09 PDT
Created attachment 283318 [details]
Patch
Comment 7 Philippe Normand 2016-07-11 09:04:54 PDT
What does this patch have to do with this bug? :)
Comment 8 Olivier Blin 2016-07-11 09:05:02 PDT
Comment on attachment 283318 [details]
Patch

Wrong bug, sorry
Comment 9 WebKit Commit Bot 2016-07-12 06:02:12 PDT
Re-opened since this is blocked by bug 159673
Comment 10 Olivier Blin 2016-09-22 05:57:50 PDT
Fixed now that GPU-GPU WebGL video integration has landed, see bug 159928