Bug 814979 - Fennec build fails with Mer SDK: invalid inclusion of GLXLibrary.h. r=glandium,mattwoodrow

This commit is contained in:
Oleg Romashin 2012-11-26 00:08:22 -08:00
parent 0fbd0c50fa
commit cba29c6203
6 changed files with 20 additions and 19 deletions

View File

@ -6704,6 +6704,7 @@ AC_SUBST(MOZ_GL_PROVIDER)
AC_DEFINE_UNQUOTED(MOZ_GL_PROVIDER, GLContextProvider$MOZ_GL_PROVIDER)
fi
AC_SUBST(MOZ_GL_DEFAULT_PROVIDER)
AC_DEFINE_UNQUOTED(GL_PROVIDER_$MOZ_GL_DEFAULT_PROVIDER)
dnl ========================================================
dnl = faststripe theme

View File

@ -129,7 +129,7 @@ CanvasLayerOGL::Initialize(const Data& aData)
} else if (aData.mSurface) {
mCanvasSurface = aData.mSurface;
mNeedsYFlip = false;
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
if (aData.mSurface->GetType() == gfxASurface::SurfaceTypeXlib) {
gfxXlibSurface *xsurf = static_cast<gfxXlibSurface*>(aData.mSurface);
mPixmap = xsurf->GetGLXPixmap();
@ -188,7 +188,7 @@ CanvasLayerOGL::UpdateSurface()
return;
}
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
if (mPixmap) {
return;
}
@ -308,7 +308,7 @@ CanvasLayerOGL::RenderLayer(int aPreviousDestination,
program = mOGLManager->GetProgram(mLayerProgram, GetMaskLayer());
}
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
if (mPixmap && !mDelayedUpdates) {
sDefGLXLib.BindTexImage(mPixmap);
}
@ -334,7 +334,7 @@ CanvasLayerOGL::RenderLayer(int aPreviousDestination,
mOGLManager->BindAndDrawQuadWithTextureRect(program, drawRect, drawRect.Size());
}
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
if (mPixmap && !mDelayedUpdates) {
sDefGLXLib.ReleaseTexImage(mPixmap);
}

View File

@ -9,7 +9,7 @@
#include "LayerManagerOGL.h"
#include "gfxASurface.h"
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
#include "GLXLibrary.h"
#include "mozilla/X11Util.h"
#endif
@ -31,7 +31,7 @@ public:
mTexture(0),
mTextureTarget(LOCAL_GL_TEXTURE_2D),
mDelayedUpdates(false)
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
,mPixmap(0)
#endif
{
@ -65,7 +65,7 @@ protected:
bool mGLBufferIsPremultiplied;
bool mNeedsYFlip;
bool mForceReadback;
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
GLXPixmap mPixmap;
#endif

View File

@ -14,7 +14,7 @@
#include "gfxUtils.h"
#include "yuv_convert.h"
#include "GLContextProvider.h"
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
# include "GLXLibrary.h"
# include "gfxXlibSurface.h"
#endif
@ -561,7 +561,7 @@ ImageLayerOGL::AllocateTexturesCairo(CairoImage *aImage)
SetClamping(gl, tex);
#if defined(MOZ_X11) && !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
if (aImage->mSurface->GetType() == gfxASurface::SurfaceTypeXlib) {
gfxXlibSurface *xsurf =
static_cast<gfxXlibSurface*>(aImage->mSurface.get());

View File

@ -23,7 +23,7 @@ using namespace mozilla;
gfxXlibSurface::gfxXlibSurface(Display *dpy, Drawable drawable, Visual *visual)
: mPixmapTaken(false), mDisplay(dpy), mDrawable(drawable)
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
, mGLXPixmap(None)
#endif
{
@ -34,7 +34,7 @@ gfxXlibSurface::gfxXlibSurface(Display *dpy, Drawable drawable, Visual *visual)
gfxXlibSurface::gfxXlibSurface(Display *dpy, Drawable drawable, Visual *visual, const gfxIntSize& size)
: mPixmapTaken(false), mDisplay(dpy), mDrawable(drawable), mSize(size)
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
, mGLXPixmap(None)
#endif
{
@ -49,7 +49,7 @@ gfxXlibSurface::gfxXlibSurface(Screen *screen, Drawable drawable, XRenderPictFor
const gfxIntSize& size)
: mPixmapTaken(false), mDisplay(DisplayOfScreen(screen)),
mDrawable(drawable), mSize(size)
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
, mGLXPixmap(None)
#endif
{
@ -67,7 +67,7 @@ gfxXlibSurface::gfxXlibSurface(cairo_surface_t *csurf)
: mPixmapTaken(false),
mSize(cairo_xlib_surface_get_width(csurf),
cairo_xlib_surface_get_height(csurf))
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
, mGLXPixmap(None)
#endif
{
@ -82,7 +82,7 @@ gfxXlibSurface::gfxXlibSurface(cairo_surface_t *csurf)
gfxXlibSurface::~gfxXlibSurface()
{
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
if (mGLXPixmap) {
gl::sDefGLXLib.DestroyPixmap(mGLXPixmap);
}
@ -217,7 +217,7 @@ gfxXlibSurface::CreateSimilarSurface(gfxContentType aContent,
void
gfxXlibSurface::Finish()
{
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
if (mGLXPixmap) {
gl::sDefGLXLib.DestroyPixmap(mGLXPixmap);
mGLXPixmap = None;
@ -518,7 +518,7 @@ gfxXlibSurface::XRenderFormat()
return cairo_xlib_surface_get_xrender_format(CairoSurface());
}
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
GLXPixmap
gfxXlibSurface::GetGLXPixmap()
{

View File

@ -11,7 +11,7 @@
#include <X11/extensions/Xrender.h>
#include <X11/Xlib.h>
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
#include "GLXLibrary.h"
#endif
@ -76,7 +76,7 @@ public:
// server, not the main application.
virtual gfxASurface::MemoryLocation GetMemoryLocation() const;
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
GLXPixmap GetGLXPixmap();
#endif
@ -103,7 +103,7 @@ protected:
gfxIntSize mSize;
#if !defined(MOZ_PLATFORM_MAEMO)
#if defined(GL_PROVIDER_GLX)
GLXPixmap mGLXPixmap;
#endif
};