Files
palemoon27/gfx/layers/ipc/ShadowLayerUtilsX11.h
T
roytam1 e8f234939e import changes from `dev' branch of rmottola/Arctic-Fox:
- Bug 967494 - "Preference Composition/Spelling/Language is ignored, and changing spellcheck language in one composition window affects all open and new compositions" [r=ehsan] Bug 1157421 - Fix typo "suggesteed". r=ehsan (d48b61df9)
- namespaces (c9e3edbf1)
- Bug 1167409 - 3/4 - Change ScriptLoadRequeest::mLoading to mProgress. r=jandem (34377ba15)
- Bug 1104732 - having deferred scripts shouldn't cause async scripts to delay domcontentloaded, r?smaug (f6b3a5ad9)
- Bug 1138395 - Optimize nsDocument::mExpandoAndGeneration.expando out from the cc graphs when possible, r=mccr8 (d944130ab)
- Bug 874838 - Make CreateElem return Element. r=khuey (ac65a35cf)
- Bug 1194619 - fix comment r=dholbert (017a488a2)
- Bug 1137494 - Change the type given to type validation check. r=jgilbert (05885cc7c)
- Bug 1106138 - Remove the early unpremultiply in WebGLContext::SurfaceFromElementResultToImageSurface, and let the texel conversion code handle it instead. r=jgilbert (b8010b16b)
- Bug 1185815 - Hoist generation increment. r=jgilbert (f6a276b5e)
- Bug 1175931 - TexImageFromVideoElement uses GL_HALF_FLOAT if it does not support GL_HALF_FLOAT_OES which would be the case on non-ANGLE systems. Using GL_HALF_FLOAT_OES on a non OES system would result in an error when using TexImage2D. r=jgilbert (d692281f1)
- Bug 1184534 - Add support for target size retrieval to GLX backend. r=jgilbert (0e5ba1f8e)
- bug 1174705 - add GLContext::GetDefaultFramebuffer. r=jgilbert (99c0e70aa)
- Bug 1179935, introduce complex viewport projections to Compositor, remove PrepareViewport; r=mstange (1753d65d3)
- Bug 1184534 - Fetch viewport size from context in CompositorOGL, discard if changed during composition. r=nical (4f57bc4ed)
- Bug 1187440 - Implement GLX shared surfaces on the OpenGL compositor. r=jgilbert,nical (4844e96ce)
- Bug 1033375 - Nudge simple linear gradients with hard stops to half-pixel gradient. r=nical (331ddd4fa)
- Bug 1185636 - Remove hard stop workaround for Cairo due to regressions. r=jrmuizel (ccefe7abc)
- Bug 1177807 - Mark cairo surface dirty in ReleaseBits. r=jrmuizel (ae9d508b9)
- Bug 1170390 - Detect 16bpp cairo xlib surface format. r=jrmuizel (25857ae30)
- Bug 1019063 - Check for ::CreateDCW failing when printing. r=dvander (7f54ba8d2)
- Bug 1170390 - Add gfxASurface::GetSurfaceFormat for retrieving precise surface format where necessary. r=jrmuizel (f70d11b29)
- Bug 1155626 - Don't assume that Factory::GetD2D1Device returns a non-null device and add some gfxCriticalLog. r=Bas (0c896a368)
- Bug 1182209 - Additional info with some critical errors. r=mchang CLOSED TREE (f4841baec)
2021-12-28 09:45:42 +08:00

86 lines
2.4 KiB
C++

/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*-
* vim: sw=2 ts=8 et :
*/
/* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#ifndef mozilla_layers_ShadowLayerUtilsX11_h
#define mozilla_layers_ShadowLayerUtilsX11_h
#include "ipc/IPCMessageUtils.h"
#include "mozilla/GfxMessageUtils.h"
#include "nsCOMPtr.h" // for already_AddRefed
#define MOZ_HAVE_SURFACEDESCRIPTORX11
#define MOZ_HAVE_PLATFORM_SPECIFIC_LAYER_BUFFERS
typedef unsigned long XID;
typedef XID Drawable;
class gfxXlibSurface;
namespace IPC {
class Message;
}
namespace mozilla {
namespace layers {
struct SurfaceDescriptorX11 {
SurfaceDescriptorX11()
{ }
explicit SurfaceDescriptorX11(gfxXlibSurface* aSurf, bool aForwardGLX = false);
SurfaceDescriptorX11(Drawable aDrawable, XID aFormatID,
const gfx::IntSize& aSize);
// Default copy ctor and operator= are OK
bool operator==(const SurfaceDescriptorX11& aOther) const {
// Define == as two descriptors having the same XID for now,
// ignoring size and render format. If the two indeed refer to
// the same valid XID, then size/format are "actually" the same
// anyway, regardless of the values of the fields in
// SurfaceDescriptorX11.
return mId == aOther.mId;
}
already_AddRefed<gfxXlibSurface> OpenForeign() const;
Drawable mId;
XID mFormat; // either a PictFormat or VisualID
gfx::IntSize mSize;
Drawable mGLXPixmap; // used to prevent multiple bindings to the same GLXPixmap in-process
};
} // namespace layers
} // namespace mozilla
namespace IPC {
template <>
struct ParamTraits<mozilla::layers::SurfaceDescriptorX11> {
typedef mozilla::layers::SurfaceDescriptorX11 paramType;
static void Write(Message* aMsg, const paramType& aParam) {
WriteParam(aMsg, aParam.mId);
WriteParam(aMsg, aParam.mSize);
WriteParam(aMsg, aParam.mFormat);
WriteParam(aMsg, aParam.mGLXPixmap);
}
static bool Read(const Message* aMsg, void** aIter, paramType* aResult) {
return (ReadParam(aMsg, aIter, &aResult->mId) &&
ReadParam(aMsg, aIter, &aResult->mSize) &&
ReadParam(aMsg, aIter, &aResult->mFormat) &&
ReadParam(aMsg, aIter, &aResult->mGLXPixmap)
);
}
};
} // namespace IPC
#endif // mozilla_layers_ShadowLayerUtilsX11_h