Skip to content

Quantization example code #2265

Discussion options

You must be logged in to vote

Sure...

string inPath = "...";
string outPath = "...";
using Image image = Image.Load(inPath);
image.Save(outPath, new PngEncoder() { ColorType = PngColorType.Palette, BitDepth = PngBitDepth.Bit8 });

There are overloads for Load/Save that take streams also.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@simonmurrell1979
Comment options

@JimBobSquarePants
Comment options

@simonmurrell1979
Comment options

Answer selected by JimBobSquarePants
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants