-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathFadeListener.h
46 lines (44 loc) · 1.1 KB
/
FadeListener.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/////////////////////////////////////////////////////////////////////
///////////////Original file by:Fyodor Zagumennov aka Sgw32//////////
///////////////Copyright(c) 2010 Fyodor Zagumennov //////////
/////////////////////////////////////////////////////////////////////
//Fast fading ///
//(c) Sgw32 Corporation ///
///////////////////////////
#pragma once
#include <OgreFrameListener.h>
#include <Ogre.h>
#include <OIS/OIS.h>
#include <list>
#include <vector>
#include "fader.h"
using namespace Ogre;
using namespace std;
class FadeListener: public Singleton<FadeListener>, FrameListener
{
public:
FadeListener();
~FadeListener();
void init(Ogre::Root *root);
void rebuild();
void rebuild(String mat,bool return1);
void setDuration(Real dur);
void setDurationF(Real durf);
void setWait(Real ait)
{
wait=ait;
}
void setFadeColor(ColourValue col);
void startIN();
void startOUT();
virtual bool frameStarted(const Ogre::FrameEvent &evt);
private:
Fader* fader;
bool fadeb;
bool inited;
bool returnafter;
Real duration;
Real durationf;
Real wait;
Ogre::Root *root;
};