How to reduce the size of an image in C# and .NET 3.5?

后端 未结 7 1506
忘掉有多难
忘掉有多难 2020-12-05 16:10

I have a screen shot I take in my mobile app. The screen shot takes about 32 KB when saved as a png on a disk.

I am sending these to a central SQL Server and 32 KB

相关标签:
7条回答
  • 2020-12-05 17:03

    If color depth is not an issue, you might change it to black and white, or 16 color mode. There should be a significant savings over png's 24-bpp (or 32-bpp with alpha) storage requirements. The other thing to think about is saving it as a .gif file in 256 color mode.

    As you're saving signature data, I'd think changing the dimensions of the image would be a bad idea. You might also consider applying a lossless compression like zip, but that is likely more computationally intensive than you require.

    0 讨论(0)
提交回复
热议问题