mirror of
https://github.com/talgo-cloud/bimg.git
synced 2026-03-14 01:46:18 -07:00
Added progressive jpeg functionality.
This commit is contained in:
parent
b6bc20df55
commit
0019d370e9
5 changed files with 8 additions and 2 deletions
3
vips.go
3
vips.go
|
|
@ -35,6 +35,7 @@ type vipsSaveOptions struct {
|
|||
Quality int
|
||||
Compression int
|
||||
Type ImageType
|
||||
Interlace int
|
||||
}
|
||||
|
||||
type vipsWatermarkOptions struct {
|
||||
|
|
@ -235,7 +236,7 @@ func vipsSave(image *C.struct__VipsImage, o vipsSaveOptions) ([]byte, error) {
|
|||
break
|
||||
default:
|
||||
debug("Save JPEG options: Q: %s", o.Quality)
|
||||
err = C.vips_jpegsave_bridge(image, &ptr, &length, 1, C.int(o.Quality), 0)
|
||||
err = C.vips_jpegsave_bridge(image, &ptr, &length, 1, C.int(o.Quality), C.int(o.Interlace))
|
||||
break
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue