Initial commit
This commit is contained in:
commit
edfc5298e1
252 changed files with 93965 additions and 0 deletions
49
include/Spectre/Graphics.h
Normal file
49
include/Spectre/Graphics.h
Normal file
|
|
@ -0,0 +1,49 @@
|
|||
|
||||
#ifndef GRAPHICS_H
|
||||
#define GRAPHICS_H
|
||||
|
||||
#include <Spectre/Display/Display.h>
|
||||
|
||||
class PlatformApplication;
|
||||
|
||||
class Graphics
|
||||
{
|
||||
public :
|
||||
enum MatrixMode {
|
||||
PROJECTION,
|
||||
MODELVIEW,
|
||||
};
|
||||
|
||||
enum VertexType {
|
||||
TRIANGLES,
|
||||
};
|
||||
|
||||
public :
|
||||
Graphics(PlatformApplication *platform);
|
||||
~Graphics();
|
||||
|
||||
bool init();
|
||||
|
||||
void shutdown();
|
||||
|
||||
void setDisplayMode(Display::Mode mode);
|
||||
|
||||
void setSize(int width, int height);
|
||||
|
||||
void setViewport(int x, int y, int width, int height);
|
||||
|
||||
void setClearColor(float r, float g, float b);
|
||||
|
||||
void clearBuffer();
|
||||
|
||||
void swapBuffers();
|
||||
|
||||
protected :
|
||||
|
||||
int m_width;
|
||||
int m_height;
|
||||
|
||||
Display *m_display;
|
||||
};
|
||||
|
||||
#endif /* GRAPHICS_H */
|
||||
Loading…
Add table
Add a link
Reference in a new issue