mirror of
https://github.com/navidrome/navidrome.git
synced 2026-08-31 07:30:32 +00:00
style(artwork): tighten processor comments to budget
This commit is contained in:
parent
e0655dc882
commit
d6fc829f84
@ -28,7 +28,7 @@ const (
|
|||||||
outcomeFailed
|
outcomeFailed
|
||||||
)
|
)
|
||||||
|
|
||||||
// thumbnailSize is the max dimension fed to blurhash, matching Jellyfin's own input cap.
|
// thumbnailSize is the max dimension fed to blurhash.
|
||||||
const thumbnailSize = 128
|
const thumbnailSize = 128
|
||||||
|
|
||||||
// workerDeps are the collaborators processItem needs; extGate is nil outside
|
// workerDeps are the collaborators processItem needs; extGate is nil outside
|
||||||
@ -155,9 +155,8 @@ func decodeArtwork(ctx context.Context, hash string, data []byte) (*model.Artwor
|
|||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// makeThumbnail downscales img to fit within maxSize on its longest side,
|
// makeThumbnail downscales img to fit within maxSize on its longest side.
|
||||||
// reusing reader_resized.go's fast-scale-type + CatmullRom approach. Images
|
// Images within bounds are returned as-is (no upscaling).
|
||||||
// already within bounds are returned as-is (no upscaling).
|
|
||||||
func makeThumbnail(img image.Image, maxSize int) image.Image {
|
func makeThumbnail(img image.Image, maxSize int) image.Image {
|
||||||
b := img.Bounds()
|
b := img.Bounds()
|
||||||
w, h := b.Dx(), b.Dy()
|
w, h := b.Dx(), b.Dy()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user