Tango: Added Level of detail rendering depending on the distance from the camera

This commit is contained in:
matlabbe
2017-03-05 21:48:18 -05:00
parent fed9d4ef3b
commit 9f65ef199b
10 changed files with 192 additions and 26 deletions
@@ -804,7 +804,14 @@ public class RTABMapActivity extends Activity implements OnClickListener {
{
if(inliers >= Integer.parseInt(mMinInliers))
{
mToast.setText(String.format("Loop closure rejected, too high graph optimization error (%.3fm > %sm).", optimizationMaxError, mMaxOptimizationError));
if(optimizationMaxError > 0.0f)
{
mToast.setText(String.format("Loop closure rejected, too high graph optimization error (%.3fm > %sm).", optimizationMaxError, mMaxOptimizationError));
}
else
{
mToast.setText(String.format("Loop closure rejected, graph optimization failed! You may try a different Graph Optimizer (see Mapping options)."));
}
}
else
{
@@ -108,6 +108,10 @@ public class Renderer implements GLSurfaceView.Renderer {
{
mToast.makeText(mActivity, String.format("Out of Memory!"), Toast.LENGTH_SHORT).show();
}
else if(value==-2 && mToast!=null)
{
mToast.makeText(mActivity, String.format("Rendering Error!"), Toast.LENGTH_SHORT).show();
}
}
});
}