wwise

package
v0.3.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 6, 2024 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Overview

The following is mostly manually converted from vgmstream (https://github.com/vgmstream/vgmstream)

The following is mostly manually converted from vgmstream (https://github.com/vgmstream/vgmstream)

Index

Constants

View Source
const (
	MappingMono            = ChannelLayout(SpeakerFC)
	MappingStereo          = ChannelLayout(SpeakerFL | SpeakerFR)
	Mapping2Point1         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerLFE)
	Mapping3Point0         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC)
	Mapping3Point0Back     = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerBC)
	Mapping4Point0         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerBC)
	MappingQuad            = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerBL | SpeakerBR)
	MappingQuadSide        = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerSL | SpeakerSR)
	Mapping3Point1         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE)
	Mapping5Point0         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerBL | SpeakerBR)
	Mapping5Point0Side     = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerSL | SpeakerSR)
	Mapping4Point1         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerBC)
	Mapping5Point1         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerBL | SpeakerBR)
	Mapping5Point1Side     = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerSL | SpeakerSR)
	Mapping6Point0         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerBC | SpeakerSL | SpeakerSR)
	Mapping6Point0Front    = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFLC | SpeakerFRC | SpeakerSL | SpeakerSR)
	MappingHexagonal       = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerBL | SpeakerBR | SpeakerBC)
	Mapping6Point1         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerBC | SpeakerSL | SpeakerSR)
	Mapping6Point1Back     = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerBL | SpeakerBR | SpeakerBC)
	Mapping6Point1Front    = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerLFE | SpeakerFLC | SpeakerFRC | SpeakerSL | SpeakerSR)
	Mapping7Point0         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerBL | SpeakerBR | SpeakerSL | SpeakerSR)
	Mapping7Point0Front    = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerFLC | SpeakerFRC | SpeakerSL | SpeakerSR)
	Mapping7Point1         = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerBL | SpeakerBR | SpeakerSL | SpeakerSR)
	Mapping7Point1Wide     = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerBL | SpeakerBR | SpeakerFLC | SpeakerFRC)
	Mapping7Point1WideSide = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerFLC | SpeakerFRC | SpeakerSL | SpeakerSR)
	Mapping7Point1Top      = ChannelLayout(SpeakerFL | SpeakerFR | SpeakerFC | SpeakerLFE | SpeakerBL | SpeakerBR | SpeakerTFL | SpeakerTFR)
)

Variables

This section is empty.

Functions

This section is empty.

Types

type BkhdXorKey

type BkhdXorKey struct {
	Version uint32
	ID      uint32
}

type Bnk

type Bnk struct {
	// contains filtered or unexported fields
}

func OpenBnk

func OpenBnk(r io.ReadSeeker, bkhdKey *BkhdXorKey) (*Bnk, error)

bkhdKey is an optional XOR key to decode bnk version and ID, if required

func (*Bnk) FileID

func (b *Bnk) FileID(idx int) uint32

func (*Bnk) NumFiles

func (b *Bnk) NumFiles() int

func (*Bnk) OpenFile

func (b *Bnk) OpenFile(idx int) (io.ReadSeeker, error)

Only one file should be read at the same time.

type ChannelLayout added in v0.1.4

type ChannelLayout uint32

func (ChannelLayout) HasName added in v0.1.8

func (cl ChannelLayout) HasName() bool

Returns true if the channel layout can be described by a simple name like "7.1" or "stereo". The string can be obtained by calling String().

func (ChannelLayout) String added in v0.1.4

func (cl ChannelLayout) String() string

Returns channel layout name, or, if nonstandard, list of speakers separated by "|".

type SpeakerFlag added in v0.1.4

type SpeakerFlag uint32
const (
	SpeakerFL  SpeakerFlag = 1 << iota // front left
	SpeakerFR                          // front right
	SpeakerFC                          // front center
	SpeakerLFE                         // low frequency effects
	SpeakerBL                          // back left
	SpeakerBR                          // back right
	SpeakerFLC                         // front left center
	SpeakerFRC                         // front right center
	SpeakerBC                          // back center
	SpeakerSL                          // side left
	SpeakerSR                          // side right
	SpeakerTC                          // top center
	SpeakerTFL                         // top front left
	SpeakerTFC                         // top front center
	SpeakerTFR                         // top front right
	SpeakerTBL                         // top back left
	SpeakerTBC                         // top back center
	SpeakerTBR                         // top back left
)

WAVEFORMATEXTENSIBLE speaker positions

func (SpeakerFlag) String added in v0.1.8

func (sp SpeakerFlag) String() string

Returns ffmpeg-compatible string for a single speaker flag (e.g. "FL").

type Wem

type Wem struct {
	// contains filtered or unexported fields
}

func OpenWem

func OpenWem(r io.ReadSeeker) (*Wem, error)

func (*Wem) BufferSize

func (w *Wem) BufferSize() int

Maximum amount of samples that can be decoded from a single packet.

func (*Wem) ChannelLayout added in v0.1.4

func (w *Wem) ChannelLayout() ChannelLayout

func (*Wem) Channels

func (w *Wem) Channels() int

func (*Wem) Decode

func (w *Wem) Decode() ([]float32, error)

Decodes the next packet. Returned slice is only valid until next call of Decode.

func (*Wem) SampleRate

func (w *Wem) SampleRate() int

Directories

Path Synopsis
The following is manually converted from ww2ogg by hcs (https://github.com/hcs64/ww2ogg)
The following is manually converted from ww2ogg by hcs (https://github.com/hcs64/ww2ogg)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL