You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This demo is great for VIO.
I run this dome app and collect the VIO data but In this case, the tracking status does not Initialize every time and also getPose(); getting null every time.
And also checked c++ function for getting Pose, but it's fired -1 every time. Below are functions, we are using for the gets Pose, but it's not working.
Can you guide us on How we can Initialize the tracking points and get the Pose successfully?
JNIEXPORT jint JNICALL Java_org_example_viotester_AlgorithmWorker_getTrackingStatus(
JNIEnv *, jobject) {
auto algorithm = std::atomic_load(&algorithmPtr);
if (algorithm) return algorithm->trackingStatus();
return -1;
}
Here are logs :
2022-04-26 13:51:08.504 11144-12723/? E/pragnesh: focalLengthX 484.068 focalLengthY 483.6075 principalPointX 317.23218 principalPointY 241.6948
2022-04-26 13:51:08.505 11144-12723/? E/pragnesh: time 0.0 qx 0.0 qy 0.0 qz 0.0 qw 0.0 x 0.0 y 0.0 z 0.0
2022-04-26 13:51:08.505 11144-12723/? E/pragnesh: status -1
2022-04-26 13:51:08.537 11144-12723/? E/pragnesh: focalLengthX 484.068 focalLengthY 483.6075 principalPointX 317.23218 principalPointY 241.6948
2022-04-26 13:51:08.538 11144-12723/? E/pragnesh: time 0.0 qx 0.0 qy 0.0 qz 0.0 qw 0.0 x 0.0 y 0.0 z 0.0
2022-04-26 13:51:08.538 11144-12723/? E/pragnesh: status -1
2022-04-26 13:51:08.570 11144-12723/? E/pragnesh: focalLengthX 484.068 focalLengthY 483.6075 principalPointX 317.23218 principalPointY 241.6948
2022-04-26 13:51:08.570 11144-12723/? E/pragnesh: time 0.0 qx 0.0 qy 0.0 qz 0.0 qw 0.0 x 0.0 y 0.0 z 0.0
2022-04-26 13:51:08.570 11144-12723/? E/pragnesh: status -1
2022-04-26 13:51:08.587 11144-12723/? E/pragnesh: focalLengthX 484.068 focalLengthY 483.6075 principalPointX 317.23218 principalPointY 241.6948
2022-04-26 13:51:08.588 11144-12723/? E/pragnesh: time 0.0 qx 0.0 qy 0.0 qz 0.0 qw 0.0 x 0.0 y 0.0 z 0.0
2022-04-26 13:51:08.588 11144-12723/? E/pragnesh: status -1
The text was updated successfully, but these errors were encountered:
pragnesh1234
changed the title
Tracking not Initialize, Every time pos gets null every time with all flavor.
Tracking not Initialize, Every time Pose gets null every time with all flavor.
Apr 26, 2022
See #46 . This repository does provides a framework for testing custom VIO implementations, but does not include any such custom implementations by default
Hii, @pekkaran
This demo is great for VIO.
I run this dome app and collect the VIO data but In this case, the tracking status does not Initialize every time and also getPose(); getting null every time.
And also checked c++ function for getting Pose, but it's fired -1 every time. Below are functions, we are using for the gets Pose, but it's not working.
Can you guide us on How we can Initialize the tracking points and get the Pose successfully?
JNIEXPORT jdoubleArray JNICALL Java_org_example_viotester_AlgorithmWorker_getPose(
JNIEnv *env, jobject) {
auto algorithm = std::atomic_load(&algorithmPtr);
if (algorithm) {
recorder::Pose pose;
bool hasPose = algorithm->pose(pose);
// Pragnesh did updated this code
if (!hasPose) {
return NULL;
}
jdoubleArray result = env->NewDoubleArray(8);
jdouble buf[8];
buf[0] = pose.time;
buf[1] = pose.position.x;
buf[2] = pose.position.y;
buf[3] = pose.position.z;
buf[4] = pose.orientation.x;
buf[5] = pose.orientation.y;
buf[6] = pose.orientation.z;
buf[7] = pose.orientation.w;
env->SetDoubleArrayRegion(result, 0, 8, buf);
return result;
}
return NULL;
JNIEXPORT jint JNICALL Java_org_example_viotester_AlgorithmWorker_getTrackingStatus(
JNIEnv *, jobject) {
auto algorithm = std::atomic_load(&algorithmPtr);
if (algorithm) return algorithm->trackingStatus();
return -1;
}
Here are logs :
2022-04-26 13:51:08.504 11144-12723/? E/pragnesh: focalLengthX 484.068 focalLengthY 483.6075 principalPointX 317.23218 principalPointY 241.6948
2022-04-26 13:51:08.505 11144-12723/? E/pragnesh: time 0.0 qx 0.0 qy 0.0 qz 0.0 qw 0.0 x 0.0 y 0.0 z 0.0
2022-04-26 13:51:08.505 11144-12723/? E/pragnesh: status -1
2022-04-26 13:51:08.537 11144-12723/? E/pragnesh: focalLengthX 484.068 focalLengthY 483.6075 principalPointX 317.23218 principalPointY 241.6948
2022-04-26 13:51:08.538 11144-12723/? E/pragnesh: time 0.0 qx 0.0 qy 0.0 qz 0.0 qw 0.0 x 0.0 y 0.0 z 0.0
2022-04-26 13:51:08.538 11144-12723/? E/pragnesh: status -1
2022-04-26 13:51:08.570 11144-12723/? E/pragnesh: focalLengthX 484.068 focalLengthY 483.6075 principalPointX 317.23218 principalPointY 241.6948
2022-04-26 13:51:08.570 11144-12723/? E/pragnesh: time 0.0 qx 0.0 qy 0.0 qz 0.0 qw 0.0 x 0.0 y 0.0 z 0.0
2022-04-26 13:51:08.570 11144-12723/? E/pragnesh: status -1
2022-04-26 13:51:08.587 11144-12723/? E/pragnesh: focalLengthX 484.068 focalLengthY 483.6075 principalPointX 317.23218 principalPointY 241.6948
2022-04-26 13:51:08.588 11144-12723/? E/pragnesh: time 0.0 qx 0.0 qy 0.0 qz 0.0 qw 0.0 x 0.0 y 0.0 z 0.0
2022-04-26 13:51:08.588 11144-12723/? E/pragnesh: status -1
The text was updated successfully, but these errors were encountered: