add cachekey
This commit is contained in:
parent
83663aa9db
commit
e668777431
1
tgs.go
1
tgs.go
|
|
@ -13,6 +13,7 @@ type TGSTransformOptions struct {
|
|||
Qualtity int
|
||||
ResizeWidth int
|
||||
ResizeHeight int
|
||||
CacheKey string
|
||||
}
|
||||
|
||||
type TGSConverter interface {
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@ func (t tgsConverterImpl) Transform(ctx context.Context, in io.Reader, out io.Wr
|
|||
return err
|
||||
}
|
||||
|
||||
anim := rlottie.LottieAnimationFromData(buf.String(), "", "")
|
||||
anim := rlottie.LottieAnimationFromData(buf.String(), opts.CacheKey, "")
|
||||
defer rlottie.LottieAnimationDestroy(anim)
|
||||
|
||||
width, height := rlottie.LottieAnimationGetSize(anim)
|
||||
|
|
|
|||
Loading…
Reference in New Issue