class DX10Graphics;
template<typename GraphicsImpl>
class GraphicsBase;

typedef GraphicsBase<DX10Graphics> Graphics;

typedef unsigned long U32;

class DX10Graphics
{
private:
	boost::scoped_array<U32> screenShotBuffer;
public:
	DX10Graphics(const Graphics &base)
	{
		InitDisplay(base.Width(), base.Height());
		CreateOffscreenScratchSurface(base.Width(), base.Height());	
	}

	void InitDisplay(int width, int height)
	{
		// Set up DXGI_SWAP_CHAIN_DESC with the size of width X height and call D3D10CreateDeviceAndSwapChain
		// with those parameters.
	}

	void CreateOffscreenScratchSurface(int width, int height)
	{
		screenShotBuffer = new U32[width * height];
	}
};

template<typename GraphicsImpl>
class GraphicsBase
{
private:
	GraphicsImpl impl;
	int width;
	int height;

public:
	GraphicsBase(int w, int h)
	:width(w), height(h), impl(&this)
	{
	}

	int Width() const { return width; }
	int Height() const { return height; }
};

int main()
{
	boost::scoped_ptr<Graphics> graphicsDevice = new Graphics(1280, 1024);	
}