mirror of
https://github.com/Mrs4s/go-cqhttp.git
synced 2025-05-05 11:33:48 +08:00
40 lines
693 B
Go
40 lines
693 B
Go
package base
|
|
|
|
import (
|
|
"io"
|
|
|
|
"github.com/pkg/errors"
|
|
)
|
|
|
|
// silk encode features
|
|
var (
|
|
EncodeSilk = encodeSilk // 编码 SilkV3 音频
|
|
ResampleSilk = resampleSilk // 将silk重新编码为 24000 bit rate
|
|
)
|
|
|
|
func encodeSilk(_ []byte, _ string) ([]byte, error) {
|
|
return nil, errors.New("not supported now")
|
|
}
|
|
|
|
func resampleSilk(data []byte) []byte {
|
|
return data
|
|
}
|
|
|
|
// Mime scan feature
|
|
var (
|
|
IsLawfulImage = nocheck // 检查图片MIME
|
|
IsLawfulAudio = nocheck // 检查音频MIME
|
|
)
|
|
|
|
func nocheck(_ io.ReadSeeker) (bool, string) {
|
|
return true, ""
|
|
}
|
|
|
|
// todo: enable all in v1.1.0
|
|
|
|
// onebot 12 feature
|
|
const (
|
|
AcceptOneBot12HTTPEndPoint = false
|
|
AcceptOneBot12Message = false
|
|
)
|