audio

package
v1.0.29 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2020 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Wav

type Wav struct {
	// 语音数据大小
	DataSize uint
	// 声道数
	Channels uint8
	// 采样频率
	Rate uint
	// 采样位数
	Precision uint16
}

func OpenWav

func OpenWav(file string) (*Wav, error)

[82 73 70 70 122 107 1 0 87 65 86 69 102 109 116 32 18 0 0 0 6 0 1 0 64 31 0 0 64 31 0 0 1 0 8 0 0 0 102 97 99 116 4 0 0 0 72 107 1 0 100 97 116 97 72 107 1 0]

func (*Wav) Duration

func (w *Wav) Duration() uint

计算时长 93000 * 8 / (8000 * 8 * 1)

Jump to

Keyboard shortcuts

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