Граф коммитов

46 Коммитов

Автор SHA1 Сообщение Дата
sotaro 19b4d3425b Bug 1594303 - Code clean up around RenderAndroidSurfaceTextureHostOGL r=jnicol
Removes NofityForUse() functions for simplicity.

Ensure that RenderTextureHost::PrepareForUse() is called before RenderTextureHost:: Lock(). When a task of calling RenderTextureHost::PrepareForUse() is simply posted to render thread, there is a case that RenderTextureHost:: Lock() is called before PrepareForUse() .

Differential Revision: https://phabricator.services.mozilla.com/D51974

--HG--
extra : moz-landing-system : lando
2019-11-08 12:52:16 +00:00
Jean-Yves Avenard 0356401c43 Bug 1543359 - P10. Add color range info to GPU and WR texture host. r=mattwoodrow
Differential Revision: https://phabricator.services.mozilla.com/D27243

--HG--
extra : moz-landing-system : lando
2019-07-26 08:45:24 +00:00
Narcis Beleuzu e84980d8b1 Backed out 15 changesets (bug 1543359) for wrench bustages on image.rs . CLOSED TREE
Backed out changeset 548006270186 (bug 1543359)
Backed out changeset c9585e9d9f3c (bug 1543359)
Backed out changeset 1c7ca95a2a9b (bug 1543359)
Backed out changeset d742d80b892f (bug 1543359)
Backed out changeset 210eee703fd9 (bug 1543359)
Backed out changeset 4eb933d55d88 (bug 1543359)
Backed out changeset fb9b71ed9f4b (bug 1543359)
Backed out changeset 98b968443458 (bug 1543359)
Backed out changeset a85bd4691bea (bug 1543359)
Backed out changeset b576317853e9 (bug 1543359)
Backed out changeset 095bca5c9b1a (bug 1543359)
Backed out changeset 48eb0ebf9f2e (bug 1543359)
Backed out changeset b22b0eb708b8 (bug 1543359)
Backed out changeset 52187d9320b1 (bug 1543359)
Backed out changeset fa6792c1c2e8 (bug 1543359)
2019-07-26 11:40:33 +03:00
Jean-Yves Avenard 6d26baca40 Bug 1543359 - P10. Add color range info to GPU and WR texture host. r=mattwoodrow
Differential Revision: https://phabricator.services.mozilla.com/D27243

--HG--
extra : moz-landing-system : lando
2019-07-26 06:14:09 +00:00
Cosmin Sabou ae7e8fbf55 Backed out 14 changesets (bug 1543359) for causing build bustages. CLOSED TREE
Backed out changeset 87c99ef85813 (bug 1543359)
Backed out changeset cd0afc5758ba (bug 1543359)
Backed out changeset 101ac87ff017 (bug 1543359)
Backed out changeset 348e748e3451 (bug 1543359)
Backed out changeset d9e937f5caf4 (bug 1543359)
Backed out changeset 2f4eb6501552 (bug 1543359)
Backed out changeset 0d316ef8c668 (bug 1543359)
Backed out changeset bf238b58c694 (bug 1543359)
Backed out changeset 496f206d03d6 (bug 1543359)
Backed out changeset 7c3a1f23baa8 (bug 1543359)
Backed out changeset 90fff717198b (bug 1543359)
Backed out changeset b2ce591ca398 (bug 1543359)
Backed out changeset a63968f077e3 (bug 1543359)
Backed out changeset ca660ab1e0c1 (bug 1543359)
2019-07-26 07:39:11 +03:00
Jean-Yves Avenard a197de5f88 Bug 1543359 - P10. Add color range info to GPU and WR texture host. r=mattwoodrow
Differential Revision: https://phabricator.services.mozilla.com/D27243

--HG--
extra : moz-landing-system : lando
2019-07-22 07:27:41 +00:00
sotaro b8b7b6195f Bug 1568419 - Handle a case that NumSubTextures() returns 0 in AsyncImagePipelineManager::UpdateImageKeys() r=nical
GPUVideoTextureHost::NumSubTextures() returns 0 when wrapped TextureHost does not exist. In this case, we do not have a content of GPUVideoTextureHost for WR render. And EnsureWrappedTextureHost() calling is added in GPUVideoTextureHost::NumSubTextures(), since GPUVideoTextureHost is not explicit about when a wrapped TextureHost is created.

Differential Revision: https://phabricator.services.mozilla.com/D39137

--HG--
extra : moz-landing-system : lando
2019-07-24 13:33:57 +00:00
sotaro 70e1a770b5 Bug 1567816 - Remove WebRenderTextureHostWrapper r=nical
Differential Revision: https://phabricator.services.mozilla.com/D38837

