Gnash
0.8.10
|
#include <dump.h>
Public Member Functions | |
DumpGui (unsigned long xid, float scale, bool loop, RunResources &r) | |
~DumpGui () | |
void | beforeRendering () |
bool | createMenu () |
bool | createMenuBar () |
bool | createWindow (int width, int height) |
bool | createWindow (const char *, int width, int height, int, int) |
Create and display our window. | |
bool | init (int argc, char **argv[]) |
/ Initialise the gui and the associated renderer. | |
virtual void | quitUI () |
End main rendering loop calling GUI-specific exit functions. | |
void | renderBuffer () |
void | render () |
void | render (int, int, int, int) |
bool | run () |
Start main rendering loop. | |
void | setInterval (unsigned int interval) |
Set main loop delay in milliseconds. | |
void | setTimeout (unsigned int timeout) |
Set the time in milliseconds after which the programme should exit. | |
bool | setupEvents () |
void | setFullscreen () |
void | setInvalidatedRegion (const SWFRect &) |
Gives the GUI a *hint* which region of the stage should be redrawn. | |
void | setInvalidatedRegions (const InvalidatedRanges &) |
void | setCursor (gnash_cursor_type) |
Sets the current mouse cursor for the Gui window. | |
void | setRenderHandlerSize (int width, int height) |
void | unsetFullscreen () |
bool | want_multiple_regions () |
bool | want_redraw () |
Asks the GUI handler if the next frame should be redrawn completely. | |
void | writeFrame () |
void | writeSamples () |
virtual VirtualClock & | getClock () |
Return the clock provided by this Gui. |
gnash::DumpGui::DumpGui | ( | unsigned long | xid, |
float | scale, | ||
bool | loop, | ||
RunResources & | r | ||
) |
References gnash::Gui::_xid.
gnash::DumpGui::~DumpGui | ( | ) |
void gnash::DumpGui::beforeRendering | ( | ) | [virtual] |
Reimplemented from gnash::Gui.
bool gnash::DumpGui::createMenu | ( | ) | [inline] |
bool gnash::DumpGui::createMenuBar | ( | ) | [inline] |
bool gnash::DumpGui::createWindow | ( | int | width, |
int | height | ||
) |
bool gnash::DumpGui::createWindow | ( | const char * | title, |
int | width, | ||
int | height, | ||
int | xPosition, | ||
int | yPosition | ||
) | [inline, virtual] |
Create and display our window.
title | The window title. |
width | The desired window width in pixels. |
height | The desired window height in pixels. |
xPosition | The desired window X position from the top left corner. |
yPosition | The desired window Y position from the top left corner. |
Implements gnash::Gui.
References createWindow().
Referenced by createWindow().
virtual VirtualClock& gnash::DumpGui::getClock | ( | ) | [inline, virtual] |
Return the clock provided by this Gui.
The Gui clock will be paused when the gui is put in pause mode and resumed when gui playback is resumed.
Reimplemented from gnash::Gui.
bool gnash::DumpGui::init | ( | int | argc, |
char ** | argv[] | ||
) | [virtual] |
/ Initialise the gui and the associated renderer.
argc | The commandline argument count. |
argv | The commandline arguments. |
Implements gnash::Gui.
References gnash::Gui::_xid, _, optind, gnash::key::c, getopt(), optarg, gnash::terminate_signal(), gnash::Gui::_renderer, gnash::create_Renderer_agg(), gnash::Gui::_runResources, gnash::RunResources::setRenderer(), gnash::RunResources::soundHandler(), gnash::RunResources::mediaHandler(), and gnash::RunResources::setSoundHandler().
void gnash::DumpGui::quitUI | ( | ) | [virtual] |
End main rendering loop calling GUI-specific exit functions.
Do not call this directly. Call quit() instead. The default implementation calls exit(EXIT_SUCCESS), which isn't nice. Please implement the proper main loop quitter in the subclasses.
Reimplemented from gnash::Gui.
References gnash::terminate_request.
void gnash::DumpGui::render | ( | ) | [inline] |
void gnash::DumpGui::render | ( | int | , |
int | , | ||
int | , | ||
int | |||
) | [inline] |
void gnash::DumpGui::renderBuffer | ( | ) | [inline, virtual] |
Render the current buffer. For OpenGL, this means that the front and back buffers are swapped.
Implements gnash::Gui.
bool gnash::DumpGui::run | ( | ) | [virtual] |
Start main rendering loop.
Implements gnash::Gui.
References gnash::Gui::_interval, gnash::terminate_request, gnash::ManualClock::elapsed(), gnash::ManualClock::advance(), gnash::Gui::advanceMovie(), writeSamples(), writeFrame(), gnash::gnashSleep(), path, gnash::parsePath(), gnash::Gui::getStage(), gnash::movie_root::getRootMovie(), gnash::MovieClip::get_environment(), gnash::key::o, gnash::findObject(), gnash::as_object::get_member(), gnash::getURI(), gnash::movie_root::getVM(), gnash::as_value::equals(), and gnash::Gui::quit().
void gnash::DumpGui::setCursor | ( | gnash_cursor_type | newcursor | ) | [inline, virtual] |
Sets the current mouse cursor for the Gui window.
Reimplemented from gnash::Gui.
void gnash::DumpGui::setFullscreen | ( | ) | [inline, virtual] |
Attempt to run in a fullscreen window both for plugin and standalone player. Use isFullscreen() to see if gnash thinks it's running in fullscreen or not. The switch to fullscreen may fail if, for instance, the window manager refuses to allow it, but the flag will be set anyway.
Reimplemented from gnash::Gui.
void gnash::DumpGui::setInterval | ( | unsigned int | interval | ) | [virtual] |
Set main loop delay in milliseconds.
Reimplemented from gnash::Gui.
References gnash::Gui::_interval.
void gnash::DumpGui::setInvalidatedRegion | ( | const SWFRect & | bounds | ) | [inline, virtual] |
Gives the GUI a *hint* which region of the stage should be redrawn.
There is *no* restriction what the GUI might do with these coordinates. Normally the GUI forwards the information to the renderer so that it avoids rendering regions that did not change anyway. The GUI can also alter the bounds before passing them to the renderer and it's absolutely legal for the GUI to simply ignore the call.
Coordinates are in TWIPS!
Note this information is given to the GUI and not directly to the renderer because both of them need to support this feature for correct results. It is up to the GUI to forward this information to the renderer.
Reimplemented from gnash::Gui.
void gnash::DumpGui::setInvalidatedRegions | ( | const InvalidatedRanges & | ) | [inline, virtual] |
Reimplemented from gnash::Gui.
void gnash::DumpGui::setRenderHandlerSize | ( | int | width, |
int | height | ||
) |
References assert, gnash::Gui::_width, gnash::Gui::_height, width, height, gnash::key::e, and gnash::Renderer_agg_base::init_buffer().
Referenced by createWindow().
void gnash::DumpGui::setTimeout | ( | unsigned int | timeout | ) | [virtual] |
Set the time in milliseconds after which the programme should exit.
Implements gnash::Gui.
bool gnash::DumpGui::setupEvents | ( | ) | [inline] |
void gnash::DumpGui::unsetFullscreen | ( | ) | [inline, virtual] |
Return from fullscreen to normal mode.
Reimplemented from gnash::Gui.
bool gnash::DumpGui::want_multiple_regions | ( | ) | [inline, virtual] |
Reimplemented from gnash::Gui.
bool gnash::DumpGui::want_redraw | ( | ) | [inline, virtual] |
Asks the GUI handler if the next frame should be redrawn completely.
For example, when the contents of the player window have been destroyed, then want_redraw() should return true so that setInvalidatedRegion() is called with the coordinates of the complete screen.
Reimplemented from gnash::Gui.
void gnash::DumpGui::writeFrame | ( | ) |
References gnash::ManualClock::elapsed().
Referenced by run().
void gnash::DumpGui::writeSamples | ( | ) |
References gnash::Gui::_runResources, gnash::RunResources::soundHandler(), gnash::ManualClock::elapsed(), gnash::key::n, gnash::key::u, and gnash::sound::sound_handler::fetchSamples().
Referenced by run().