⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 track.h

📁 游戏编程精粹2第六章源码
💻 H
字号:
/* Copyright (C) Scott Patterson, 2001. 
 * All rights reserved worldwide.
 *
 * This software is provided "as is" without express or implied
 * warranties. You may freely copy and compile this source into
 * applications you distribute provided that the copyright text
 * below is included in the resulting source code, for example:
 * "Portions Copyright (C) Scott Patterson, 2001"
 */

// Track.h

#ifndef TRACK_H
#define TRACK_H

#include "Def.h"
#include "MusicTypes.h"
#include "Voice.h"
#include "TrackData.h"

class Sequence_t;
class InstrumentData_t;

class TrackState_t {
public:
    Volume_t    m_Volume;
    PitchBend_t m_PitchBend; // unused in this demo
    Pan_t       m_Pan;
    Effect_t    m_Effect;    // unused in this demo

	PlayInit();
};

class TrackInterpolator_t {
public:
	Volume_t    m_VolumeStep;
};

class Track_t {
public:
	bool                          m_bActive;         // this track is playing
    TrackState_t                  m_State;
	TrackState_t                  m_TargetState;     // interactive feature
	TrackInterpolator_t           m_Interpolator;    // interactive feature
    Sequence_t                   *m_pOwner;
    TimeInt_t                     m_TimeElapsedInt;
	EventDataPtrList_t::iterator  m_iEDPLStart;
	EventDataPtrList_t::iterator  m_iEDPLEnd;
	EventDataPtrList_t::iterator  m_iEDPL;           // the current event pending
    InstrumentData_t             *m_pInstrumentData;
    VoicePtrList_t                m_VoicePtrList;
};

typedef std::vector< Track_t >    TrackVector_t;
typedef std::list< Track_t * >    TrackPtrList_t;

#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -