fixed error due to index out of bounds while logging keypoint

This commit is contained in:
Mautisim Munir 2022-10-12 12:19:52 +05:00
parent a0b7a5318e
commit 7a628e468e

View File

@ -346,7 +346,7 @@ public class MainActivity extends AppCompatActivity {
private void logExampleKeypoint( private void logExampleKeypoint(
PoseTrackingResult result, int faceIndex, boolean showPixelValues) { PoseTrackingResult result, int faceIndex, boolean showPixelValues) {
if (result.multiPoseTrackings().isEmpty()) { if (result.multiPoseLandmarks().isEmpty()) {
return; return;
} }
LandmarkProto.Landmark exampleLandmark = result.multiPoseLandmarks().get(0); LandmarkProto.Landmark exampleLandmark = result.multiPoseLandmarks().get(0);