Quantcast
Channel: magick Discussions Rss Feed
Viewing all articles
Browse latest Browse all 3693

New Post: ToBase64 is always different for same image

$
0
0
I am converting a PDF to image and sending back to client Base 64 encoding string

using (MagickImage pdfConvertedImage = images[index])
                    {
                        // ReSharper restore AccessToDisposedClosure
                        //// set the format of the image
                        pdfConvertedImage.Format = MagickFormat.Png;
                        pdfConvertedImage.Resize(new MagickGeometry(width, height));                    

                        var keyValuePair = new KeyValuePair<string, string>(
                                    string.Format(imageFolderPath + FilePng, index),
                                    pdfConvertedImage.ToBase64());

                        imageCollection.Add(keyValuePair);
}

But, the Base64 string is always different for the Image. For the same resolution, I should expect the image to be exact, ie the base 64 encoded string , should match, but its not happening.

Can you please help me.

I am using
<package id="Magick.NET-Q8-x64" version="7.0.0.0009" targetFramework="net451" />

Viewing all articles
Browse latest Browse all 3693

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>