Open FilX opened 4 years ago
Hi, I am aware of this problem. This is a mirror repository, could you open an issue in my main repository in GitLab (with CI CD and stuffs) Thanks!
It was resolved here: https://github.com/kornelski/pngquant/issues/348#issuecomment-554283563
Image which has less than 4000 bytes is not possible compress by PngQuant from c#. But when it's called pngquant.exe in console directly it works. I think there is problem in PngQuant.CompressImplementation in await pro.StandardOutput.BaseStream.CopyToAsync(outputStream); line
Code example
var pngQuant = new PngQuant(); var image = File.ReadAllBytes(@"C:\\Temp\\Images\\testx.png"); var compressed = pngQuant.Compress(image).GetAwaiter().GetResult();