11 #include "inprogext.h"
16 enum UserFmtType
: unsigned char {
26 enum UserFmtChannels
: unsigned char {
31 UserFmtX51
, /* (WFX order) */
32 UserFmtX61
, /* (WFX order) */
33 UserFmtX71
, /* (WFX order) */
34 UserFmtBFormat2D
, /* WXY */
35 UserFmtBFormat3D
, /* WXYZ */
39 /* Storable formats */
40 enum FmtType
: unsigned char {
41 FmtUByte
= UserFmtUByte
,
42 FmtShort
= UserFmtShort
,
43 FmtFloat
= UserFmtFloat
,
44 FmtDouble
= UserFmtDouble
,
45 FmtMulaw
= UserFmtMulaw
,
46 FmtAlaw
= UserFmtAlaw
,
48 enum FmtChannels
: unsigned char {
49 FmtMono
= UserFmtMono
,
50 FmtStereo
= UserFmtStereo
,
51 FmtRear
= UserFmtRear
,
52 FmtQuad
= UserFmtQuad
,
56 FmtBFormat2D
= UserFmtBFormat2D
,
57 FmtBFormat3D
= UserFmtBFormat3D
,
59 #define MAX_INPUT_CHANNELS (8)
62 ALuint
BytesFromFmt(FmtType type
);
63 ALuint
ChannelsFromFmt(FmtChannels chans
);
64 inline ALuint
FrameSizeFromFmt(FmtChannels chans
, FmtType type
)
65 { return ChannelsFromFmt(chans
) * BytesFromFmt(type
); }
69 al::vector
<al::byte
,16> mData
;
72 ALbitfieldSOFT Access
{0u};
75 FmtChannels mFmtChannels
{};
78 UserFmtType OriginalType
{};
79 ALuint OriginalSize
{0};
80 ALuint OriginalAlign
{0};
82 ALenum AmbiLayout
{AL_FUMA_SOFT
};
83 ALenum AmbiScaling
{AL_FUMA_SOFT
};
88 ALuint UnpackAlign
{0};
91 ALbitfieldSOFT MappedAccess
{0u};
92 ALsizei MappedOffset
{0};
93 ALsizei MappedSize
{0};
95 /* Number of times buffer was attached to a source (deletion can only occur when 0) */