Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 20; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
|
|
|
* 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_GFX_IMAGECLIENT_H
|
|
|
|
#define MOZILLA_GFX_IMAGECLIENT_H
|
|
|
|
|
2013-08-12 03:17:23 +04:00
|
|
|
#include <stdint.h> // for uint32_t, uint64_t
|
|
|
|
#include <sys/types.h> // for int32_t
|
|
|
|
#include "mozilla/Attributes.h" // for MOZ_OVERRIDE
|
|
|
|
#include "mozilla/RefPtr.h" // for RefPtr, TemporaryRef
|
|
|
|
#include "mozilla/gfx/Types.h" // for SurfaceFormat
|
|
|
|
#include "mozilla/layers/CompositableClient.h" // for CompositableClient
|
|
|
|
#include "mozilla/layers/CompositorTypes.h" // for CompositableType, etc
|
|
|
|
#include "mozilla/layers/LayersSurfaces.h" // for SurfaceDescriptor
|
|
|
|
#include "mozilla/layers/TextureClient.h" // for DeprecatedTextureClient, etc
|
|
|
|
#include "mozilla/mozalloc.h" // for operator delete
|
|
|
|
#include "nsCOMPtr.h" // for already_AddRefed
|
|
|
|
#include "nsRect.h" // for nsIntRect
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
|
|
|
|
namespace mozilla {
|
|
|
|
namespace layers {
|
|
|
|
|
2013-08-12 03:17:23 +04:00
|
|
|
class CompositableForwarder;
|
|
|
|
class Image;
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
class ImageContainer;
|
2013-08-12 03:17:23 +04:00
|
|
|
class ShadowableLayer;
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Image clients are used by basic image layers on the content thread, they
|
|
|
|
* always match with an ImageHost on the compositor thread. See
|
|
|
|
* CompositableClient.h for information on connecting clients to hosts.
|
|
|
|
*/
|
|
|
|
class ImageClient : public CompositableClient
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
/**
|
|
|
|
* Creates, configures, and returns a new image client. If necessary, a
|
|
|
|
* message will be sent to the compositor to create a corresponding image
|
|
|
|
* host.
|
|
|
|
*/
|
2013-04-17 01:36:06 +04:00
|
|
|
static TemporaryRef<ImageClient> CreateImageClient(CompositableType aImageHostType,
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
CompositableForwarder* aFwd,
|
|
|
|
TextureFlags aFlags);
|
|
|
|
|
|
|
|
virtual ~ImageClient() {}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Update this ImageClient from aContainer in aLayer
|
|
|
|
* returns false if this is the wrong kind of ImageClient for aContainer.
|
|
|
|
* Note that returning true does not necessarily imply success
|
|
|
|
*/
|
|
|
|
virtual bool UpdateImage(ImageContainer* aContainer, uint32_t aContentFlags) = 0;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* The picture rect is the area of the texture which makes up the image. That
|
|
|
|
* is, the area that should be composited. In texture space.
|
|
|
|
*/
|
|
|
|
virtual void UpdatePictureRect(nsIntRect aPictureRect);
|
|
|
|
|
2014-01-31 02:58:51 +04:00
|
|
|
virtual already_AddRefed<Image> CreateImage(ImageFormat aFormat) = 0;
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
|
2013-09-12 18:50:28 +04:00
|
|
|
/**
|
|
|
|
* Synchronously remove all the textures used by the image client.
|
|
|
|
*/
|
2013-10-17 19:09:15 +04:00
|
|
|
virtual void FlushAllImages(bool aExceptFront) {}
|
2013-09-12 18:50:28 +04:00
|
|
|
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
protected:
|
|
|
|
ImageClient(CompositableForwarder* aFwd, CompositableType aType);
|
|
|
|
|
|
|
|
CompositableType mType;
|
|
|
|
int32_t mLastPaintedImageSerial;
|
|
|
|
nsIntRect mPictureRect;
|
|
|
|
};
|
|
|
|
|
2013-07-30 13:59:51 +04:00
|
|
|
/**
|
|
|
|
* An image client which uses a single texture client.
|
|
|
|
*/
|
|
|
|
class ImageClientSingle : public ImageClient
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
ImageClientSingle(CompositableForwarder* aFwd,
|
|
|
|
TextureFlags aFlags,
|
|
|
|
CompositableType aType);
|
|
|
|
|
|
|
|
virtual bool UpdateImage(ImageContainer* aContainer, uint32_t aContentFlags);
|
|
|
|
|
2013-08-08 16:53:12 +04:00
|
|
|
virtual void OnDetach() MOZ_OVERRIDE;
|
2013-07-30 13:59:51 +04:00
|
|
|
|
2013-10-10 03:18:29 +04:00
|
|
|
virtual bool AddTextureClient(TextureClient* aTexture) MOZ_OVERRIDE;
|
2013-07-30 13:59:51 +04:00
|
|
|
|
2013-08-28 00:16:03 +04:00
|
|
|
virtual TemporaryRef<BufferTextureClient>
|
2013-10-14 04:24:12 +04:00
|
|
|
CreateBufferTextureClient(gfx::SurfaceFormat aFormat,
|
|
|
|
TextureFlags aFlags = TEXTURE_FLAGS_DEFAULT) MOZ_OVERRIDE;
|
2013-08-03 21:30:28 +04:00
|
|
|
|
2013-07-30 13:59:51 +04:00
|
|
|
virtual TextureInfo GetTextureInfo() const MOZ_OVERRIDE;
|
2013-08-28 17:21:05 +04:00
|
|
|
|
2014-01-31 02:58:51 +04:00
|
|
|
virtual already_AddRefed<Image> CreateImage(ImageFormat aFormat) MOZ_OVERRIDE;
|
2013-09-12 18:50:28 +04:00
|
|
|
|
2013-10-17 19:09:15 +04:00
|
|
|
virtual void FlushAllImages(bool aExceptFront) MOZ_OVERRIDE;
|
2013-09-12 18:50:28 +04:00
|
|
|
|
2013-07-30 13:59:51 +04:00
|
|
|
protected:
|
|
|
|
RefPtr<TextureClient> mFrontBuffer;
|
|
|
|
// Some layers may want to enforce some flags to all their textures
|
|
|
|
// (like disallowing tiling)
|
|
|
|
TextureFlags mTextureFlags;
|
|
|
|
};
|
|
|
|
|
|
|
|
/**
|
2013-08-08 16:53:12 +04:00
|
|
|
* An image client which uses two texture clients.
|
2013-07-30 13:59:51 +04:00
|
|
|
*/
|
|
|
|
class ImageClientBuffered : public ImageClientSingle
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
ImageClientBuffered(CompositableForwarder* aFwd,
|
|
|
|
TextureFlags aFlags,
|
|
|
|
CompositableType aType);
|
|
|
|
|
|
|
|
virtual bool UpdateImage(ImageContainer* aContainer, uint32_t aContentFlags);
|
|
|
|
|
2013-08-08 16:53:12 +04:00
|
|
|
virtual void OnDetach() MOZ_OVERRIDE;
|
2013-07-30 13:59:51 +04:00
|
|
|
|
2013-10-17 19:09:15 +04:00
|
|
|
virtual void FlushAllImages(bool aExceptFront) MOZ_OVERRIDE;
|
2013-09-12 18:50:28 +04:00
|
|
|
|
2013-07-30 13:59:51 +04:00
|
|
|
protected:
|
|
|
|
RefPtr<TextureClient> mBackBuffer;
|
|
|
|
};
|
|
|
|
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
/**
|
|
|
|
* An image client which uses a single texture client, may be single or double
|
|
|
|
* buffered. (As opposed to using two texture clients for buffering, as in
|
|
|
|
* ContentClientDoubleBuffered, or using multiple clients for YCbCr or tiled
|
|
|
|
* images).
|
2013-07-30 13:59:51 +04:00
|
|
|
*
|
|
|
|
* XXX - this is deprecated, use ImageClientSingle
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
*/
|
2013-07-24 20:08:35 +04:00
|
|
|
class DeprecatedImageClientSingle : public ImageClient
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
{
|
|
|
|
public:
|
2013-07-24 20:08:35 +04:00
|
|
|
DeprecatedImageClientSingle(CompositableForwarder* aFwd,
|
|
|
|
TextureFlags aFlags,
|
|
|
|
CompositableType aType);
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
|
|
|
|
virtual bool UpdateImage(ImageContainer* aContainer, uint32_t aContentFlags);
|
|
|
|
|
2013-05-01 04:42:05 +04:00
|
|
|
/**
|
|
|
|
* Creates a texture client of the requested type.
|
|
|
|
* Returns true if the texture client was created succesfully,
|
|
|
|
* false otherwise.
|
|
|
|
*/
|
2013-07-09 01:30:44 +04:00
|
|
|
bool EnsureDeprecatedTextureClient(DeprecatedTextureClientType aType);
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
|
|
|
|
virtual void Updated();
|
2013-04-12 11:28:55 +04:00
|
|
|
|
|
|
|
virtual void SetDescriptorFromReply(TextureIdentifier aTextureId,
|
|
|
|
const SurfaceDescriptor& aDescriptor) MOZ_OVERRIDE
|
|
|
|
{
|
2013-07-09 01:30:44 +04:00
|
|
|
mDeprecatedTextureClient->SetDescriptorFromReply(aDescriptor);
|
2013-04-12 11:28:55 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
virtual TextureInfo GetTextureInfo() const MOZ_OVERRIDE
|
|
|
|
{
|
|
|
|
return mTextureInfo;
|
|
|
|
}
|
|
|
|
|
2014-01-31 02:58:51 +04:00
|
|
|
virtual already_AddRefed<Image> CreateImage(ImageFormat aFormat) MOZ_OVERRIDE;
|
2013-08-28 17:21:05 +04:00
|
|
|
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
private:
|
2013-07-09 01:30:44 +04:00
|
|
|
RefPtr<DeprecatedTextureClient> mDeprecatedTextureClient;
|
2013-04-12 11:28:55 +04:00
|
|
|
TextureInfo mTextureInfo;
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
};
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Image class to be used for async image uploads using the image bridge
|
|
|
|
* protocol.
|
2013-07-09 01:30:44 +04:00
|
|
|
* We store the ImageBridge id in the DeprecatedTextureClientIdentifier.
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
*/
|
|
|
|
class ImageClientBridge : public ImageClient
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
ImageClientBridge(CompositableForwarder* aFwd,
|
|
|
|
TextureFlags aFlags);
|
|
|
|
|
|
|
|
virtual bool UpdateImage(ImageContainer* aContainer, uint32_t aContentFlags);
|
|
|
|
virtual bool Connect() { return false; }
|
|
|
|
virtual void Updated() {}
|
|
|
|
void SetLayer(ShadowableLayer* aLayer)
|
|
|
|
{
|
|
|
|
mLayer = aLayer;
|
|
|
|
}
|
|
|
|
|
2013-04-12 11:28:55 +04:00
|
|
|
virtual TextureInfo GetTextureInfo() const MOZ_OVERRIDE
|
|
|
|
{
|
|
|
|
return TextureInfo(mType);
|
|
|
|
}
|
|
|
|
|
2013-08-21 05:27:05 +04:00
|
|
|
virtual void SetIPDLActor(CompositableChild* aChild) MOZ_OVERRIDE
|
|
|
|
{
|
|
|
|
MOZ_ASSERT(!aChild, "ImageClientBridge should not have IPDL actor");
|
|
|
|
}
|
|
|
|
|
2014-01-31 02:58:51 +04:00
|
|
|
virtual already_AddRefed<Image> CreateImage(ImageFormat aFormat) MOZ_OVERRIDE
|
2013-08-28 17:21:05 +04:00
|
|
|
{
|
|
|
|
NS_WARNING("Should not create an image through an ImageClientBridge");
|
|
|
|
return nullptr;
|
|
|
|
}
|
|
|
|
|
Bug 825928: Land layers refactoring. r=jrmuizel,bas,nical,mattwoodrow,roc,nrc,benwa,bjacob,jgilbert,kchen CLOSED TREE
Please contact Bas Schouten <bschouten@mozilla.com>, Nicolas Silva <nsilva@mozilla.com> or Nicholas Cameron <ncameron@mozilla.com> with general questions. Below is a rough list of authors to contact with specific questions.
Authors:
gfx/layers/Compositor.* gfx/layers/Effects.h - Compositor Interface - bas,nrc,nical
gfx/layers/d3d* - D3D9/D3D10 - bas
gfx/layers/ThebesLayer* - ThebesLayers - nrc,bas
gfx/layers/composite/* - CompositeLayers - nrc,nical
gfx/layers/client/* - Client - nrc,nical,bas
gfx/layers/*Image* - nical
gfx/layers/ipc ipc - IPC - nical
gfx/layers/opengl - CompositorOGL - nrc,nical
gfx/2d - bas,nrc
gfx/gl - GLContext - bjacob
dom/* layout/* - DOM - mattwoodrow
2013-04-10 13:20:52 +04:00
|
|
|
protected:
|
|
|
|
uint64_t mAsyncContainerID;
|
|
|
|
ShadowableLayer* mLayer;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|