Files
tamabox/dev/webpstub/webp.go
T
2026-09-08 10:10:44 +08:00

21 lines
626 B
Go
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
// webpstub(package webp)是 chai2010/webp 的本地编译桩:仅用于在缺少 libwebp 的
// Windows 沙箱中通过 `go build -overlay` 对依赖 internal/storage 的包做完整
// 类型检查。API 只覆盖项目实际用到的 Encode/Options。
package webp
import (
"image"
"io"
)
// Options 与 github.com/chai2010/webp 的 Options 字段保持兼容(项目仅用 Quality)。
type Options struct {
Lossless bool
Quality float32
}
// Encode 是 webp.Encode 的签名兼容桩(类型检查期间不会被真正调用)。
func Encode(w io.Writer, m image.Image, o *Options) error {
return nil
}