#include "rendercontrol.hh"
#include "truerendercontrol.hh"
+#include "rendertexture.hh"
#include "display.hh"
#include "screeninfo.hh"
class ScreenInfo;
class Surface;
+class RenderTexture;
class RenderControl {
protected:
static RenderControl *getRenderControl(int screen);
- virtual void render(Surface *sf) = 0;
+ virtual void drawBackground(Surface *sf,
+ const RenderTexture &texture) const = 0;
};
}
#include "otk.hh"
#include "rendercontrol.hh"
+#include "rendertexture.hh"
#include <stdio.h>
#include <X11/Xlib.h>
otk::RenderControl *rc = otk::RenderControl::getRenderControl(0);
- rc->render(&foo);
+ otk::RenderTexture tex;
+
+ rc->drawBackground(&foo, tex);
XSetWindowBackgroundPixmap(**otk::display, foo.window(), foo.pixmap());
XClearWindow(**otk::display, foo.window());
--- /dev/null
+// -*- mode: C++; indent-tabs-mode: nil; c-basic-offset: 2; -*-
+#ifndef __rendertexture_hh
+#define __rendertexture_hh
+
+namespace otk {
+
+class RenderTexture {
+};
+
+}
+
+#endif // __rendertexture_hh
}
}
-void TrueRenderControl::render(Surface *sf)
+void TrueRenderControl::drawBackground(Surface *sf,
+ const RenderTexture &texture) const
{
assert(sf);
TrueRenderControl(const ScreenInfo *screen);
virtual ~TrueRenderControl();
- virtual void render(Surface *sf);
+ virtual void drawBackground(Surface *sf, const RenderTexture &texture) const;
};
}