CommonLibVR
Loading...
Searching...
No Matches
BSSoundHandle.h
Go to the documentation of this file.
1#pragma once
2
3namespace RE
4{
5 class BSISoundOutputModel;
6 class NiAVObject;
7 class NiPoint3;
8
10 {
11 public:
12 enum : std::uint32_t
13 {
14 kInvalidID = static_cast<std::uint32_t>(-1)
15 };
16
17 enum class AssumedState
18 {
19 kInitialized = 0,
20 kPlaying = 1,
21 kStopped = 2,
22 kPaused = 3
23 };
24
25 enum class LoopType
26 {
27 kNone = 0,
28 kWholeFile = 1,
29 kEnvFast = 2,
30 kEnvSlow = 3
31 };
32
34 ~BSSoundHandle() = default;
35
36 bool FadeInPlay(std::uint16_t a_fadeTimeMS);
37 bool FadeOutAndRelease(std::uint16_t a_fadeTimeMS);
38 std::uint64_t GetDuration();
39 [[nodiscard]] bool IsPlaying() const;
40 [[nodiscard]] bool IsValid() const;
41 bool SetFrequency(float a_frequency);
42 bool SetPosition(NiPoint3 a_pos);
44 void SetOutputModel(const BSISoundOutputModel* a_outputModel);
45 bool SetVolume(float a_volume);
46 bool Stop();
47 bool Play();
48 bool Pause();
49
50 // members
51 std::uint32_t soundID; // 00
52 bool assumeSuccess; // 04
53 std::uint8_t pad05; // 05
54 std::uint16_t pad06; // 06
56 private:
58 };
59 static_assert(sizeof(BSSoundHandle) == 0xC);
60}
#define KEEP_FOR_RE()
Definition PCH.h:517
Definition EnumSet.h:9
Definition BSISoundOutputModel.h:6
Definition NiAVObject.h:57
Definition NiPoint3.h:6
Definition AbsorbEffect.h:6
Definition BSSoundHandle.h:10
~BSSoundHandle()=default
std::uint8_t pad05
Definition BSSoundHandle.h:53
bool FadeOutAndRelease(std::uint16_t a_fadeTimeMS)
bool IsPlaying() const
std::uint16_t pad06
Definition BSSoundHandle.h:54
bool SetFrequency(float a_frequency)
bool assumeSuccess
Definition BSSoundHandle.h:52
bool FadeInPlay(std::uint16_t a_fadeTimeMS)
@ kInvalidID
Definition BSSoundHandle.h:14
bool IsValid() const
REX::EnumSet< AssumedState, std::uint32_t > state
Definition BSSoundHandle.h:55
std::uint32_t soundID
Definition BSSoundHandle.h:51
bool SetVolume(float a_volume)
AssumedState
Definition BSSoundHandle.h:18
bool SetPosition(NiPoint3 a_pos)
std::uint64_t GetDuration()
void SetOutputModel(const BSISoundOutputModel *a_outputModel)
void SetObjectToFollow(NiAVObject *a_node)
LoopType
Definition BSSoundHandle.h:26