📄 appstateintro.h
字号:
/*
* ==============================================================================
* Name : AppStateIntro.h
* Part of : RGA Game Example
* Interface :
* Description : application intro state
* Version : 1.0
*
* Copyright (c) 2007-2008 Nokia Corporation.
* This material, including documentation and any related
* computer programs, is protected by copyright controlled by
* Nokia Corporation.
* ==============================================================================
*/
#ifndef __APPSTATEINTRO_H__
#define __APPSTATEINTRO_H__
#include "AppState.h"
#include <display.h> // rga
#include <videoplayback.h> // rga
class CAppStateIntro : public CAppState,
public IVideoPlaybackObserver
{
public:
CAppStateIntro(CExampleApplication& aApp);
virtual ~CAppStateIntro();
/**
* Init
* Initialise the state
* @return KErrNone if successfull
*/
virtual TInt Init();
/**
* Update
* Update application state
* @param aFrametime seconds elapsed since last frame
* @return state change value
*/
virtual EAppUpdateState Update(const TReal64& aFrametime);
/**
* Draw
* Draw state graphics to given graphics context
* @param aContext graphics context to draw to.
*/
virtual void Draw(IGraphicsContext& aContext);
/**
* KeyDown
* This handler is called by the main application object
* when any key is pressed
* @param aKeyCode RGA input key code of the pressed key
*/
virtual void KeyDown(TUint32 aKeyCode);
private: // from IVideoPlaybackObserver
virtual void OpenCompleted( ReturnCode aError ) NO_THROW;
virtual void PlayCompleted( ReturnCode aError ) NO_THROW;
private: // new functions
/**
* InitVideoplayer
*/
TInt InitVideoplayer();
/**
* UpdateIntroState
* Change intro State to next one
*/
void UpdateIntroState();
/**
* ReleaseVideoPlayer
* release video player resources
*/
void ReleaseVideoPlayer();
private: // data
IBitmap* iTextBuffer;
IGraphicsContext* iTextBufferContext;
IBitmap* iAlphaBuffer;
IGraphicsContext* iAlphaBufferContext;
TInt iIntroState;
TReal64 iIntroTimer;
EAppUpdateState iNextState;
// video playback objects
IVideoPlayback* iVideoPlayer;
TFileName iVideoFilename;
};
#endif /* __APPSTATEINTRO_H__*/
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -