![]() |
Blamite Game Engine - blam!
00453.06.08.26.0624.blamite
The core library for the Blamite Game Engine.
|
Usage: To record: Start app with –ut_record=/home/username/Ogre/pbs.json –ut_compress Move around and press F12 to take a picture To playback: –ut_playback=/home/username/Ogre/pbs.json –ut_output=/home/username/Ogre/. More...
#include <UnitTesting.h>
Inheritance diagram for Demo::UnitTest:
Collaboration diagram for Demo::UnitTest:Classes | |
| struct | Params |
Public Member Functions | |
| UnitTest () | |
| void | parseCmdLine (int nargs, const char *const *argv) |
| const Params & | getParams (void) const |
| void | startRecording (Demo::GraphicsSystem *graphicsSystem) |
| void | notifyRecordingNewFrame (Demo::GraphicsSystem *graphicsSystem) |
| void | saveToJson (const char *fullpath, const bool bCompressDuration) |
| Saves the current recording to JSON, for later playback. More... | |
| virtual void | keyPressed (const SDL_KeyboardEvent &arg) |
| virtual void | keyReleased (const SDL_KeyboardEvent &arg) |
| virtual void | mouseMoved (const SDL_Event &arg) |
| virtual void | mousePressed (const SDL_MouseButtonEvent &arg, Ogre::uint8 id) |
| virtual void | mouseReleased (const SDL_MouseButtonEvent &arg, Ogre::uint8 id) |
| int | loadFromJson (const char *fullpath, const Ogre::String &outputFolder) |
| Loads JSON from fullpath and plays it back, saving the results to outputFolder Return value is the return value for main() More... | |
Public Member Functions inherited from Demo::KeyboardListener | |
| virtual void | textEditing (const SDL_TextEditingEvent &arg) |
| virtual void | textInput (const SDL_TextInputEvent &arg) |
Protected Member Functions | |
| void | exportFrameActivity (const FrameActivity &frameActivity, Ogre::LwString &jsonStr, std::string &outJson) |
| void | saveToJsonStr (std::string &outJson) |
| int | runLoop (Ogre::String outputFolder) |
Static Protected Member Functions | |
| static void | flushLwString (Ogre::LwString &jsonStr, std::string &outJson) |
| static bool | shouldRecordKey (const SDL_KeyboardEvent &arg) |
| static Ogre::Vector3 | getCameraRecordPosition (Ogre::Camera *camera) |
Protected Attributes | |
| double | mFrametime |
| uint32_t | mFrameIdx |
| uint32_t | mNumFrames |
| KeyboardListener * | mRealKeyboardListener |
| MouseListener * | mRealMouseListener |
| std::vector< FrameActivity > | mFrameActivity |
| Params | mParams |
| bool | mBlockInputForwarding |
Usage: To record: Start app with –ut_record=/home/username/Ogre/pbs.json –ut_compress Move around and press F12 to take a picture To playback: –ut_playback=/home/username/Ogre/pbs.json –ut_output=/home/username/Ogre/.
ut_compress is optional (recommended) ut_output is where the the app should dump the captures (i.e. where you pressed F12) ut_skip_dump can be used in playback to skip dumping (i.e. to debug an error)
| Demo::UnitTest::UnitTest | ( | ) |
|
protected |
Here is the call graph for this function:
Here is the caller graph for this function:
|
inlinestaticprotected |
Here is the caller graph for this function:
|
staticprotected |
|
inline |
Here is the caller graph for this function:
|
virtual |
|
virtual |
| int Demo::UnitTest::loadFromJson | ( | const char * | fullpath, |
| const Ogre::String & | outputFolder | ||
| ) |
Loads JSON from fullpath and plays it back, saving the results to outputFolder Return value is the return value for main()
Here is the call graph for this function:
Here is the caller graph for this function:
|
virtual |
|
virtual |
|
virtual |
| void Demo::UnitTest::notifyRecordingNewFrame | ( | Demo::GraphicsSystem * | graphicsSystem | ) |
Here is the call graph for this function:
Here is the caller graph for this function:| void Demo::UnitTest::parseCmdLine | ( | int | nargs, |
| const char *const * | argv | ||
| ) |
Here is the caller graph for this function:
|
protected |
Here is the call graph for this function:
Here is the caller graph for this function:| void Demo::UnitTest::saveToJson | ( | const char * | fullpath, |
| const bool | bCompressDuration | ||
| ) |
Saves the current recording to JSON, for later playback.
| fullpath | Full path where to save the JSON file |
| bCompressDuration | When true, we assume mNumFrames can be reduced to a minimum. Thus if recording took 70 seconds but there's only 8 FrameActivity, then it will be compressed to roughly 11 frames. |
Here is the call graph for this function:
Here is the caller graph for this function:
|
protected |
Here is the call graph for this function:
Here is the caller graph for this function:
|
staticprotected |
Here is the caller graph for this function:| void Demo::UnitTest::startRecording | ( | Demo::GraphicsSystem * | graphicsSystem | ) |
Here is the caller graph for this function:
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |