1#pragma once
2
3#include <basis/seadTypes.h>
4#include <container/seadPtrArray.h>
5#include <math/seadVector.h>
6
7namespace al {
8class BgmDirector;
9class BgmSituationDirector;
10class Bgm3DParamsController;
11class BgmLine;
12class BgmMultiPlayingController;
13class BgmPlayingRequest;
14class FunctorBase;
15class IBgmParamsChanger;
16class IUseAudioKeeper;
17class LiveActor;
18class Resource;
19
20class BgmDataBase {
21public:
22 static BgmDataBase* create(const char*, const char*);
23
24 BgmDataBase(const Resource*, const Resource*);
25};
26
27BgmDirector* getBgmDirector(const IUseAudioKeeper*);
28BgmDirector* tryGetBgmDirector(const IUseAudioKeeper*);
29BgmSituationDirector* getBgmSituationDirector(const IUseAudioKeeper*);
30Bgm3DParamsController* getBgm3DParamsController(const IUseAudioKeeper*);
31BgmLine* getActiveBgmLine(const IUseAudioKeeper*);
32BgmLine* getPlayingBgmLine(const IUseAudioKeeper*, const char*);
33const char* getCurPlayingBgmPlayName(const IUseAudioKeeper*);
34const char* getCurPlayingBgmResourceName(const IUseAudioKeeper*);
35const char* getBgmPlayNameInCurPosition(const IUseAudioKeeper*, bool);
36const char* getBgmResourceNameInCurPosition(const IUseAudioKeeper*, bool);
37s64 getActiveBgmCurSamplePosition(const IUseAudioKeeper*);
38s64 getBgmLoopEndSamplePosition(const IUseAudioKeeper*, const char*);
39void startBgm(const IUseAudioKeeper*, const char*, s32, s32);
40void startBgm(const IUseAudioKeeper*, const BgmPlayingRequest&, bool, bool);
41void startBgmWithSuffix(const IUseAudioKeeper*, const char*, const char*, s32, s32);
42void startAndStopBgmInCurPosition(const IUseAudioKeeper*, bool);
43void startBgmSituation(const IUseAudioKeeper*, const char*, bool);
44void prepareBgm(const IUseAudioKeeper*, const BgmPlayingRequest&);
45void prepareBgmWithAreaCheck(const IUseAudioKeeper*);
46void stopBgm(const IUseAudioKeeper*, const char*, s32);
47void stopBgm(const IUseAudioKeeper*, const BgmPlayingRequest&);
48void pauseBgm(const IUseAudioKeeper*, const char*, s32);
49void resumeBgm(const IUseAudioKeeper*, const char*, s32);
50bool isPlayingBgm(const IUseAudioKeeper*);
51bool isPlayingBgm(const IUseAudioKeeper*, const char*);
52bool isRunningBgm(const IUseAudioKeeper*, const char*);
53bool isPlayingResourceCategoryBgm(const IUseAudioKeeper*, const char*);
54void stopActiveBgm(const IUseAudioKeeper*, s32);
55void pauseActiveBgm(const IUseAudioKeeper*, s32);
56void resumeActiveBgm(const IUseAudioKeeper*, s32);
57bool isPlayingActiveBgm(const IUseAudioKeeper*, const char*);
58bool isPauseActiveBgm(const IUseAudioKeeper*);
59void stopAllBgm(const IUseAudioKeeper*, s32);
60void tryStopAllBgm(const IUseAudioKeeper*, s32);
61void setTriggerEventForStopAllBgm(const IUseAudioKeeper*, const FunctorBase&);
62void tryPauseBgmIfDifferBgmArea(const LiveActor*, const sead::Vector3f&, s32);
63void tryPauseBgmIfLowPriority(const IUseAudioKeeper*, const char*, s32);
64void startBgmSituation(const IUseAudioKeeper*, const char*, bool, bool);
65void startBgmSituation(const IUseAudioKeeper*, sead::PtrArray<IBgmParamsChanger>*, const char*,
66 bool, bool);
67void forceStartBgmSituation(const IUseAudioKeeper*, const char*, bool, bool);
68void endBgmSituation(const IUseAudioKeeper*, const char*, bool);
69void endBgmSituation(const IUseAudioKeeper*, sead::PtrArray<IBgmParamsChanger>*, const char*, bool);
70void forceEndBgmSituation(const IUseAudioKeeper*, const char*, bool);
71void startBgm3D(const IUseAudioKeeper*);
72void endBgm3D(const IUseAudioKeeper*);
73void changeBgm3DParams(const IUseAudioKeeper*, f32, f32, f32, f32, bool);
74void activateBgm3DController(const IUseAudioKeeper*);
75void deactivateBgm3DController(const IUseAudioKeeper*);
76bool isActivateBgm3DController(const IUseAudioKeeper*);
77s32 getActiveBgmSituationNum(const IUseAudioKeeper*);
78const char* getActiveBgmSituationName(const IUseAudioKeeper*, s32);
79s32 getDeactiveBgmSituationNum(const IUseAudioKeeper*);
80const char* getDeactiveBgmSituationName(const IUseAudioKeeper*, s32);
81void takeBgmSituationSnapShot(const IUseAudioKeeper*);
82void applyBgmSituationSnapShot(const IUseAudioKeeper*);
83void applyNoAppliedSituationRecord(const IUseAudioKeeper*);
84bool isStartedBgmSituation(const IUseAudioKeeper*, const char*);
85void endAllBgmSituation(const IUseAudioKeeper*);
86void clearBgmDataForStepOverScene(const IUseAudioKeeper*);
87void clearBgmPlayPointRecord(const IUseAudioKeeper*);
88void startBgmSyncedCurBgmBeat(const IUseAudioKeeper*, const BgmPlayingRequest&, s32);
89void stopBgmSyncedCurBgmBeat(const IUseAudioKeeper*, const BgmPlayingRequest&, s32);
90void disableBgmLineChange(const IUseAudioKeeper*);
91void enableBgmLineChange(const IUseAudioKeeper*);
92bool isDisableBgmLineChange(const IUseAudioKeeper*);
93void disableBgmSituationChange(const IUseAudioKeeper*);
94void enableBgmSituationChange(const IUseAudioKeeper*, bool);
95bool isDisableBgmSituationChange(const IUseAudioKeeper*);
96BgmMultiPlayingController* tryAllocBgmMultiPlayingController(const IUseAudioKeeper*);
97void tryReleaseBgmMultiPlayingController(const IUseAudioKeeper*, BgmMultiPlayingController*);
98s32 getBgmLineNum(const IUseAudioKeeper*, bool);
99BgmLine* getBgmLineAccessor(const IUseAudioKeeper*, s32, bool);
100s32 getgBgmLineIndex(const IUseAudioKeeper*, const char*, bool);
101void replaceBgmPlayInfoResourceName(const IUseAudioKeeper*, const char*, const char*);
102bool isEnableRhythmAnim(const IUseAudioKeeper*, const char*);
103bool isTriggerBeat(const IUseAudioKeeper*);
104bool isTriggerBackBeat(const IUseAudioKeeper*);
105bool isTriggerMeasureTop(const IUseAudioKeeper*);
106f32 getBpm(const IUseAudioKeeper*);
107f32 getBeatRate(const IUseAudioKeeper*);
108f32 getCurBeat(const IUseAudioKeeper*);
109f32 getCurBeatOnMeasure(const IUseAudioKeeper*);
110f32 getLoopStartBeat(const IUseAudioKeeper*);
111f32 getLoopEndBeat(const IUseAudioKeeper*);
112f32 getFramePerMeasure(const IUseAudioKeeper*);
113s32 getBeatPerMeasure(const IUseAudioKeeper*);
114bool isChangeActiveBgmResourceName(const IUseAudioKeeper*);
115bool tryRegistTargetBgmResourceName(const IUseAudioKeeper*, const char*);
116void muteOnRunningLineTrack(IUseAudioKeeper*, u32, bool);
117void muteOffRunningLineTrack(IUseAudioKeeper*, u32, bool);
118
119} // namespace al
120