Recover camera session failures once with low-resolution native YUV
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
package com.google.mediapipe.tasks.vision.facelandmarker
|
||||
class Landmark {fun x()=.5f;fun y()=.5f}
|
||||
class Category {fun categoryName()="none";fun score()=0f}
|
||||
class Result {
|
||||
fun faceLandmarks(): List<List<Landmark>> = emptyList()
|
||||
fun faceBlendshapes(): java.util.Optional<List<List<Category>>> = java.util.Optional.empty()
|
||||
fun facialTransformationMatrixes(): java.util.Optional<List<FloatArray>> = java.util.Optional.empty()
|
||||
}
|
||||
class FaceLandmarker {
|
||||
fun detectForVideo(image: com.google.mediapipe.framework.image.MPImage,now: Long)=Result()
|
||||
fun close() {}
|
||||
class FaceLandmarkerOptions {
|
||||
companion object {fun builder()=Builder()}
|
||||
class Builder {
|
||||
fun setBaseOptions(b: com.google.mediapipe.tasks.core.BaseOptions)=this
|
||||
fun setRunningMode(r: com.google.mediapipe.tasks.vision.core.RunningMode)=this
|
||||
fun setNumFaces(n: Int)=this
|
||||
fun setMinFaceDetectionConfidence(f: Float)=this
|
||||
fun setMinFacePresenceConfidence(f: Float)=this
|
||||
fun setMinTrackingConfidence(f: Float)=this
|
||||
fun setOutputFaceBlendshapes(b: Boolean)=this
|
||||
fun setOutputFacialTransformationMatrixes(b: Boolean)=this
|
||||
fun build()=FaceLandmarkerOptions()
|
||||
}
|
||||
}
|
||||
companion object {fun createFromOptions(c: android.content.Context,o: FaceLandmarkerOptions)=FaceLandmarker()}
|
||||
}
|
||||
Reference in New Issue
Block a user