NSMBW-Decomp
A decompilation of New Super Mario Bros. Wii
Loading...
Searching...
No Matches
snd_StrmChannel.h
1
#ifndef NW4R_SND_STRM_CHANNEL_H
2
#define NW4R_SND_STRM_CHANNEL_H
3
4
/*******************************************************************************
5
* headers
6
*/
7
8
#include <climits>
// CHAR_BIT
9
10
#include <types.h>
11
12
#include "nw4r/snd/snd_adpcm.h"
13
14
/*******************************************************************************
15
* types
16
*/
17
18
namespace
nw4r {
namespace
snd {
namespace
detail
19
{
20
// [R89JEL]:/bin/RVL/Debug/mainD.elf:.debug::0x2f927
21
struct
StrmChannel
22
{
23
void
*bufferAddress;
// size 0x04, offset 0x00
24
AdpcmParam
adpcmParam;
// size 0x28, offset 0x04
25
AdpcmLoopParam
adpcmLoopParam;
// size 0x06, offset 0x2c
26
u16 adpcmPredScale;
// size 0x02, offset 0x32
27
};
// size 0x34
28
}}}
// namespace nw4r::snd::detail
29
30
/*******************************************************************************
31
* classes and functions
32
*/
33
34
namespace
nw4r {
namespace
snd {
namespace
detail
35
{
36
// [R89JEL]:/bin/RVL/Debug/mainD.elf:.debug::0x2f7c6
37
class
StrmBufferPool
38
{
39
// methods
40
public
:
41
// methods
42
void
Setup(
void
*buffer, ulong size,
int
blockCount);
43
void
Shutdown();
44
45
ulong GetBlockSize()
const
{
return
mBlockSize; }
46
47
void
*Alloc();
48
void
Free(
void
*p);
49
50
// static members
51
private
:
52
static
int
const
BIT_PER_BYTE = CHAR_BIT;
// uhhh ok
53
static
int
const
BLOCK_MAX = 32;
54
55
// members
56
private
:
57
void
*mBuffer;
// size 0x04, offset 0x00
58
ulong mBufferSize;
// size 0x04, offset 0x04
59
ulong mBlockSize;
// size 0x04, offset 0x08
60
int
mBlockCount;
// size 0x04, offset 0x0c
61
int
mAllocCount;
// size 0x04, offset 0x10
62
byte_t mAllocFlags[ROUND_UP(BLOCK_MAX, BIT_PER_BYTE) / BIT_PER_BYTE];
// size 0x04, offset 0x14
63
};
// size 0x18
64
}}}
// namespace nw4r::snd::detail
65
66
#endif
// NW4R_SND_STRM_CHANNEL_H
nw4r::snd::detail::StrmBufferPool
Definition
snd_StrmChannel.h:38
nw4r::snd::AdpcmParam
Definition
snd_adpcm.h:22
nw4r::snd::detail::AdpcmLoopParam
Definition
snd_adpcm.h:33
nw4r::snd::detail::StrmChannel
Definition
snd_StrmChannel.h:22
include
lib
nw4r
snd
snd_StrmChannel.h
Made with ❤️ by
CLF78
and
RootCubed
. Logos by
Chasical
and
B1
. Website generated by
Doxygen
1.13.2