--HG--
extra : moz-landing-system : lando
2019-07-22 08:03:59 +00:00
sotaro 67e4b24fb3 Bug 1558100 - Recycle TextureClient in CanvasClient2D with WebRender r=nical
Differential Revision: https://phabricator.services.mozilla.com/D34495

--HG--
extra : moz-landing-system : lando
2019-06-12 21:29:47 +00:00
sotaro ec2350cffb Bug 1557105 - Handle non-webrender widget case during enabling WebRender at ImageBridge r=nical
ImageBridgeChild has only one global TextureFactoryIdentifier. When WebRender is enabled, it is used for both WebRender widget and non-WebRender(BasicCompositor) widget. WebRenderImageHost and ImageHost are incompatible and WebRenderTextureHost does not permit to be consumed on compositor thread. Then it does not work well for non-WebRender widget. To address the problem at ImageContainer, ImageContainer needs to know a connected widget type. It is not easy in some cases like WebRTC. Then host side could address the problem easier.

CompositableParentManager::FindCompositable() is changed to permit transform from WebRenderImageHost to ImageHost if it is necessary when WebRenderImageHost belongs to ImageBridge.

WebRenderTextureHost is changed to permit to consume wrapped TextureHost on compositor thread. If the wrapped TextureHost is BufferTextureHost, it is possible to comsume the TextureHost on compositor and on RenderThread, since they are memory buffer or shared memory buffer. WebRTC code always create BufferTextureHost for video frame. Then it works.

Differential Revision: https://phabricator.services.mozilla.com/D34132

--HG--
extra : moz-landing-system : lando
2019-06-10 12:36:14 +00:00
sotaro 00fa00cad3 Bug 1544642 - Do not bind SurfaceTexture of video to gl context if it is used by WebGL r=nical
GeckoSurfaceTexture could bind to only one GL context at once. With WebRender, GeckoSurfaceTexture is soon bounded to sharedGL on render thread. It caused the problem if GeckoSurfaceTexture is rendered to WebGL. It could happen only for video's GeckoSurfaceTexture. To avoid the problem, the GeckoSurfaceTexture is bound to gl context when it is actually rendered on WebRender.

Differential Revision: https://phabricator.services.mozilla.com/D27873

--HG--
extra : moz-landing-system : lando
2019-04-26 07:48:54 +00:00
sotaro 601b513435 Bug 1543621 - Move Y flip handling to AsyncImagePipelineManager::ApplyAsyncImageForPipeline() r=nical
With webrender, current gecko does not handle SurfaceTexture.getTransformMatrix() yet. SurfaceTexture is used for video decoding and WebGL. On both usages, when getTransformMatrix() is not handled, it actually worked as bottom left origin. Then gecko need to ignore y flip. AsyncImagePipelineManager::ApplyAsyncImageForPipeline() is a good place to handle the situations, since it handles canvas and video frame rendering. Long term solution is going to be handled by Bug 1507076.

Differential Revision: https://phabricator.services.mozilla.com/D28315

--HG--
extra : moz-landing-system : lando
2019-04-23 12:29:24 +00:00
Jean-Yves Avenard 3ae43eb506 Bug 1493898 - P6. Move YUVColorSpace definition in the gfx namespace. r=mattwoodrow.
YUVColorSpace is inseparable from the bit depth as the matrix coefficients to be calculated need the bit depth information.

So let's put the two types together. gfx namespace also makes more sense as that's where we find IntRect, IntSize and other.

The extent of the changes highlight how much similar data structures are duplicated across the code, to the point it's scary.

Differential Revision: https://phabricator.services.mozilla.com/D25347

--HG--
extra : moz-landing-system : lando
2019-04-11 12:41:33 +00:00
sotaro 817c9ec8c9 Bug 1529870 - Add handling of single buffer mode android SurfaceTexture r=nical
When SurfaceTexture is single buffer mode, UpdateTexImage() should be called only once for each publish. If UpdateTexImage() is called more than once, it causes hand on puglish side.

Differential Revision: https://phabricator.services.mozilla.com/D24483

--HG--
extra : moz-landing-system : lando
2019-04-03 22:05:27 +00:00
Sylvestre Ledru 265e672179 Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format
# ignore-this-changeset

--HG--
extra : amend_source : 4d301d3b0b8711c4692392aa76088ba7fd7d1022
2018-11-30 11:46:48 +01:00
sotaro 3b545f56f3 Bug 1500017 - Use triple buffer with DXGI_SWAP_EFFECT_FLIP_SEQUENTIAL SwapChain r=mattwoodrow 2018-11-05 18:58:37 +09:00
Cosmin Sabou 411aca55f1 Backed out changeset d139f68fd874 (bug 1500017) for build bustages on RenderCompositorANGLE.cpp 2018-11-05 09:36:05 +02:00
sotaro e56fb1f874 Bug 1500017 - Use triple buffer with DXGI_SWAP_EFFECT_FLIP_SEQUENTIAL SwapChain r=mattwoodrow 2018-11-05 15:54:10 +09:00
sotaro 2bcc8b96f5 Bug 1477608 - Reuse same ExternalImageId for different video frames if possible r=jrmuizel 2018-07-25 23:30:08 +09:00
Nicolas Silva 082991a7bc Bug 1404477 - Merge ResourceUpdateQueue and TransactionBuilder. r=kats 2018-01-29 14:33:39 +01:00
Daniel Holbert 126bd9e1a4 Bug 1412427 part 8: (automated patch) Switch a bunch of C++ files in gfx to use our standard mode lines. r=jrmuizel
This patch was generated automatically by the "modeline.py" script, available
here: https://github.com/amccreight/moz-source-tools/blob/master/modeline.py

For every file that is modified in this patch, the changes are as follows:
 (1) The patch changes the file to use the exact C++ mode lines from the
     Mozilla coding style guide, available here:
https://developer.mozilla.org/en-US/docs/Mozilla/Developer_guide/Coding_Style#Mode_Line

 (2) The patch deletes any blank lines between the mode line & the MPL
     boilerplate comment.

 (3) If the file previously had the mode lines and MPL boilerplate in a
     single contiguous C++ comment, then the patch splits them into
     separate C++ comments, to match the boilerplate in the coding style.

MozReview-Commit-ID: 77D61xpSmIl

--HG--
extra : rebase_source : c6162fa3cf539a07177a19838324bf368faa162b
2017-10-27 16:10:06 -07:00
Nicolas Silva f1d8bb2519 Bug 1383786 - Rename TextureHost::PushExternalImage into PushDisplayItems. r=sotaro 2017-09-26 15:31:00 +02:00
Nicolas Silva f8c1fa40c8 Bug 1383786 - Make it possible to update TextureHost image keys. r=sotaro 2017-09-26 15:30:51 +02:00
Nicolas Silva 988b7e111c Bug 1383786 - Simplify generating image keys for TextureHosts. r=sotaro 2017-09-26 15:30:46 +02:00
Nicolas Silva 38b33aa593 Bug 1393031 - Separate WebRenderAPI and ResourceUpdateQueue. r=sotaro 2017-09-04 13:59:42 +02:00
JerryShih 9fdb7a255f Bug 1357299 - P2: Remove the unused IsWrappingNativeHandle() function in WebRenderTextureHost. r=nical
All WR texture related codes are move into GetWRImageKeys(), AddWRImage() and PushExternalImage().
Each texture type could generate its WR commands individually. So, this "mIsWrappingNativeHandle" flag is not used anymore.

MozReview-Commit-ID: 1TITkGRemAr
2017-08-07 18:15:21 +08:00
Sylvestre Ledru 7c0ae251cd Bug 1381253 - Remove redundant control flow declarations rs=ehsan
MozReview-Commit-ID: FFxP4aMCbOL

--HG--
extra : amend_source : 3aec108430b11048f47ffe19d5da7ac5034770a9
2017-07-15 19:03:04 +02:00
Ryan Hunt 017d292cac Bug 1382128 part 2 - Remove WrPoint, WrSize, WrRect, WrMatrix, and WrColor. r=kats
MozReview-Commit-ID: 9koNScu4CyE

--HG--
extra : rebase_source : 68185e949ddf2ae346a5d597d056a7f2d9ea7a28
2017-07-18 18:32:46 -04:00
Ryan Hunt 3f3cb0a954 Bug 1382128 part 1 - Use a namespace in webrender_bindings. r=kats
MozReview-Commit-ID: 3JTMa9Ix5S7

--HG--
extra : rebase_source : 0bea14d9e395cab260d2db5135b1f64e9f82b2e2
2017-06-27 19:20:36 -04:00
Kartikaya Gupta 34903d0ba6 Bug 1376215 - Stop exposing the WrClipRegionToken in WebRenderAPI.h APIs. r=jrmuizel
No functional changes intended in this patch. It merely simplifies the
additional patch that we'll need to update gecko past WR cset 0bf6655,
and saves some potential manual rebasing work.

MozReview-Commit-ID: Km8dBotP3NQ

--HG--
extra : rebase_source : 77c34ec1cbbc1c0fe4d1971feb131d30c97f0d66
2017-06-26 07:49:52 -04:00
Carsten "Tomcat" Book c2622cfcd0 Backed out changeset 504e5b1de987 (bug 1376215) for bustage 2017-06-26 13:07:09 +02:00
Kartikaya Gupta b459b56298 Bug 1376215 - Stop exposing the WrClipRegionToken in WebRenderAPI.h APIs. r=jrmuizel
No functional changes intended in this patch. It merely simplifies the
additional patch that we'll need to update gecko past WR cset 0bf6655,
and saves some potential manual rebasing work.

MozReview-Commit-ID: AgMyNapY2Og

--HG--
extra : rebase_source : d8522d8e806522a4a0e8b2cd1669db0374bd5e63
2017-06-25 14:45:54 -04:00
JerryShih 011987c967 Bug 1372803 - Handle GPUVideoTextureHost type for WR. r=sotaro
In windows platform, gecko will use GPUVideoTextureHost type for remote video decoding.
Implement the WR related functions for this type.

MozReview-Commit-ID: KSpndcApK3H
2017-06-15 17:07:46 +08:00
JerryShih 8731715817 Bug 1372803 - Move the RenderTextureHost creation from WebRenderTextureHost to the corresponding TextureHost. r=sotaro
MozReview-Commit-ID: JF19ntiQKfa
2017-06-15 17:07:46 +08:00
JerryShih efa30c7964 Bug 1366502 - Make sure all wrapped textureHosts doesn't use TextureFlags::DEALLOCATE_CLIENT flag. v2. r=sotaro
MozReview-Commit-ID: KjZIGRzRomT
2017-06-07 23:44:05 +08:00
JerryShih b28ccb02ff Bug 1366502 - Update the thread model for RegisterExternalImage(), UnregisterExternalImage() and GetRenderTexture() call. v2. r=sotaro
If we call UnregisterExternalImage() at non-render-thread and decrease the RenderTextureHost's ref-count to zero, the RenderTextureHost will be released in non-render-thread.
That will cause some problems if we use some thread-specific functions in ~RenderTextureHost().
This patch uses a message loop in UnregisterExternalImage() to resolve this problem.

MozReview-Commit-ID: CDazxGkE1cK
2017-06-07 23:44:05 +08:00
JerryShih df9418c639 Bug 1366502 - Update WebRenderTextureHost for video pipeline. r=sotaro
MozReview-Commit-ID: 8ODLYyXzHjO
2017-06-07 23:44:04 +08:00
JerryShih 76b2651840 Bug 1364922 - Update AddWRImage() interface for multiple ImageKeys. v2. r=nical
Some textureHosts have multiple-channel data. Each channel should use different ImageKey.

MozReview-Commit-ID: 86EGQn65nMG
2017-05-19 00:25:41 +08:00
JerryShih 2c3fd143c6 Bug 1362049 - Add AddWRImage() to call the proper WR commands for all TextureHost types. v3. r=nical
Different TextureHost type could use different WR commands. So, make a abstract interface for these different commands.

MozReview-Commit-ID: 63dnOJC2P9r
2017-05-18 22:59:07 +08:00
sotaro e39bdc681a Bug 1356944 - Fix external image id allocation of WebRenderTextureHost r=nical 2017-04-20 10:24:13 +09:00
sotaro d85c0f08e4 Bug 1357644 - Use wr::ExternalImageId instead of uint64_t for external image id r=nical 2017-04-19 18:59:53 +09:00
JerryShih b0ffca2f70 Bug 1347062 - P4: create RenderBufferTextureHost and RenderMacIOSurfaceTextureHostOGL. r=nical,sotaro
1) make RenderTextureHost into a abstract base class for all RenderXXXTextureHost.
2) create a base class RenderTextureHostOGL for all texture handle base texture.
3) create RenderBufferTextureHost for buffer texture at render thread.
4) create RenderMacIOSurfaceTextureHostOGL for MacIOSurface at render thread.

--HG--
rename : gfx/webrender_bindings/RenderBufferTextureHost.h => gfx/webrender_bindings/RenderTextureHost.h
2017-03-31 22:29:14 +08:00
JerryShih f8987906e1 Bug 1347062 - P3: rename from RenderTextureHost to RenderBufferTextureHost for further updating. r=sotaro
We will have a class RenderTextureHost as the base-class and its sub-class RenderBufferTextureHost in next patch. Use "rename" to preserve the file history.

MozReview-Commit-ID: KiqaO616AHc

--HG--
rename : gfx/webrender_bindings/RenderTextureHost.cpp => gfx/webrender_bindings/RenderBufferTextureHost.cpp
rename : gfx/webrender_bindings/RenderTextureHost.h => gfx/webrender_bindings/RenderBufferTextureHost.h
2017-03-31 22:29:14 +08:00
David Anderson ca86baecf0 Material changes for TextureHost TextureSourceProvider support. (bug 1343814 part 3.2, r=mattwoodrow) 2017-03-21 20:32:54 -07:00
sotaro 6a06e56c91 Bug 1345344 - Pass stride for ExternalImageBuffer r=nical 2017-03-09 11:10:09 +09:00
sotaro 1d710a54ef Bug 1343764 - Add ExternalBuffer handling r=nical 2017-03-07 19:37:28 +09:00