utils

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: May 1, 2023 License: MIT Imports: 22 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertTo2DArray added in v1.2.0

func ConvertTo2DArray(arr []byte, rows int) [][]byte

func DecodeVideo added in v1.2.0

func DecodeVideo(inputFile string, outputFile string, a int, b int, width int, height int, length int, rows int, hashSha256 *string) error

DecodeVideo 反向函数实现:将视频转换回原始文件

func DecodeVideoByBase64 added in v1.2.0

func DecodeVideoByBase64(encodeFile string, decodeFile string, base64Str string) error

DecodeVideoByBase64 通过 base64 字符串解码视频

func Degarble added in v1.2.0

func Degarble(laby string, source string, output string)

func EncodeVideo added in v1.2.0

func EncodeVideo(inputFile string, outputFile string, width int, height int, a int, b int) (err error, base64Str string)

func Garble added in v1.2.0

func Garble(laby, source, output string)

func Generate

func Generate(width int, height int, mode string, name string)

func GenerateRandomImage

func GenerateRandomImage(lst [][]int, origin, output string) bool

func GenerateRandomLaby

func GenerateRandomLaby(width int, height int, mode string) [][]int

func GenerateRandomName added in v1.2.0

func GenerateRandomName(length int) string

GenerateRandomName 生成随机名称函数

func GetNextMultiple added in v1.2.0

func GetNextMultiple(length int) int

func LabyFileToList

func LabyFileToList(name string) [][]int

func LabyToFile

func LabyToFile(s string, name string) bool

func LabyToStr

func LabyToStr(arr [][]int) string

func LogError

func LogError(s string)

func LogInfo

func LogInfo(s string)

func LogPanic

func LogPanic(s string)

func LogWarn

func LogWarn(s string)

func RestoreOriginalImage

func RestoreOriginalImage(lst [][]int, origin, restore string) bool

func RunCommand

func RunCommand(command string, args []string) error

func VideoDegarble added in v1.2.0

func VideoDegarble(laby string, source string, framerate int, routines int)

func VideoGarble added in v1.2.0

func VideoGarble(laby, source string, framerate int, routines int)

func VideoGarble1 added in v1.2.0

func VideoGarble1(laby, source string, framerate int, routines int)

Types

This section is empty.

Jump to

Keyboard shortcuts

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