We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I was trying around with this branch #15 and found out that there is a failing test using libjpeg whereas it is passing with libjpeg-turbo.
$ CGO_CFLAGS=-I/usr/local/opt/jpeg/include CGO_LDFLAGS=-L/usr/local/opt/jpeg/lib go test -a -test.v . === RUN TestDecode - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecode (1.70s) === RUN TestDecodeScaled - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecodeScaled (0.12s) === RUN TestDecodeIntoRGBA --- SKIP: TestDecodeIntoRGBA (0.00s) jpeg_test.go:109: This build is not support DecodeIntoRGBA. === RUN TestDecodeScaledIntoRGBA --- SKIP: TestDecodeScaledIntoRGBA (0.00s) jpeg_test.go:128: This build is not support DecodeIntoRGBA. === RUN TestDecodeScaledIntoRGB - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecodeScaledIntoRGB (0.12s) === RUN TestDecodeSubsampledImage - test: checkerboard_444.jpg - test: checkerboard_440.jpg - test: checkerboard_422.jpg - test: checkerboard_420.jpg --- PASS: TestDecodeSubsampledImage (0.07s) === RUN TestDecodeAndEncode - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecodeAndEncode (0.07s) === RUN TestDecodeAndEncodeSubsampledImages - test: checkerboard_444.jpg - test: checkerboard_440.jpg - test: checkerboard_422.jpg - test: checkerboard_420.jpg --- PASS: TestDecodeAndEncodeSubsampledImages (0.01s) === RUN TestDecodeConfig - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecodeConfig (0.00s) === RUN TestNewYCbCrAlignedWithLandscape --- PASS: TestNewYCbCrAlignedWithLandscape (0.00s) === RUN TestNewYCbCrAlignedWithPortrait --- PASS: TestNewYCbCrAlignedWithPortrait (0.00s) === RUN TestDecodeTestdataFromGoStdlib --- FAIL: TestDecodeTestdataFromGoStdlib (0.11s) testdata_test.go:110: testdata/video-001.221212.jpeg: at (93, 0): got {96 11 0 255} want {34 106 166} FAIL exit status 1 FAIL github.com/pixiv/go-libjpeg/jpeg 2.209s
$ CGO_CFLAGS=-I/usr/local/opt/jpeg-turbo/include CGO_LDFLAGS=-L/usr/local/opt/jpeg-turbo/lib go test -a -test.v . === RUN TestDecode - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecode (1.69s) === RUN TestDecodeScaled - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecodeScaled (0.11s) === RUN TestDecodeIntoRGBA --- SKIP: TestDecodeIntoRGBA (0.00s) jpeg_test.go:109: This build is not support DecodeIntoRGBA. === RUN TestDecodeScaledIntoRGBA --- SKIP: TestDecodeScaledIntoRGBA (0.00s) jpeg_test.go:128: This build is not support DecodeIntoRGBA. === RUN TestDecodeScaledIntoRGB - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecodeScaledIntoRGB (0.13s) === RUN TestDecodeSubsampledImage - test: checkerboard_444.jpg - test: checkerboard_440.jpg - test: checkerboard_422.jpg - test: checkerboard_420.jpg --- PASS: TestDecodeSubsampledImage (0.06s) === RUN TestDecodeAndEncode - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecodeAndEncode (0.03s) === RUN TestDecodeAndEncodeSubsampledImages - test: checkerboard_444.jpg - test: checkerboard_440.jpg - test: checkerboard_422.jpg - test: checkerboard_420.jpg --- PASS: TestDecodeAndEncodeSubsampledImages (0.01s) === RUN TestDecodeConfig - test: cosmos.jpg - test: kinkaku.jpg --- PASS: TestDecodeConfig (0.00s) === RUN TestNewYCbCrAlignedWithLandscape --- PASS: TestNewYCbCrAlignedWithLandscape (0.00s) === RUN TestNewYCbCrAlignedWithPortrait --- PASS: TestNewYCbCrAlignedWithPortrait (0.00s) === RUN TestDecodeTestdataFromGoStdlib --- PASS: TestDecodeTestdataFromGoStdlib (0.11s) PASS ok github.com/pixiv/go-libjpeg/jpeg 2.149s
libjpeg version 8g and libjpeg-turbo 1.4.1 installed with homebrew.
The text was updated successfully, but these errors were encountered:
It turned out that the lowest tolerance values for libjpeg-turbo are;
var imageTests = []imageTest{ {"testdata/video-001.221212.png", "testdata/video-001.221212.jpeg", 8 << 6}, // {"testdata/video-001.cmyk.png", "testdata/video-001.cmyk.jpeg", 8 << 8}, {"testdata/video-001.png", "testdata/video-001.jpeg", 8 << 8}, {"testdata/video-001.png", "testdata/video-001.progressive.jpeg", 8 << 8}, {"testdata/video-001.png", "testdata/video-001.rgb.jpeg", 8 << 13}, {"testdata/video-005.gray.png", "testdata/video-005.gray.jpeg", 8 << 8}, }
On the other hand, those for libjpeg are;
var imageTests = []imageTest{ {"testdata/video-001.221212.png", "testdata/video-001.221212.jpeg", 8 << 11}, // {"testdata/video-001.cmyk.png", "testdata/video-001.cmyk.jpeg", 8 << 8}, {"testdata/video-001.png", "testdata/video-001.jpeg", 8 << 8}, {"testdata/video-001.png", "testdata/video-001.progressive.jpeg", 8 << 8}, {"testdata/video-001.png", "testdata/video-001.rgb.jpeg", 8 << 13}, {"testdata/video-005.gray.png", "testdata/video-005.gray.jpeg", 8 << 8}, }
Sorry, something went wrong.
We should probably stop comparing dot by dot.
No branches or pull requests
I was trying around with this branch #15 and found out that there is a failing test using libjpeg whereas it is passing with libjpeg-turbo.
libjpeg version 8g and libjpeg-turbo 1.4.1 installed with homebrew.
The text was updated successfully, but these errors were encountered: