Commit 108f4b24 authored by Vadim Pisarevsky's avatar Vadim Pisarevsky

write camera pose, handle partially occluded objects

parent ed64c560
......@@ -401,8 +401,10 @@ int main(int argc, char** argv)
fclose(f);
}
imwrite(path, selectedObjFrame(r));
fprintf(fframes, "%s%04d.jpg", outbarename, frameIdx);
imwrite(path, selectedObjFrame(r&Rect(0,0,selectedObjFrame.cols,selectedObjFrame.rows)));
fprintf(fframes, "%s%04d.jpg (%.4f %.4f %.4f) (%.4f %.4f %.4f)", outbarename, frameIdx,
rvec.at<double>(0,0), rvec.at<double>(1,0), rvec.at<double>(2,0),
tvec.at<double>(0,0), tvec.at<double>(1,0), tvec.at<double>(2,0));
for( int i = 0; i < 8; i++ )
fprintf(fframes, " (%.2f %.2f %.2f)", objpts[i].x, objpts[i].y, objpts[i].z);
fprintf(fframes, "\n");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment