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

69 Коммитов

Автор SHA1 Сообщение Дата
Bas Schouten 8a205e06fb Bug 1251778: Attempt to avoid presenting when the window is still resizing. r=jrmuizel 2016-03-10 03:12:55 +00:00
Lee Salzman 059ca6d6f5 Bug 1249813 - part 3 - tell the compositor if the root layer has opaque content so it can skip clears. r=mattwoodrow 2016-02-25 14:38:05 -05:00
Bas Schouten 36d729fab3 Bug 1232042: Execute an additional present for D3D11 on the compositor thread when a WM_PAINT event has returned. r=jrmuizel 2016-02-24 03:50:09 +00:00
Phil Ringnalda a5861fc16a Back out 6a24b31747be (bug 1232042) for crashes @RecvForcePresent
CLOSED TREE
2016-02-23 21:27:46 -08:00
Bas Schouten fd04611c7c Bug 1232042: Execute an additional present for D3D11 on the compositor thread when a WM_PAINT event has returned. r=jrmuizel 2016-02-24 03:50:09 +00:00
David Anderson 3af026a7f5 Add full mix-blend mode support to the D3D11 compositor. (bug 1238496, r=bas) 2016-02-02 16:33:13 -08:00
Nicholas Nethercote 186d3e93ab Bug 1239537 - Remove Compositor::GetWidgetSize(), which is unused. r=mattwoodrow.
Also remove BasicCompositor::mWidgetSize because its only use can be replaced
by a temporary variable.

--HG--
extra : rebase_source : 03b5992445687cd1ec24307da2d42f87d8cc1041
2016-01-13 15:27:34 -08:00
Nicholas Nethercote 7892cfcede Bug 1239530 (part 2) - Use LayoutDevice coordinates in {Start,End}RemoteDrawingInRegion() and related functions. r=kats.
--HG--
extra : rebase_source : b5bd2d6822904a188242efa6e46aaed9f96a15b9
2015-12-02 22:29:54 -08:00
Milan Sreckovic bd6e14f6c6 Bug 1204922 - Part 3. Report failed before HandleError call. r=bas
--HG--
extra : rebase_source : 4c44c5fe2df0f067dbfc5e6053561b1005911e8c
2015-11-19 10:19:00 +01:00
Bas Schouten 1106ab221f Bug 1204922: When ResizeBuffers fails, make no attempt to do subsequent paints until it succeeds again. r=milan 2015-11-13 13:04:44 +01:00
Milan Sreckovic d0d73eaf51 Bug 1204922 - More information about crashes. r=bas 2015-10-27 14:11:00 +01:00
Nathan Froyd 01583602a9 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi

--HG--
rename : mfbt/nsRefPtr.h => mfbt/RefPtr.h
2015-10-18 01:24:48 -04:00
Nathan Froyd 583afa0965 Bug 1207245 - part 3 - switch all uses of mozilla::RefPtr<T> to nsRefPtr<T>; r=ehsan
This commit was generated using the following script, executed at the
top level of a typical source code checkout.

 # Don't modify select files in mfbt/ because it's not worth trying to
 # tease out the dependencies currently.
 #
 # Don't modify anything in media/gmp-clearkey/0.1/ because those files
 # use their own RefPtr, defined in their own RefCounted.h.
find . -name '*.cpp' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    grep -v 'mfbt/RefPtr.h' | \
    grep -v 'mfbt/nsRefPtr.h' | \
    grep -v 'mfbt/RefCounted.h' | \
    grep -v 'media/gmp-clearkey/0.1/' | \
    xargs perl -p -i -e '
 s/mozilla::RefPtr/nsRefPtr/g; # handle declarations in headers
 s/\bRefPtr</nsRefPtr</g; # handle local variables in functions
 s#mozilla/RefPtr.h#mozilla/nsRefPtr.h#; # handle #includes
 s#mfbt/RefPtr.h#mfbt/nsRefPtr.h#;       # handle strange #includes
'

 # |using mozilla::RefPtr;| is OK; |using nsRefPtr;| is invalid syntax.
find . -name '*.cpp' -o -name '*.mm' | xargs sed -i -e '/using nsRefPtr/d'

 # RefPtr.h used |byRef| for dealing with COM-style outparams.
 # nsRefPtr.h uses |getter_AddRefs|.
 # Fixup that mismatch.
find . -name '*.cpp' -o -name '*.h'| \
    xargs perl -p -i -e 's/byRef/getter_AddRefs/g'
2015-10-18 00:40:10 -04:00
David Anderson 497eea35bc Disable screen and multiply mix-blend-mode support in the D3D11 and OGL compositors. (bug 1135271, r=mattwoodrow) 2015-10-07 16:38:19 -07:00
David Anderson f35bf0138b Log initialization failures in CompositorD3D11.cpp. (bug 1211109 part 1, r=mattwoodrow) 2015-10-05 23:38:40 -07:00
David Anderson b8fb04e7b8 Handle screen and multiply blend modes in the D3D11 compositor. (bug 1203829 part 4, r=mattwoodrow) 2015-09-15 01:04:37 -07:00
David Anderson 250032dd90 Refactor shader initialization in CompositorD3D11. (bug 1203829 part 3, r=mattwoodrow) 2015-09-15 01:04:17 -07:00
Vladimir Vukicevic a0b4b85e51 Bug 1179935, introduce complex viewport projections to Compositor, remove PrepareViewport; r=mstange
---
 gfx/layers/Compositor.h                          |  10 ---
 gfx/layers/basic/BasicCompositor.h               |   2 -
 gfx/layers/composite/TextureHost.h               |  34 +++++++-
 gfx/layers/d3d11/CompositorD3D11.cpp             |  47 +++++++---
 gfx/layers/d3d11/CompositorD3D11.h               |   4 +-
 gfx/layers/d3d9/CompositorD3D9.h                 |   2 +-
 gfx/layers/opengl/CompositingRenderTargetOGL.cpp |  23 +++--
 gfx/layers/opengl/CompositingRenderTargetOGL.h   |   2 +
 gfx/layers/opengl/CompositorOGL.cpp              | 104 +++++++++++++----------
 gfx/layers/opengl/CompositorOGL.h                |   6 +-
 10 files changed, 145 insertions(+), 89 deletions(-)
2015-05-19 13:51:26 -04:00
Nathan Froyd 974d8120f2 Bug 1161627 - part 2 - machine-convert TemporaryRef<T> to already_AddRefed<T>; r=ehsan
This conversion was done with the script:

  find . -name '*.cpp' -o -name '*.h' -o -name '*.mm' -o -name '*.idl' | \
    egrep -v 'cairo-win32-refptr.h|RefPtr.h|TestRefPtr.cpp' | \
    xargs sed -i -e 's/mozilla::TemporaryRef</already_AddRefed</g' \
                 -e 's/TemporaryRef</already_AddRefed</g'

Manual fixups were performed in the following instances:

- We handled mfbt/RefPtr.h manually so as to not convert TemporaryRef itself
  into already_AddRefed.

- The following files had explicit Move() calls added to make up for the lack
  of a copy constructor on already_AddRefed:

  dom/base/ImageEncoder.cpp
  dom/media/MediaTaskQueue.{h,cpp}
  dom/media/webaudio/PannerNode.cpp

- A redundant overload for MediaTaskQueue::Dispatch was deleted.

- A few manual fixups were required in mfbt/tests/TestRefPtr.cpp.

- Comments, using declarations, and forward declarations relating to
  TemporaryRef in dom/canvas/ and gfx/layers/ were changed to refer to
  already_AddRefed.
2015-06-17 10:00:52 -04:00
Kearwood (Kip) Gilbert e25ede39ea Bug 766345 - Part 1 - Implement DEAA Antialiasing for transformed layers (v5 Patch). r=vladimir, r=djg 2014-12-17 16:28:45 -08:00
Nicolas Silva 0b1f75bea0 Bug 1132854 - Remove the gfx::ToIntSize conversion helper. r=Bas 2015-04-07 16:08:57 +02:00
Ehsan Akhgari 883849ee32 Bug 1145631 - Part 1: Replace MOZ_OVERRIDE and MOZ_FINAL with override and final in the tree; r=froydnj
This patch was automatically generated using the following script:

function convert() {
echo "Converting $1 to $2..."
find . \
       ! -wholename "*/.git*" \
       ! -wholename "obj-ff-dbg*" \
         -type f \
      \( -iname "*.cpp" \
         -o -iname "*.h" \
         -o -iname "*.c" \
         -o -iname "*.cc" \
         -o -iname "*.idl" \
         -o -iname "*.ipdl" \
         -o -iname "*.ipdlh" \
         -o -iname "*.mm" \) | \
    xargs -n 1 sed -i -e "s/\b$1\b/$2/g"
}

convert MOZ_OVERRIDE override
convert MOZ_FINAL final
2015-03-21 12:28:04 -04:00
Bas Schouten 9ab9d86962 Bug 1107718: Properly deal with a D3D11 device reset. r=nical 2015-01-08 00:10:49 +00:00
Nicholas Nethercote b4adaf93a3 Bug 1117639 - Remove AbortFrame() because it is dead. r=bas.
--HG--
extra : rebase_source : 7df4840fb99dc025ee102d9697097caa4034fa6d
2015-01-05 15:54:51 -08:00
Vladimir Vukicevic 145ebfeec2 Bug 1036602 - add D3D11 support for VR rendering; r=bas
From fbb1e2ba9936896a1eb932585218401f4c95e411 Mon Sep 17 00:00:00 2001
---
 gfx/layers/d3d11/CompositorD3D11.cpp  | 212 +++++++++++++++++++++++++++++++++-
 gfx/layers/d3d11/CompositorD3D11.fx   |   1 +
 gfx/layers/d3d11/CompositorD3D11.h    |   9 ++
 gfx/layers/d3d11/CompositorD3D11VR.fx |  71 ++++++++++++
 4 files changed, 290 insertions(+), 3 deletions(-)
 create mode 100644 gfx/layers/d3d11/CompositorD3D11VR.fx
2014-07-09 12:26:51 -07:00
Bas Schouten 184e84297b Bug 1107297: Only recomposite the damaged rect with D3D11. r=jrmuizel
This patch makes us behave similarly to when we're using the BasicCompositor, essentially we will clip all drawing to the final display to the area that was labeled as invalid. When DXGI 1.2 is available we will then also report the damaged area to the Present call so that can then be used to minimize the amount of bits that actually need to be blitted to the screen. Since we're no longer recompositing the whole screen this means we should also only clear the damaged area of the window.
2014-12-06 00:02:18 +00:00
Carsten "Tomcat" Book 7f42025e12 Backed out changeset 48667a14f94d (bug 1092360) for test bustage / crashes on a CLOSED TREE 2014-11-14 08:14:22 +01:00
Benoit Girard db4fbee6fb Bug 1092360 - Avoid redundant framebuffer switches. r=jrmuizel 2014-11-12 17:39:17 -05:00
Nicolas Silva 816b042dd6 Bug 1089364 - Add some missing D3D11 error checks. r=Bas 2014-10-27 13:52:17 +01:00
Nicolas Silva 92db98b094 Bug 1087270 - Check more D3D11 result codes and assert in debug builds. r=jrmuizel 2014-10-23 16:22:41 +02:00
Carsten "Tomcat" Book 8e79075d89 Backed out changeset 8a39622aa24a (bug 1087270) for bustage 2014-10-23 13:12:16 +02:00
Nicolas Silva 340b8a427e Bug 1087270 - Check more D3D11 result codes and assert in debug builds. r=jrmuizel 2014-10-23 12:06:14 +02:00
Nicolas Silva a735b7135f Bug 1044975 - Don't crash if mapping D3D11 shader constant buffers fails. r=Bas 2014-10-06 14:53:42 +02:00
Jeff Muizelaar 34032eed5e Bug 1064479. Redo how screen rotation is implemented on B2G/Layers. r=nical,mwoodrow
Currently we use a world transform on the LayerManager. This gets passed to the
screen render target which adjusts the gl transform to accomplish the rotation.
This causes a lot of the system to have to know about the transform.

