Develop and Download Open Source Software

Browse Subversion Repository

Contents of /sound/MusicManager.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 279 - (show annotations) (download) (as text)
Wed Mar 12 05:28:19 2008 UTC (16 years, 1 month ago) by satofumi
File MIME type: text/x-chdr
File size: 2410 byte(s)
adjust tab index
1 #ifndef MUSIC_MANAGER_H
2 #define MUSIC_MANAGER_H
3
4 /*!
5 \file
6 \brief ”wŒi‹Č‚ĚŠÇ—
7
8 \author Satofumi KAMIMURA
9
10 $Id$
11 */
12
13 #include <memory>
14
15
16 namespace beego {
17 /*!
18 \brief ”wŒi‹Č‚ĚŠÇ—ƒNƒ‰ƒX
19 */
20 class MusicManager {
21 MusicManager(const MusicManager& rhs);
22 MusicManager& operator = (const MusicManager& rhs);
23
24 struct pImpl;
25 //const std::auto_ptr<pImpl> pimpl;
26 // !!! shared_ptr ‚É‚ˇ‚ׂŤ‚Č‚Ě‚ŠH
27 pImpl* pimpl;
28
29 public:
30 enum {
31 Infinity = -1, //!< –łŒŔ‰ń‚̍Đś
32 };
33 MusicManager(void);
34 ~MusicManager(void);
35
36 /*!
37 \brief ‰Šú‰ťĎ‚Ý‚Š‚đ•Ô‚ˇ
38
39 \retval true ‰Šú‰ťĎ‚Ý
40 \retval false –˘‰Šú‰ť
41 */
42 bool isInitialized(void);
43
44 /*!
45 \brief ‰šŠy‚Ě“o˜^
46
47 \param music_id [i] “o˜^‚ľ‚˝‚˘ ID ”ԍ†
48 \param file_path [i] ‰šŠyƒtƒ@ƒCƒ‹‚Ě‚ ‚éƒpƒX
49
50 \retval true “o˜^ŹŒ÷
51 \retval false “o˜^ޏ”s
52
53 \attention “Ż‚ś music_id ‚Ş•Ą”Žw’肳‚ę‚˝ę‡AĹŒă‚ĚŽw’肪—LŒř‚ɂȂé
54 */
55
56 bool registerMusic(int music_id, const char* file_path);
57
58 /*!
59 \brief ‰šŠy‚Ě“o˜^íœ
60
61 \param music_id [i] íœ‚ľ‚˝‚˘ ID ”ԍ†
62 */
63 void unregisterMusic(int music_id);
64
65 /*!
66 \brief ‰š—ʂ̊„‡‚đÝ’č
67
68 \param percent [i] ‰šŠy‚̏o—̓{ƒŠƒ…[ƒ€Ý’u [%]
69 */
70 void updateVolume(size_t percent);
71
72 /*!
73 \brief ‹Č‚̐؂č‘Ö‚Ś
74
75 \param next_music_id [i] ŽŸ‚ɍĐś‚ł‚š‚鉚Šy‚Ě ID ”ԍ†
76 \param play_times [i] Äś‰ń” (0 ‚ōĐś’âŽ~)
77 */
78 void setNextMusic(int next_music_id, int play_times = Infinity);
79
80 /*!
81 \brief ‹Č‚Ě’âŽ~
82
83 \param fade_out_msec [i] ƒtƒF[ƒhƒAƒEƒgŽžŠÔ [msec]
84 */
85 void stop(size_t fade_out_msec = 0);
86
87 void halt(void);
88
89 /*!
90 \brief ƒtƒF[ƒhƒCƒ“Ý’č
91
92 setNextMusic() Žž‚É—˜—p‚ł‚ę‚é
93
94 \param effect_msec [i] ƒtƒF[ƒhƒCƒ“ŽžŠÔ [msec]
95 */
96 void setFadeInEffect(size_t effect_msec);
97
98 /*!
99 \brief ƒtƒF[ƒhƒAƒEƒgÝ’č
100
101 setNextMusic(), stop() Žž‚É—˜—p‚ł‚ę‚é
102
103 \param effect_msec [i] ƒtƒF[ƒhƒAƒEƒgŽžŠÔ [msec]
104 */
105 void setFadeOutEffect(size_t effect_msec);
106
107 /*!
108 \brief ŒťÝÄś’†‚̉šŠy”ԍ†‚đŽw’č
109
110 \return Äś’†‚̉šŠy”ԍ†
111
112 \attention Äś’†o‚Č‚˘ę‡A–ß‚č’l‚Í–łŒř
113 */
114 int getCurrentMusicId(void);
115
116 /*!
117 \brief Äś’†‚Š‚đ•Ô‚ˇ
118
119 \retval true Äś’†
120 \retval false ’âŽ~’†
121 */
122 bool nowPlaying(void);
123 };
124 };
125
126 #endif /* !MUSIC_MANAGER_H */

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26