This is the readme for the CMS 12 version, the version for CMS 11 is over here.
This addon will use Azure Cognitive Services Face API to detect faces, and place a black rectangle over the eye region of all detected faces, in images uploaded in Optimizely CMS (formerly Episerver CMS).
- Create an Azure Cognitive Services, Face API-resource using the Azure portal.
- Add the following keys to appsettings.json. Get the values from the Azure portal.
"Gulla": {
"EpiserverCensorFaces": {
"CognitiveServices": {
"SubscriptionKey": "my-subscription-key",
"Endpoint": "https://my-service.cognitiveservices.azure.com/"
}
}
}
- Add the following to
Configure
inStartup.cs
and add IContentEvents as an input paramter if not already present
public void Configure(IApplicationBuilder app, IContentEvents contentEvents)
{
app.UseCensorFaces(contentEvents);
}
Check out this blog post or this blog post.
Install the NuGet package Gulla.Episerver.CensorFaces. You need to check «Include prerelease» in Visual Studio, or your packet manager.