summaryrefslogtreecommitdiffstats
path: root/gfx/layers/ipc/LayersSurfaces.ipdlh
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--gfx/layers/ipc/LayersSurfaces.ipdlh204
1 files changed, 204 insertions, 0 deletions
diff --git a/gfx/layers/ipc/LayersSurfaces.ipdlh b/gfx/layers/ipc/LayersSurfaces.ipdlh
new file mode 100644
index 0000000000..8661d6748f
--- /dev/null
+++ b/gfx/layers/ipc/LayersSurfaces.ipdlh
@@ -0,0 +1,204 @@
+/* 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/. */
+
+include "gfxipc/ShadowLayerUtils.h";
+
+using struct gfxPoint from "gfxPoint.h";
+using nsIntRegion from "nsRegion.h";
+using struct mozilla::layers::SurfaceDescriptorX11 from "gfxipc/SurfaceDescriptor.h";
+using mozilla::StereoMode from "ImageTypes.h";
+using struct mozilla::null_t from "mozilla/ipc/IPCCore.h";
+using mozilla::WindowsHandle from "mozilla/ipc/IPCTypes.h";
+using mozilla::gfx::YUVColorSpace from "mozilla/gfx/Types.h";
+using mozilla::gfx::ColorDepth from "mozilla/gfx/Types.h";
+using mozilla::gfx::ColorRange from "mozilla/gfx/Types.h";
+using mozilla::gfx::SurfaceFormat from "mozilla/gfx/Types.h";
+using mozilla::gfx::IntRect from "mozilla/gfx/Rect.h";
+using mozilla::gfx::IntSize from "mozilla/gfx/Point.h";
+using mozilla::ipc::SharedMemoryBasic::Handle from "mozilla/ipc/SharedMemoryBasic.h";
+using gfxImageFormat from "gfxTypes.h";
+using mozilla::layers::MaybeVideoBridgeSource from "mozilla/layers/VideoBridgeUtils.h";
+
+namespace mozilla {
+namespace layers {
+
+comparable struct SurfaceDescriptorFileMapping {
+ WindowsHandle handle;
+ SurfaceFormat format;
+ IntSize size;
+};
+
+comparable struct SurfaceDescriptorDIB {
+ // gfxWindowsSurface*
+ uintptr_t surface;
+};
+
+comparable struct SurfaceDescriptorD3D10 {
+ WindowsHandle handle;
+ SurfaceFormat format;
+ IntSize size;
+ YUVColorSpace yUVColorSpace;
+ ColorRange colorRange;
+};
+
+comparable struct SurfaceDescriptorDXGIYCbCr {
+ WindowsHandle handleY;
+ WindowsHandle handleCb;
+ WindowsHandle handleCr;
+ IntSize size;
+ IntSize sizeY;
+ IntSize sizeCbCr;
+ ColorDepth colorDepth;
+ YUVColorSpace yUVColorSpace;
+ ColorRange colorRange;
+};
+
+comparable struct SurfaceDescriptorMacIOSurface {
+ uint32_t surfaceId;
+ double scaleFactor;
+ bool isOpaque;
+ YUVColorSpace yUVColorSpace;
+};
+
+comparable struct SurfaceDescriptorDMABuf {
+ uint32_t bufferType;
+ uint64_t modifier;
+ uint32_t flags;
+ FileDescriptor[] fds;
+ uint32_t[] width;
+ uint32_t[] height;
+ uint32_t[] format;
+ uint32_t[] strides;
+ uint32_t[] offsets;
+ YUVColorSpace yUVColorSpace;
+ FileDescriptor[] fence;
+ uint32_t uid;
+ FileDescriptor[] refCount;
+};
+
+comparable struct SurfaceTextureDescriptor {
+ uint64_t handle;
+ IntSize size;
+ SurfaceFormat format;
+ bool continuous;
+ bool ignoreTransform;
+};
+
+comparable struct SurfaceDescriptorAndroidHardwareBuffer {
+ FileDescriptor handle;
+ uint64_t bufferId;
+ IntSize size;
+ SurfaceFormat format;
+};
+
+comparable struct EGLImageDescriptor {
+ uintptr_t image; // `EGLImage` is a `void*`.
+ uintptr_t fence;
+ IntSize size;
+ bool hasAlpha;
+};
+
+comparable struct SurfaceDescriptorSharedGLTexture {
+ uint32_t texture;
+ uint32_t target;
+ uintptr_t fence;
+ IntSize size;
+ bool hasAlpha;
+};
+
+
+comparable union RemoteDecoderVideoSubDescriptor {
+ SurfaceDescriptorD3D10;
+ SurfaceDescriptorDXGIYCbCr;
+ SurfaceDescriptorDMABuf;
+ SurfaceDescriptorMacIOSurface;
+ null_t;
+};
+
+comparable struct SurfaceDescriptorRemoteDecoder {
+ uint64_t handle;
+ RemoteDecoderVideoSubDescriptor subdesc;
+ MaybeVideoBridgeSource source;
+};
+
+comparable struct SurfaceDescriptorPlugin {
+ uint64_t id;
+ SurfaceDescriptorD3D10 pluginSurf;
+ SurfaceDescriptorD3D10 displaySurf;
+};
+
+comparable union SurfaceDescriptorGPUVideo {
+ SurfaceDescriptorRemoteDecoder;
+ SurfaceDescriptorPlugin;
+};
+
+comparable struct RGBDescriptor {
+ IntSize size;
+ SurfaceFormat format;
+ bool hasIntermediateBuffer;
+};
+
+comparable struct YCbCrDescriptor {
+ IntRect display;
+ IntSize ySize;
+ uint32_t yStride;
+ IntSize cbCrSize;
+ uint32_t cbCrStride;
+ uint32_t yOffset;
+ uint32_t cbOffset;
+ uint32_t crOffset;
+ StereoMode stereoMode;
+ ColorDepth colorDepth;
+ YUVColorSpace yUVColorSpace;
+ ColorRange colorRange;
+ bool hasIntermediateBuffer;
+};
+
+comparable union BufferDescriptor {
+ RGBDescriptor;
+ YCbCrDescriptor;
+};
+
+comparable union MemoryOrShmem {
+ uintptr_t;
+ Shmem;
+};
+
+comparable struct SurfaceDescriptorBuffer {
+ BufferDescriptor desc;
+ MemoryOrShmem data;
+};
+
+comparable struct SurfaceDescriptorShared
+{
+ IntSize size;
+ int32_t stride;
+ SurfaceFormat format;
+ Handle handle;
+};
+
+comparable struct SurfaceDescriptorRecorded {
+ int64_t textureId;
+};
+
+comparable union SurfaceDescriptor {
+ SurfaceDescriptorBuffer;
+ SurfaceDescriptorDIB;
+ SurfaceDescriptorD3D10;
+ SurfaceDescriptorFileMapping;
+ SurfaceDescriptorDXGIYCbCr;
+ SurfaceDescriptorX11;
+ SurfaceDescriptorDMABuf;
+ SurfaceTextureDescriptor;
+ SurfaceDescriptorAndroidHardwareBuffer;
+ EGLImageDescriptor;
+ SurfaceDescriptorMacIOSurface;
+ SurfaceDescriptorSharedGLTexture;
+ SurfaceDescriptorGPUVideo;
+ SurfaceDescriptorRecorded;
+ null_t;
+};
+
+} // namespace
+} // namespace