Documentation ¶
Index ¶
- Constants
- Variables
- func GetEncoderName() string
- func IsCommandAvailable(name string) bool
- type Converter
- func (c *Converter) Convert(src interface{}) error
- func (c *Converter) DstFormat() string
- func (c *Converter) WithBitRate(rate int) *Converter
- func (c *Converter) WithChannels(v int) *Converter
- func (c *Converter) WithCodec(codec string) *Converter
- func (c *Converter) WithCover(coverPath string) *Converter
- func (c *Converter) WithDstFormat(f string) *Converter
- func (c *Converter) WithID3TagVersion(v int) *Converter
- func (c *Converter) WithParams(p ...string) *Converter
- func (c *Converter) WithSampleRate(rate int) *Converter
- func (c *Converter) WithTags(tags map[string]string) *Converter
- func (c *Converter) WithWriter(w io.Writer) *Converter
- type EncodeError
- type InvalidCoverError
- type InvalidID3TagVersionError
Constants ¶
View Source
const ( MP3BitRateEconomy = 64 * 1000 MP3BitRateStandard = 128 * 1000 MP3BitRateGood = 192 * 1000 MP3BitRatePerfect = 320 * 1000 M4ABitRateEconomy = 64 * 1000 M4ABitRateStandard = 128 * 1000 M4ABitRateGood = 160 * 1000 M4ABitRatePerfect = 256 * 1000 )
View Source
const (
FFMPEGEncoder = "ffmpeg"
)
Variables ¶
Functions ¶
func GetEncoderName ¶
func GetEncoderName() string
func IsCommandAvailable ¶
Types ¶
type Converter ¶
type Converter struct {
// contains filtered or unexported fields
}
func NewConverter ¶
func (*Converter) WithBitRate ¶
func (*Converter) WithChannels ¶
func (*Converter) WithDstFormat ¶
func (*Converter) WithID3TagVersion ¶
func (*Converter) WithParams ¶
func (*Converter) WithSampleRate ¶
type EncodeError ¶
type EncodeError string
func (EncodeError) Error ¶
func (e EncodeError) Error() string
type InvalidCoverError ¶
type InvalidCoverError string
func (InvalidCoverError) Error ¶
func (e InvalidCoverError) Error() string
type InvalidID3TagVersionError ¶
type InvalidID3TagVersionError string
func (InvalidID3TagVersionError) Error ¶
func (e InvalidID3TagVersionError) Error() string
Click to show internal directories.
Click to hide internal directories.