Is StretchBlt HALFTONE == BILINEAR for all scaling?

后端 未结 2 898
别那么骄傲
别那么骄傲 2021-01-06 02:27

Can anyone clarify if the GDI StretchBlt function for the workstation Win32 API performs bilinear interpolation for scaling to both larger and smaller imag

2条回答
  •  爱一瞬间的悲伤
    2021-01-06 02:50

    HALFTONE mode performs a very blocky halftone dithering on the image, based on varying the conversion thresholds over a defined square. I have never seen a situation where it would be considered the best choice.

    COLORONCOLOR is the best mode for color images, but as you've seen it doesn't give great results.

    GDI does not support a bilinear mode (except in Windows Mobile CE as you discovered). The naive implementation of bilinear does not do very well when shrinking an image, as it simply tries to interpolate between two adjacent input pixels without trying to draw from a larger area.

提交回复
热议问题