OSDN Git Service

#xxxxx DTXViewerのプロジェクトを追加。
[dtxmania/dtxmania.git] / DTXViewerプロジェクト / @DTXViewerプロジェクト / ソースファイル / CStagePlay.h
diff --git a/DTXViewerプロジェクト/@DTXViewerプロジェクト/ソースファイル/CStagePlay.h b/DTXViewerプロジェクト/@DTXViewerプロジェクト/ソースファイル/CStagePlay.h
new file mode 100644 (file)
index 0000000..18ddd9f
--- /dev/null
@@ -0,0 +1,84 @@
+#pragma once
+
+// FDK includes
+#include "DTX.h"
+#include "CSurface.h"
+#include "CTexture.h"
+#include "CCounter.h"
+// App includes
+#include "CStage.h"
+#include "ActPlayAVI.h"
+#include "ActPlayBGA.h"
+
+namespace DTXViewer {
+       namespace Stage {
+               namespace Play {
+
+enum EPlayPart
+{
+       PLAYPART_UNKNOWN        = -1,
+       PLAYPART_DRUMS          = 0,
+       PLAYPART_GUITAR         = 1,
+       PLAYPART_BASS           = 2
+};
+
+class CStagePlay : public CStage
+{
+public:
+       bool    Load( LPCTSTR strFileName );
+       void    Play( int nPart );
+       void    Stop();
+
+       virtual int             MainWork();
+       CStagePlay();
+
+protected:
+       struct _struct\89\89\91t\8fî\95ñ {
+               bool                    b\89\89\91t\92\86;
+               DTX::Chip*              p\8c»\8dÝ\82Ì\83g\83b\83vChip;
+               int                             n\8c»\8dÝ\82Ì\8f¬\90ß\94Ô\8d\86\81E\83f\83o\83b\83O\95\\8e¦\97p;
+               double                  db\8c»\8dÝ\82ÌBPM\81E\83f\83o\83b\83O\95\\8e¦\97p;
+               double                  db\8aJ\8en\8e\9e\8d\8fms;
+               int                             n\8dÅ\8cã\82É\8dÄ\90\82µ\82½BGM\82Ì\8eÀWAV\94Ô\8d\86[50];      // -1=\96¢\8dÄ\90
+               int                             n\8dÅ\8cã\82É\8dÄ\90\82µ\82½HH\82ÌWAV\94Ô\8d\86;                     // LC\82Í\96³\8aÖ\8cW, -1=\96¢\8dÄ\90
+               int                             n\8dÅ\8cã\82É\8dÄ\90\82µ\82½HH\82Ì\83`\83\83\83\93\83l\83\8b\94Ô\8d\86;      // LC\82Í\96³\8aÖ\8cW,  0=\96¢\8dÄ\90
+               int                             n\8dÅ\8cã\82É\8dÄ\90\82µ\82½\83M\83^\81[\82ÌWAV\94Ô\8d\86;         // -1=\96¢\8dÄ\90
+               int                             n\8dÅ\8cã\82É\8dÄ\90\82µ\82½\83x\81[\83X\82ÌWAV\94Ô\8d\86;         // -1=\96¢\8dÄ\90
+       } struct\89\89\91t\8fî\95ñ;
+
+       CSurface                sfMap;
+       CTexture                txNumbers;
+
+       ActPlayAVI              actAVI;
+       ActPlayBGA              actBGA;
+
+       CCounter        ctNowLoading\95\\8e¦;
+       bool            bLoading\97v\90¿\82 \82è;
+       tstring         strFileName;
+       bool            bPlaying\97v\90¿\82 \82è;
+       int                     n\8aJ\8en\8f¬\90ß\94Ô\8d\86;
+
+       void    SkipStart( double db\8aJ\8en\8e\9e\8d\8fms );
+       void    ProcessCell( DTX::Chip* pChip, bool bSkip );
+       void    t\90\94\8e\9a\95`\89æ( int rx, int by, int num );
+       void    t\83T\83E\83\93\83h\8dÄ\90¶( DTX::Chip* pChip, EPlayPart part, long l\89¹\97Ê=DTX_PLAYVOLUME );
+       bool    tDTX\83t\83@\83C\83\8b\82Ì\93Ç\82Ý\8d\9e\82Ý();
+       void    t\8dÄ\90\8aJ\8en();
+       void    t\89\89\91t\8fî\95ñ\82ð\8f\89\8aú\89»\82·\82é();
+
+       virtual bool    MyOneTimeSceneInit();
+       virtual bool    MyActivate();
+       virtual bool    MyUnActivate();
+       virtual bool    MyFinalCleanup();
+       virtual bool    MyInitDeviceObjects();
+       virtual bool    MyRestoreDeviceTextures();
+       virtual bool    MyRestoreDeviceSurfaces();
+       virtual bool    MyInvalidateDeviceObjects();
+       virtual bool    MyDeleteDeviceObjects();
+};
+
+               }//Play
+       }//Stage
+}//DTXViewer
+
+using namespace DTXViewer::Stage::Play;