2014-03-27 18:10:15 +00:00
|
|
|
#ifndef OPENMW_MWGUI_VIDEOWIDGET_H
|
|
|
|
#define OPENMW_MWGUI_VIDEOWIDGET_H
|
|
|
|
|
|
|
|
#include <MyGUI_ImageBox.h>
|
|
|
|
|
|
|
|
#include "../mwrender/videoplayer.hpp"
|
|
|
|
|
|
|
|
namespace MWGui
|
|
|
|
{
|
|
|
|
|
|
|
|
/**
|
2014-06-09 23:57:54 +00:00
|
|
|
* Widget that plays a video.
|
2014-03-27 18:10:15 +00:00
|
|
|
*/
|
|
|
|
class VideoWidget : public MyGUI::ImageBox
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
MYGUI_RTTI_DERIVED(VideoWidget)
|
|
|
|
|
|
|
|
VideoWidget();
|
|
|
|
|
2014-06-09 23:57:54 +00:00
|
|
|
void playVideo (const std::string& video);
|
2014-03-27 18:10:15 +00:00
|
|
|
|
|
|
|
int getVideoWidth();
|
|
|
|
int getVideoHeight();
|
|
|
|
|
|
|
|
/// @return Is the video still playing?
|
|
|
|
bool update();
|
|
|
|
|
2014-06-09 23:57:54 +00:00
|
|
|
/// Stop video and free resources (done automatically on destruction)
|
|
|
|
void stop();
|
2014-06-05 13:39:08 +00:00
|
|
|
|
2014-03-27 18:10:15 +00:00
|
|
|
private:
|
|
|
|
MWRender::VideoPlayer mPlayer;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|