VibranceLayer.Vibrance

VibranceLayer.Vibrance property

Gets or sets the vibrance.

public int Vibrance { get; set; }

Property Value

The vibrance.

Exceptions

exceptioncondition
ArgumentOutOfRangeExceptionVibrance must be in range from -180 to +180

Examples

The following code example demonstrates support of the VibranceLayer layer and the ability to edit this adjustment.

[C#]

string sourceFileName = "WithoutVibrance.psd";
string outputFileNamePsd = "out_VibranceLayer.psd";
string outputFileNamePng = "out_VibranceLayer.png";

using (PsdImage image = (PsdImage) Image.Load(sourceFileName))
{
    // Creating a new VibranceLayer
    VibranceLayer vibranceLayer = image.AddVibranceAdjustmentLayer();
    vibranceLayer.Vibrance = 50;
    vibranceLayer.Saturation = 100;

    image.Save(outputFileNamePsd);
    image.Save(outputFileNamePng, new PngOptions());
}

See Also