GDI+ How to disable smoothing effect?

  • Thread starter Thread starter Austin Jan
  • Start date Start date
A

Austin Jan

Hello,

When I use Graphics.DrawImage() draw specified image to bigger size, I found
that the output image's edge smoothing, In other words output image's edge
have different color.

Can I disable it effect? I just want to get same color and different size
image.

Thanks,

Austin
 
Put this in your OnPaint method:
Graphics.InterpolationMode = InterpolationMode.NearestNeighbor;

I can recommend the 'microsoft.public.dotnet.framework.drawing' group for
graphics related questions. Mr. Powell will immideately respond any question
with an exact answer.

regards, Teis
 
Back
Top