Face detection
Purpose
Demonstrate enabling face mode on the online recognition pipeline, consuming quality-ranked FaceModels, and extracting optimised crops for downstream usage.
Entry points
Glass home:
HomeActivity→GlassFaceTrackActivity
Sample Activity:
com.rokid.glass.GlassFaceTrackActivity
Platform
- Glass
Main file
Flow
- Grab
GlassSdk.getGlassOnlineRecService(). - Attach
IGlassDetectionListener. startDetection(MODE_FACE).- Consume
onProcessedFaceModels()to pick the best samples. - Filter noisy tracks via quality +
trackId. - Snapshot crops through
getFaceSamllBitmap(trackId)and render.
FAQ
What “best face” means here
Heuristic blend of bounding-box area, iqaScore, faceScore, deduped per trackId; samples under iqaScore < 40 drop out.
Detection vs recognition
This path emphasises detection + crop quality scoring—no ID compare is performed in UI.
Caveats
- Always call stop + detach on exit.
- Persistence hooks exist but stay commented—focus is pipeline validation, not archival UX.