|
From: The M. <mit...@be...> - 2003-03-12 01:47:53
|
Here it is so far, as requested.
#ifndef STUBRENDERER_
#define STUBRENDERER_
namespace GDN {
namespace Graphics {
template<>
class<GDN::Dependent::OS::Graphics::API> Renderer {
public:
//enumeration info
//returns the enumerated info for all adapters
static EnumeratedInfo<GDN::Dependent::OS::Graphics::API> =
GetEnumeratedInfo();
//returns the enumerated info for one adapter, this may not make =
sense in GL
static EnumeratedInfo<GDN::Dependent::OS::Graphics::API>::AdapterInfo =
GetAdapterInfo(unsigned int adapter);
//default constructor
Renderer();
//constructor taking information for a single display, does not call =
Create. Also procides functionality for multi mon
Renderer(AdapterSettings &AS); //see the definition of this struct in =
Renderer.h Has DisplayDevice, DisplaySettings, =
//and an adapter number (which may not make sense in GL). We =
could specialize =
//AdapterSettings for each API, unless you just want to ignore the =
adapter number in GL
//constructor taking information for multihead, may not make sense in =
GL
Renderer(std::vector<AdapterSettings> &AS); //first adapter ordinal =
is taken as the head
bool Setup(AdapterSettings &AS); //for single or multimon
bool Setup(std::vector<AdapterSettings> &AS); //for multihead
//does the display initialization
bool Create();
bool Create(AdapterSettings &AS);
bool Create(std::vector<AdapterSettings> &AS); //for multihead
//does the display reinitialization, maybe doesn't make sense in GL
bool Reset();
bool Reset(AdapterSettings &AS);
bool Reset(std::vector<AdapterSettings> &AS); //for multihead
bool Clear(); //clears all children
bool Clear(unsigned int displaynumber); //clears only a child monitor =
in multihead mode
bool Clear(/*Clear settings here(as you had them before, I can't =
remember them exactly*/);
=20
bool Present(); //flips all children
bool Present(unsigned int displaynumber); //or flip. flips a child =
monitor in multihead
bool IsValid(); //returns whether this display is ready and created
=20
//access functions
AdapterSettings GetAdapterSettings();
GDN::Application::DisplayDevice GetDisplayDevice();
DisplaySettings GetDisplaySettings();
unsigned int GetAdapterNum();
//now for the matrices and stuff =20
GDN::Math::Matrix4<float> GetView(); //for single monitors, makes it =
easier
GDN::Math::Matrix4<float> GetView(unsigned int adapternum); //for =
children
void SetView(GDN::Math::Matrix4<float> &newview);
void SetView(GDN::Math::Matrix4<float> &newview, unsigned int =
adapternum);
GDN::Math::Matrix4<float> GetWorld(); //for single monitors, makes it =
easier
GDN::Math::Matrix4<float> GetWorld(unsigned int adapternum); //for =
children
void SetWorld(GDN::Math::Matrix4<float> &newworld);
void SetWorld(GDN::Math::Matrix4<float> &newworld, unsigned int =
adapternum);
GDN::Math::Matrix4<float> GetProjection(); //for single monitors, =
makes it easier
GDN::Math::Matrix4<float> GetProjection(unsigned int adapternum); =
//for children
void SetProjection(GDN::Math::Matrix4<float> &newprojection);
void SetProjection(GDN::Math::Matrix4<float> &newprojection, unsigned =
int adapternum);
//probably forgot something, feel free to add stuff
=20
};
}
}
#endif
|