API Credentials
Analysis Workflow
Upload Skin Image
Requirements: JPG/PNG, up to 4096px on long side, at least 480px (SD) or 1080px (HD) on short side
Processing…
Analysis Results
Detection Masks
Requirements: JPG/PNG, up to 4096px on long side, at least 480px (SD) or 1080px (HD) on short side
Processing…
let sdkLoaded=false;
/* Perfect Corp Camera Kit SDK callback */
window.YMKAsyncInit=function(){
sdkLoaded=true;
document.getElementById("status").innerHTML = "AI Beauty Studio Ready";
if(typeof YMK.addEventListener==="function"){
YMK.addEventListener( "loaded", function(){
document.getElementById("status").innerHTML = "Camera Kit Loaded";
}
);
}
};
/* Load SDK */
(function(){
if(document.getElementById("ymk-sdk")){ return; }
let script=document.createElement("script");
script.id="ymk-sdk";
script.src= "https://plugins-media.makeupar.com/v2.5-camera-kit/sdk.js";
script.async=true;
document.body.appendChild(script);
})();
function initYMK(mode){
if(!sdkLoaded || typeof YMK==="undefined"){
document.getElementById("status").innerHTML = "SDK not ready";
return false;
}
if(typeof YMK.init==="function"){
YMK.init({
container:"#YMK-module",
faceDetectionMode:mode
});
}
return true;
}
function openMakeup(){
if(!initYMK("makeup")) return;
document.getElementById("status").innerHTML = "Opening Makeup...";
if(typeof YMK.openCameraKit==="function"){
YMK.openCameraKit();
}
}
function openSkin(){
if(!initYMK("skin")) return;
document.getElementById("status").innerHTML = "Opening Skin Analysis...";
if(typeof YMK.openCameraKit==="function"){
YMK.openCameraKit();
}
}
function openCamera(){
if(!initYMK("makeup")) return;
document.getElementById("status").innerHTML = "Opening Camera...";
if(typeof YMK.openCameraKit==="function"){
YMK.openCameraKit();
}
}
function openUpload(){
if(!initYMK("makeup")) return;
document.getElementById("status").innerHTML = "Opening Upload...";
if(typeof YMK.openPhoto==="function"){
YMK.openPhoto();
}
else if(typeof YMK.openCameraKit==="function"){
YMK.openCameraKit();
}
}
Requirements: JPG/PNG, up to 4096px on long side, at least 480px (SD) or 1080px (HD) on short side
Processing...
let sdkLoaded=false;
/* Perfect Corp Camera Kit SDK callback */
window.YMKAsyncInit=function(){
sdkLoaded=true;
document.getElementById("status").innerHTML = "AI Beauty Studio Ready";
if(typeof YMK.addEventListener==="function"){
YMK.addEventListener( "loaded", function(){
document.getElementById("status").innerHTML = "Camera Kit Loaded";
}
);
}
};
/* Load SDK */
(function(){
if(document.getElementById("ymk-sdk")){ return; }
let script=document.createElement("script");
script.id="ymk-sdk";
script.src= "https://plugins-media.makeupar.com/v2.5-camera-kit/sdk.js";
script.async=true;
document.body.appendChild(script);
})();
function initYMK(mode){
if(!sdkLoaded || typeof YMK==="undefined"){
document.getElementById("status").innerHTML = "SDK not ready";
return false;
}
if(typeof YMK.init==="function"){
YMK.init({
container:"#YMK-module",
faceDetectionMode:mode
});
}
return true;
}
function openMakeup(){
if(!initYMK("makeup")) return;
document.getElementById("status").innerHTML = "Opening Makeup...";
if(typeof YMK.openCameraKit==="function"){
YMK.openCameraKit();
}
}
function openSkin(){
if(!initYMK("skin")) return;
document.getElementById("status").innerHTML = "Opening Skin Analysis...";
if(typeof YMK.openCameraKit==="function"){
YMK.openCameraKit();
}
}
function openCamera(){
if(!initYMK("makeup")) return;
document.getElementById("status").innerHTML = "Opening Camera...";
if(typeof YMK.openCameraKit==="function"){
YMK.openCameraKit();
}
}
function openUpload(){
if(!initYMK("makeup")) return;
document.getElementById("status").innerHTML = "Opening Upload...";
if(typeof YMK.openPhoto==="function"){
YMK.openPhoto();
}
else if(typeof YMK.openCameraKit==="function"){
YMK.openCameraKit();
}
}
⁹