Skip to content
Snippets Groups Projects
Commit 3be85cf6 authored by Marco Biasini's avatar Marco Biasini
Browse files

more cleanups

parent 9b0fc728
No related branches found
No related tags found
No related merge requests found
......@@ -18,6 +18,7 @@
//------------------------------------------------------------------------------
#include <ost/geom/geom.hh>
#include <ost/geom/vec_mat_predicates.hh>
#include "helper.hh"
using namespace geom;
......@@ -122,6 +123,12 @@ BOOST_AUTO_TEST_CASE(operators_vec3)
// cross
v2=Cross(v1,v3);
BOOST_CHECK(match(v2,0.01,-0.02,0.01));
Vec3 v4(4.25,-1.5,0.75);
BOOST_CHECK(vec3_is_close(Frac(v4), Vec3(0.25,-0.5,0.75)));
}
BOOST_AUTO_TEST_SUITE_END()
......@@ -80,7 +80,8 @@ void MapTool::MouseMove(const MouseEvent& event)
event.GetLastPos().y(), 0);
geom::Vec3 p2(-event.GetPos().x(),
event.GetPos().y(), 0);
geom::Vec3 delta=scene.UnProject(p1)-scene.UnProject(p2);
geom::Vec3 delta=delta_+(scene.UnProject(p1)-scene.UnProject(p2));
delta_=Frac(delta);
img::ImageHandle the_map=mi->GetMap();
img::Extent vis=mi->GetVisibleExtent();
img::Extent new_vis(vis.GetStart()+img::Point(delta),
......
......@@ -72,7 +72,8 @@ img::XtalMapPtr LoadXtalMap(const String& filename)
throw IOException(loc.string()+": Invalid symmetry");
}
LOG_INFO("loaded xtal map with extent " << ih.GetExtent() << " and symmetry '"
<< uc.GetSymmetry()->GetHermannMauguinSymbol() << "'");
<< uc.GetSymmetry()->GetHermannMauguinSymbol() << "'"
<< " unit cell size " << mrc_handler.GetUnitCellSize());
return img::XtalMapPtr(new img::XtalMap(ih, mrc_handler.GetUnitCell(),
mrc_handler.GetUnitCellSize()));
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment