Hello Everyone,
As I have mentioned my app shows a line between two lips for the application of virtual lipstick color change. Following is my code used for lip color
let faceGeometry = ARSCNFaceGeometry(device: device)
let faceNode = SCNNode(geometry: faceGeometry) faceNode.geometry?.firstMaterial?.transparency = 0 guard let faceAnchor = anchor as? ARFaceAnchor else { return nil } faceAnchors.insert(faceAnchor)
let material = faceGeometry?.firstMaterial!
// Shape of lips material?.diffuse.contents = imageLiteral(resourceName: "lipShape_old")
// Lipstick color material?.normal.contents = lipstickColor material?.multiply.contents = lipstickColor
// More realistic material?.lightingModel = .physicallyBased material?.transparency = 0.82
masks.insert(faceNode)
return faceNode
Please check that. Any help will be appreciated. Thanks