The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: Jimg on April 29, 2009, 05:07:08 PM

Title: gdi plus smoothingmode antialias
Post by: Jimg on April 29, 2009, 05:07:08 PM
Anyone know the value for gdi plus smoothingmode antialias for calling GdipSetSmoothingMode?

And if so, where did you find it?
Title: Re: gdi plus smoothingmode antialias
Post by: MichaelW on April 29, 2009, 05:41:45 PM
The value is available  here (http://com.it-berater.org/gdiplus/GdiPlus.htm) under Enumerations, or from the SDK GdiPlusEnums.h as:

//--------------------------------------------------------------------------
// Quality mode constants
//--------------------------------------------------------------------------

enum QualityMode
{
    QualityModeInvalid   = -1,
    QualityModeDefault   = 0,
    QualityModeLow       = 1, // Best performance
    QualityModeHigh      = 2  // Best rendering quality
};

. . .

//---------------------------------------------------------------------------
// Smoothing Mode
//---------------------------------------------------------------------------

enum SmoothingMode
{
    SmoothingModeInvalid     = QualityModeInvalid,
    SmoothingModeDefault     = QualityModeDefault,
    SmoothingModeHighSpeed   = QualityModeLow,
    SmoothingModeHighQuality = QualityModeHigh,
    SmoothingModeNone,
    SmoothingModeAntiAlias
};

Title: Re: gdi plus smoothingmode antialias
Post by: Jimg on April 29, 2009, 05:56:03 PM
Thank you Michael.  I had to go figure out what enum meant, but it's all good.

It's a good thing it was explicitly shown as 4 at the place you posted the link to, because I would have guessed from the enum code it would have been 6.  I guess I'll never be comfortable with c systax.