#include <RenderWindow.hpp>
Inheritance diagram for sfRenderWindow:
Public Member Functions | |
sfRenderWindow () | |
sfRenderWindow (sfVideoMode Mode, const std::string &Title, bool Fullscreen) | |
sfRenderWindow (void *Handle) | |
virtual | ~sfRenderWindow () |
void | Create (sfVideoMode Mode, const std::string &Title, bool Fullscreen) |
void | Create (void *Handle) |
void | Display () |
void | Draw (sfDrawable &Object) |
void | Capture (const std::string &Filename) const |
void | SetBackgroundColor (const sfColor &Color) |
bool | GetEvent (sfEvent &Event) |
void | SetView (const sfView *View) |
const sfFloatRect & | GetViewRect () const |
void | BeginOpenGL () |
void | EndOpenGL () |
Definition at line 44 of file RenderWindow.hpp.
sfRenderWindow::sfRenderWindow | ( | ) |
Default constructor
Definition at line 39 of file RenderWindow.cpp.
sfRenderWindow::sfRenderWindow | ( | sfVideoMode | Mode, | |
const std::string & | Title, | |||
bool | Fullscreen | |||
) |
Construct the window
Mode | : Video mode to use | |
Title | : Title of the window | |
Fullscreen | : True to set fullscreen, false to stay in windowed mode |
Definition at line 50 of file RenderWindow.cpp.
References Create().
sfRenderWindow::sfRenderWindow | ( | void * | Handle | ) |
Construct the window from an existing control
Handle | : Platform-specific handle of the control |
Definition at line 61 of file RenderWindow.cpp.
References Create().
sfRenderWindow::~sfRenderWindow | ( | ) | [virtual] |
Destructor
Definition at line 72 of file RenderWindow.cpp.
void sfRenderWindow::Create | ( | sfVideoMode | Mode, | |
const std::string & | Title, | |||
bool | Fullscreen | |||
) |
Create the window
Mode | : Video mode to use | |
Title | : Title of the window | |
Fullscreen | : True to set fullscreen, false to stay in windowed mode |
Reimplemented from sfWindow.
Definition at line 82 of file RenderWindow.cpp.
References sfWindow::Create().
Referenced by sfRenderWindow().
void sfRenderWindow::Create | ( | void * | Handle | ) |
Create the window from an existing control
Handle | : Platform-specific handle of the control |
Reimplemented from sfWindow.
Definition at line 95 of file RenderWindow.cpp.
References sfWindow::Create().
void sfRenderWindow::Display | ( | ) |
Display window content on screen
Reimplemented from sfWindow.
Definition at line 108 of file RenderWindow.cpp.
References sfColor::Alpha, sfColor::Blue, sfWindow::Display(), sfColor::Green, sfColor::Red, and sfWindow::SetCurrent().
void sfRenderWindow::Draw | ( | sfDrawable & | Object | ) |
Draw something on the window
Object | : Object to draw |
Definition at line 136 of file RenderWindow.cpp.
References sfDrawable::Render(), and sfWindow::SetCurrent().
void sfRenderWindow::Capture | ( | const std::string & | Filename | ) | const |
Save the content of the window to a file
Filename | : Path of the file to save (overwritten if already exist) |
Definition at line 161 of file RenderWindow.cpp.
References sfWindow::GetHeight(), sfWindow::GetWidth(), sfImage::SaveToFile(), and sfWindow::SetCurrent().
void sfRenderWindow::SetBackgroundColor | ( | const sfColor & | Color | ) |
Change the background color of the window
Color | : New background color |
Definition at line 184 of file RenderWindow.cpp.
bool sfRenderWindow::GetEvent | ( | sfEvent & | Event | ) |
Get the event on top of events stack, if any
Event | : Event to fill, if any |
Reimplemented from sfWindow.
Definition at line 193 of file RenderWindow.cpp.
References sfWindow::GetEvent(), and sfEvent::Resize.
void sfRenderWindow::SetView | ( | const sfView * | View | ) |
Change the current active view
View | : Pointer to the new view (pass NULL to set default view) |
Definition at line 212 of file RenderWindow.cpp.
References sfRect< T >::Bottom, sfView::Height, sfRect< T >::Left, sfView::Left, sfRect< T >::Right, sfWindow::SetCurrent(), sfRect< T >::Top, sfView::Top, sfView::Width, and sfView::Zoom.
const sfFloatRect & sfRenderWindow::GetViewRect | ( | ) | const |
Get current view rectangle
Definition at line 248 of file RenderWindow.cpp.
void sfRenderWindow::BeginOpenGL | ( | ) |
Start custom OpenGL rendering
Definition at line 257 of file RenderWindow.cpp.
References sfWindow::SetCurrent().
void sfRenderWindow::EndOpenGL | ( | ) |
End custom OpenGL rendering
Definition at line 277 of file RenderWindow.cpp.
References sfWindow::SetCurrent().