Instead we can just bake the transform into the root layer's shadow transform.
Everything now mostly just works.

--HG--
extra : rebase_source : e0e170d191eef5887a2e6b17f71ac79037033006
2014-09-10 15:59:00 -04:00
Bas Schouten 2ad53f526f Bug 1035227: Upload partial surfaces when an upload region is specified. r=nical 2014-07-09 16:21:11 +02:00
Matt Woodrow 0726340c00 Bug 1013767 - Restrict BasicCompositor snapshots to the bounds of the invalid region. r=nical 2014-05-28 13:21:32 +12:00
Benoit Jacob 3b123f8333 Bug 987311 - 3/6 - Make TextureFlags a typed enum, final manual changes - r=nical 2014-04-25 22:34:05 -04:00
Blair McBride 24b74a2af7 Backed out 9 changesets (bug 987311, bug 989027, bug 989144). r=sheriff
Backed out changeset 046c061d91c2 (bug 989144)
Backed out changeset 3f1b41adeaef (bug 987311)
Backed out changeset 8d5a171564bd (bug 987311)
Backed out changeset dcc0d016de7a (bug 987311)
Backed out changeset 27f338fbc835 (bug 989027)
Backed out changeset 4a67f5144ea4 (bug 989027)
Backed out changeset 62ba0a377450 (bug 987311)
Backed out changeset 6a2542a5c865 (bug 987311)
Backed out changeset 1dfd9a457f34 (bug 987311)
2014-04-27 19:45:08 +12:00
Benoit Jacob 49dd7d0c3f Bug 987311 - 3/6 - Make TextureFlags a typed enum, final manual changes - r=nical 2014-04-25 22:34:05 -04:00
Nicolas Silva 8ab27731dc Bug 993004 - Fix missing #include on a CLOSED TREE 2014-04-25 14:00:52 +02:00
Nicolas Silva b2b18ff6c3 Bug 993004 - Fix the clipping of tiles when the screen is rotated. r=botond 2014-04-25 13:38:17 +02:00
Carsten "Tomcat" Book 700bf7f2ee Backed out changeset 3d116167774f (bug 993004) for bustage on a CLOSED TREE 2014-04-25 12:19:45 +02:00
Nicolas Silva 66001e57a2 Bug 993004 - Fix the clipping of tiles when the screen is rotated. r=botond 2014-04-25 11:51:17 +02:00
Botond Ballo 2343facec1 Bug 984490 - Make Compositor::GetCurrentRenderTarget() const. r=nical 2014-04-02 03:27:42 -04:00
Matt Woodrow 230a565a26 Bug 980642 - Implement ClearRect for CompositorD3D11. r=Bas 2014-03-28 16:38:32 +13:00
Morris Tseng d4cdf301e3 Bug 926128 - Use a single configurable shader in OpenGL layers backend. r=vlad, r=nical, r=gal 2013-11-07 22:22:05 -08:00
Tom Schuster f9c9b5dccb Bug 973227 - Add GetBackendType to every Compositor class. r=nical 2014-02-18 01:30:05 +01:00
Benoit Girard 0f3a70b95f Bug 963821 - Port FPS counter to the Compositor API. r=bas
--HG--
rename : gfx/layers/opengl/FPSCounter.h => gfx/layers/composite/FPSCounter.h
2014-02-10 17:14:11 -05:00
David Zbarsky c3de69e906 Bug 952977: Convert PrepareViewport to gfx::Matrix4x4 r=nical 2014-01-27 15:25:20 -05:00
David Zbarsky 3e4ce3885c Bug 952977: Switch GL world transform to gfx::Matrix r=nical 2014-01-16 02:22:19 -05:00