diff options
Diffstat (limited to 'gfx/layers/basic/TextureHostBasic.cpp')
-rw-r--r-- | gfx/layers/basic/TextureHostBasic.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/gfx/layers/basic/TextureHostBasic.cpp b/gfx/layers/basic/TextureHostBasic.cpp index 1d671729e6..8058e43efc 100644 --- a/gfx/layers/basic/TextureHostBasic.cpp +++ b/gfx/layers/basic/TextureHostBasic.cpp @@ -4,6 +4,9 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #include "TextureHostBasic.h" +#ifdef XP_MACOSX +#include "MacIOSurfaceTextureHostBasic.h" +#endif using namespace mozilla::gl; using namespace mozilla::gfx; @@ -16,6 +19,13 @@ CreateTextureHostBasic(const SurfaceDescriptor& aDesc, ISurfaceAllocator* aDeallocator, TextureFlags aFlags) { +#ifdef XP_MACOSX + if (aDesc.type() == SurfaceDescriptor::TSurfaceDescriptorMacIOSurface) { + const SurfaceDescriptorMacIOSurface& desc = + aDesc.get_SurfaceDescriptorMacIOSurface(); + return MakeAndAddRef<MacIOSurfaceTextureHostBasic>(aFlags, desc); + } +#endif return CreateBackendIndependentTextureHost(aDesc, aDeallocator, aFlags); } |