├── README.md ├── TinyGrapeKit ├── LICENSE ├── README.md ├── app │ ├── FilterFusion │ │ ├── CMakeLists.txt │ │ ├── cmake │ │ │ └── FindGlog.cmake │ │ ├── doc │ │ │ ├── SIM.png │ │ │ ├── VWO-MSCKF.png │ │ │ └── Visual-Wheel-GNSS-Localization.png │ │ ├── example │ │ │ ├── RunKAISTData.cpp │ │ │ ├── RunSimData.cpp │ │ │ └── TestVisualWheelCircleSim.cpp │ │ ├── include │ │ │ └── FilterFusion │ │ │ │ ├── FilterFusionSystem.h │ │ │ │ ├── GpsUpdater.h │ │ │ │ ├── Initializer.h │ │ │ │ ├── ParamLoader.h │ │ │ │ ├── Parameter.h │ │ │ │ ├── PlaneUpdater.h │ │ │ │ ├── Propagator.h │ │ │ │ ├── State.h │ │ │ │ ├── StateAugmentor.h │ │ │ │ ├── StateBlock.h │ │ │ │ ├── StateMarginalizer.h │ │ │ │ ├── UpdaterUtil.h │ │ │ │ ├── VisualUpdater.h │ │ │ │ └── Visualizer.h │ │ ├── params │ │ │ └── KAIST.yaml │ │ └── src │ │ │ ├── FilterFusionSystem.cpp │ │ │ ├── GpsUpdater.cpp │ │ │ ├── Initializer.cpp │ │ │ ├── ParamLoader.cpp │ │ │ ├── PlaneUpdater.cpp │ │ │ ├── Propagator.cpp │ │ │ ├── StateAugmentor.cpp │ │ │ ├── StateMarginalizer.cpp │ │ │ ├── UpdaterUtil.cpp │ │ │ ├── VisualUpdater.cpp │ │ │ └── Visualizer.cpp │ └── SINS │ │ ├── CMakeLists.txt │ │ ├── Core │ │ ├── .DS_Store │ │ ├── Alignment │ │ │ ├── StationaryCoarseAlignment.cpp │ │ │ └── StationaryCoarseAlignment.h │ │ ├── Base │ │ │ ├── .DS_Store │ │ │ ├── Index.h │ │ │ ├── InsState.h │ │ │ ├── KFState.h │ │ │ └── SensorDataTypes.h │ │ ├── Earth │ │ │ ├── EarthModel.cpp │ │ │ └── EarthModel.h │ │ ├── ErrorModel │ │ │ ├── ErrorModel.cpp │ │ │ └── ErrorModel.h │ │ ├── InsUpdate │ │ │ ├── InsUpdater.cpp │ │ │ └── InsUpdater.h │ │ ├── KFSystem │ │ │ ├── KFSystem.cpp │ │ │ └── KFSystem.h │ │ ├── MeasureModel │ │ │ ├── Measurements.cpp │ │ │ └── Measurements.h │ │ └── Utils │ │ │ ├── SO3.h │ │ │ ├── TimeConverter.h │ │ │ └── Utils.h │ │ ├── Data │ │ └── .DS_Store │ │ ├── Examples │ │ ├── InsUpdateExample.cpp │ │ └── StationaryCoarseAlignmentExample.cpp │ │ └── Tools │ │ └── CombineData.cpp ├── build.sh ├── library │ ├── CMakeLists.txt │ ├── build │ │ ├── CMakeCache.txt │ │ ├── CMakeFiles │ │ │ ├── 3.12.2 │ │ │ │ ├── CMakeCCompiler.cmake │ │ │ │ ├── CMakeCXXCompiler.cmake │ │ │ │ ├── CMakeDetermineCompilerABI_C.bin │ │ │ │ ├── CMakeDetermineCompilerABI_CXX.bin │ │ │ │ ├── CMakeSystem.cmake │ │ │ │ ├── CompilerIdC │ │ │ │ │ ├── CMakeCCompilerId.c │ │ │ │ │ └── a.out │ │ │ │ └── CompilerIdCXX │ │ │ │ │ ├── CMakeCXXCompilerId.cpp │ │ │ │ │ └── a.out │ │ │ ├── CMakeDirectoryInformation.cmake │ │ │ ├── CMakeOutput.log │ │ │ ├── Makefile.cmake │ │ │ ├── Makefile2 │ │ │ ├── TargetDirectories.txt │ │ │ ├── TinyGrapeKit.dir │ │ │ │ ├── CXX.includecache │ │ │ │ ├── DependInfo.cmake │ │ │ │ ├── build.make │ │ │ │ ├── cmake_clean.cmake │ │ │ │ ├── depend.internal │ │ │ │ ├── depend.make │ │ │ │ ├── flags.make │ │ │ │ ├── link.txt │ │ │ │ ├── progress.make │ │ │ │ └── src │ │ │ │ │ ├── FeatureTracker.cpp.o │ │ │ │ │ ├── KLTFeatureTracker.cpp.o │ │ │ │ │ ├── PinholeRanTanCamera.cpp.o │ │ │ │ │ ├── SimFeatureTracker.cpp.o │ │ │ │ │ ├── Triangulator.cpp.o │ │ │ │ │ ├── TriangulatorUtil.cpp.o │ │ │ │ │ ├── VisualWheelCircleSim.cpp.o │ │ │ │ │ ├── WheelImageSynchronizer.cpp.o │ │ │ │ │ └── WheelPropagator.cpp.o │ │ │ ├── cmake.check_cache │ │ │ ├── feature_tests.bin │ │ │ ├── feature_tests.c │ │ │ ├── feature_tests.cxx │ │ │ └── progress.marks │ │ ├── Makefile │ │ ├── cmake_install.cmake │ │ ├── install_manifest.txt │ │ └── libTinyGrapeKit.so │ ├── cmake │ │ └── FindGlog.cmake │ ├── include │ │ ├── BaseType │ │ │ └── Measurement.h │ │ ├── Camera │ │ │ ├── Camera.h │ │ │ └── PinholeRanTanCamera.h │ │ ├── Const │ │ │ └── Const.h │ │ ├── DataSynchronizer │ │ │ ├── DataSynchronizerUtil.h │ │ │ └── WheelImageSynchronizer.h │ │ ├── Geometry │ │ │ ├── Triangulator.h │ │ │ └── TriangulatorUtil.h │ │ ├── ImageProcessor │ │ │ ├── FeatureTracker.h │ │ │ ├── KLTFeatureTracker.h │ │ │ └── SimFeatureTracker.h │ │ ├── Simulation │ │ │ └── VisualWheelCircleSim.h │ │ ├── Util │ │ │ └── Util.h │ │ └── WheelProcessor │ │ │ └── WheelPropagator.h │ ├── install │ │ ├── include │ │ │ └── TGK │ │ │ │ ├── BaseType │ │ │ │ └── Measurement.h │ │ │ │ ├── Camera │ │ │ │ ├── Camera.h │ │ │ │ └── PinholeRanTanCamera.h │ │ │ │ ├── Const │ │ │ │ └── Const.h │ │ │ │ ├── DataSynchronizer │ │ │ │ ├── DataSynchronizerUtil.h │ │ │ │ └── WheelImageSynchronizer.h │ │ │ │ ├── Geometry │ │ │ │ ├── Triangulator.h │ │ │ │ └── TriangulatorUtil.h │ │ │ │ ├── ImageProcessor │ │ │ │ ├── FeatureTracker.h │ │ │ │ ├── KLTFeatureTracker.h │ │ │ │ └── SimFeatureTracker.h │ │ │ │ ├── Simulation │ │ │ │ └── VisualWheelCircleSim.h │ │ │ │ ├── Util │ │ │ │ └── Util.h │ │ │ │ └── WheelProcessor │ │ │ │ └── WheelPropagator.h │ │ └── lib │ │ │ └── libTinyGrapeKit.so │ └── src │ │ ├── FeatureTracker.cpp │ │ ├── KLTFeatureTracker.cpp │ │ ├── PinholeRanTanCamera.cpp │ │ ├── SimFeatureTracker.cpp │ │ ├── Triangulator.cpp │ │ ├── TriangulatorUtil.cpp │ │ ├── VisualWheelCircleSim.cpp │ │ ├── WheelImageSynchronizer.cpp │ │ └── WheelPropagator.cpp └── third_party │ ├── GeographicLib │ ├── CMakeLists.txt │ ├── build │ │ ├── CMakeCache.txt │ │ ├── CMakeFiles │ │ │ ├── 3.12.2 │ │ │ │ ├── CMakeCCompiler.cmake │ │ │ │ ├── CMakeCXXCompiler.cmake │ │ │ │ ├── CMakeDetermineCompilerABI_C.bin │ │ │ │ ├── CMakeDetermineCompilerABI_CXX.bin │ │ │ │ ├── CMakeSystem.cmake │ │ │ │ ├── CompilerIdC │ │ │ │ │ ├── CMakeCCompilerId.c │ │ │ │ │ └── a.out │ │ │ │ └── CompilerIdCXX │ │ │ │ │ ├── CMakeCXXCompilerId.cpp │ │ │ │ │ └── a.out │ │ │ ├── CMakeDirectoryInformation.cmake │ │ │ ├── CMakeOutput.log │ │ │ ├── Makefile.cmake │ │ │ ├── Makefile2 │ │ │ ├── TargetDirectories.txt │ │ │ ├── cmake.check_cache │ │ │ ├── feature_tests.bin │ │ │ ├── feature_tests.c │ │ │ ├── feature_tests.cxx │ │ │ ├── libGeographiccc.dir │ │ │ │ ├── CXX.includecache │ │ │ │ ├── DependInfo.cmake │ │ │ │ ├── build.make │ │ │ │ ├── cmake_clean.cmake │ │ │ │ ├── depend.internal │ │ │ │ ├── depend.make │ │ │ │ ├── flags.make │ │ │ │ ├── link.txt │ │ │ │ ├── progress.make │ │ │ │ └── src │ │ │ │ │ ├── Geocentric.cpp.o │ │ │ │ │ ├── LocalCartesian.cpp.o │ │ │ │ │ └── Math.cpp.o │ │ │ └── progress.marks │ │ ├── Makefile │ │ ├── cmake_install.cmake │ │ └── liblibGeographiccc.so │ ├── include │ │ ├── Config.h │ │ ├── Constants.hpp │ │ ├── Geocentric.hpp │ │ ├── LocalCartesian.hpp │ │ └── Math.hpp │ └── src │ │ ├── Geocentric.cpp │ │ ├── LocalCartesian.cpp │ │ └── Math.cpp │ ├── Pangolin │ ├── .clang-format │ ├── .gitignore │ ├── .gitmodules │ ├── .travis.yml │ ├── CMakeLists.txt │ ├── CMakeModules │ │ ├── AndroidUtils.cmake │ │ ├── CreateMethodCallFile.cmake │ │ ├── EmbedBinaryFiles.cmake │ │ ├── FindDC1394.cmake │ │ ├── FindDepthSense.cmake │ │ ├── FindEigen.cmake │ │ ├── FindFFMPEG.cmake │ │ ├── FindFREEGLUT.cmake │ │ ├── FindGLEW.cmake │ │ ├── FindGLUES.cmake │ │ ├── FindLibRealSense.cmake │ │ ├── FindLibRealSense2.cmake │ │ ├── FindLz4.cmake │ │ ├── FindMediaFoundation.cmake │ │ ├── FindOculus.cmake │ │ ├── FindOpenEXR.cmake │ │ ├── FindOpenNI.cmake │ │ ├── FindOpenNI2.cmake │ │ ├── FindPleora.cmake │ │ ├── FindROBOTVISION.cmake │ │ ├── FindTeliCam.cmake │ │ ├── FindTooN.cmake │ │ ├── FindWayland.cmake │ │ ├── FindXrandr.cmake │ │ ├── Findlibusb1.cmake │ │ ├── Findpthread.cmake │ │ ├── Finduvc.cmake │ │ ├── Findzstd.cmake │ │ └── SetPlatformVars.cmake │ ├── LICENCE │ ├── README.md │ ├── appveyor.yml │ ├── cmake_uninstall.cmake.in │ ├── examples │ │ ├── CMakeLists.txt │ │ ├── HelloPangolin │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ ├── HelloPangolinOffscreen │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ ├── HelloPangolinThreads │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ ├── SharedMemoryCamera │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ ├── SimpleDisplay │ │ │ ├── CMakeLists.txt │ │ │ ├── app.cfg │ │ │ └── main.cpp │ │ ├── SimpleDisplayImage │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ ├── SimpleMultiDisplay │ │ │ ├── CMakeLists.txt │ │ │ ├── app.cfg │ │ │ └── main.cpp │ │ ├── SimplePlot │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ ├── SimpleRecord │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ ├── SimpleScene │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ ├── SimpleVideo │ │ │ ├── CMakeLists.txt │ │ │ └── main.cpp │ │ └── VBODisplay │ │ │ ├── CMakeLists.txt │ │ │ ├── kernal.cu │ │ │ └── main.cpp │ ├── external │ │ └── CMakeLists.txt │ ├── include │ │ ├── experimental │ │ │ └── optional.hpp │ │ ├── mpark │ │ │ └── variant.hpp │ │ ├── pangolin │ │ │ ├── compat │ │ │ │ ├── glutbitmap.h │ │ │ │ ├── optional.h │ │ │ │ ├── type_traits.h │ │ │ │ └── variant.h │ │ │ ├── console │ │ │ │ ├── ConsoleInterpreter.h │ │ │ │ └── ConsoleView.h │ │ │ ├── display │ │ │ │ ├── attach.h │ │ │ │ ├── device │ │ │ │ │ ├── OsxWindow.h │ │ │ │ │ ├── PangolinNSApplication.h │ │ │ │ │ ├── PangolinNSGLView.h │ │ │ │ │ ├── WinWindow.h │ │ │ │ │ ├── X11GlContext.h │ │ │ │ │ ├── X11Window.h │ │ │ │ │ └── display_android.h │ │ │ │ ├── display.h │ │ │ │ ├── display_internal.h │ │ │ │ ├── image_view.h │ │ │ │ ├── opengl_render_state.h │ │ │ │ ├── user_app.h │ │ │ │ ├── view.h │ │ │ │ ├── viewport.h │ │ │ │ ├── widgets │ │ │ │ │ └── widgets.h │ │ │ │ └── window.h │ │ │ ├── factory │ │ │ │ └── factory_registry.h │ │ │ ├── geometry │ │ │ │ ├── geometry.h │ │ │ │ ├── geometry_obj.h │ │ │ │ ├── geometry_ply.h │ │ │ │ └── glgeometry.h │ │ │ ├── gl │ │ │ │ ├── cg.h │ │ │ │ ├── colour.h │ │ │ │ ├── compat │ │ │ │ │ ├── gl2engine.h │ │ │ │ │ └── gl_es_compat.h │ │ │ │ ├── gl.h │ │ │ │ ├── gl.hpp │ │ │ │ ├── glchar.h │ │ │ │ ├── glcuda.h │ │ │ │ ├── gldraw.h │ │ │ │ ├── glfont.h │ │ │ │ ├── glformattraits.h │ │ │ │ ├── glinclude.h │ │ │ │ ├── glpangoglu.h │ │ │ │ ├── glpixformat.h │ │ │ │ ├── glplatform.h │ │ │ │ ├── glsl.h │ │ │ │ ├── glstate.h │ │ │ │ ├── gltext.h │ │ │ │ ├── gltexturecache.h │ │ │ │ └── glvbo.h │ │ │ ├── handler │ │ │ │ ├── handler.h │ │ │ │ ├── handler_enums.h │ │ │ │ ├── handler_glbuffer.h │ │ │ │ └── handler_image.h │ │ │ ├── image │ │ │ │ ├── copy.h │ │ │ │ ├── image.h │ │ │ │ ├── image_convert.h │ │ │ │ ├── image_io.h │ │ │ │ ├── image_utils.h │ │ │ │ ├── managed_image.h │ │ │ │ ├── memcpy.h │ │ │ │ ├── pixel_format.h │ │ │ │ └── typed_image.h │ │ │ ├── ios │ │ │ │ ├── PangolinAppDelegate.h │ │ │ │ └── PangolinUIView.h │ │ │ ├── log │ │ │ │ ├── packet.h │ │ │ │ ├── packetstream.h │ │ │ │ ├── packetstream_reader.h │ │ │ │ ├── packetstream_source.h │ │ │ │ ├── packetstream_tags.h │ │ │ │ ├── packetstream_writer.h │ │ │ │ ├── playback_session.h │ │ │ │ └── sync_time.h │ │ │ ├── pangolin.h │ │ │ ├── platform.h │ │ │ ├── plot │ │ │ │ ├── datalog.h │ │ │ │ ├── plotter.h │ │ │ │ └── range.h │ │ │ ├── python │ │ │ │ ├── pyinterpreter.h │ │ │ │ ├── pypangoio.h │ │ │ │ ├── pypangolin_init.h │ │ │ │ ├── pyuniqueobj.h │ │ │ │ └── pyvar.h │ │ │ ├── scene │ │ │ │ ├── axis.h │ │ │ │ ├── interactive.h │ │ │ │ ├── interactive_index.h │ │ │ │ ├── renderable.h │ │ │ │ ├── scenehandler.h │ │ │ │ └── tree.h │ │ │ ├── tools │ │ │ │ └── video_viewer.h │ │ │ ├── utils │ │ │ │ ├── argagg.hpp │ │ │ │ ├── assert.h │ │ │ │ ├── compontent_cast.h │ │ │ │ ├── file_extension.h │ │ │ │ ├── file_utils.h │ │ │ │ ├── fix_size_buffer_queue.h │ │ │ │ ├── format_string.h │ │ │ │ ├── log.h │ │ │ │ ├── memstreambuf.h │ │ │ │ ├── params.h │ │ │ │ ├── parse.h │ │ │ │ ├── picojson.h │ │ │ │ ├── posix │ │ │ │ │ ├── condition_variable.h │ │ │ │ │ ├── semaphore.h │ │ │ │ │ └── shared_memory_buffer.h │ │ │ │ ├── registration.h │ │ │ │ ├── signal_slot.h │ │ │ │ ├── sigstate.h │ │ │ │ ├── simple_math.h │ │ │ │ ├── threadedfilebuf.h │ │ │ │ ├── timer.h │ │ │ │ ├── transform.h │ │ │ │ ├── type_convert.h │ │ │ │ ├── uri.h │ │ │ │ ├── variadic_all.h │ │ │ │ └── xml │ │ │ │ │ ├── license.txt │ │ │ │ │ ├── rapidxml.hpp │ │ │ │ │ ├── rapidxml_iterators.hpp │ │ │ │ │ ├── rapidxml_print.hpp │ │ │ │ │ └── rapidxml_utils.hpp │ │ │ ├── var │ │ │ │ ├── input_record_repeat.h │ │ │ │ ├── var.h │ │ │ │ ├── varextra.h │ │ │ │ ├── varstate.h │ │ │ │ ├── varvalue.h │ │ │ │ ├── varvaluegeneric.h │ │ │ │ ├── varvaluet.h │ │ │ │ └── varwrapper.h │ │ │ └── video │ │ │ │ ├── drivers │ │ │ │ ├── debayer.h │ │ │ │ ├── deinterlace.h │ │ │ │ ├── depthsense.h │ │ │ │ ├── ffmpeg.h │ │ │ │ ├── firewire.h │ │ │ │ ├── images.h │ │ │ │ ├── images_out.h │ │ │ │ ├── join.h │ │ │ │ ├── merge.h │ │ │ │ ├── mirror.h │ │ │ │ ├── openni.h │ │ │ │ ├── openni2.h │ │ │ │ ├── openni_common.h │ │ │ │ ├── pack.h │ │ │ │ ├── pango.h │ │ │ │ ├── pango_video_output.h │ │ │ │ ├── pleora.h │ │ │ │ ├── pvn.h │ │ │ │ ├── realsense.h │ │ │ │ ├── realsense2.h │ │ │ │ ├── shared_memory.h │ │ │ │ ├── shift.h │ │ │ │ ├── split.h │ │ │ │ ├── teli.h │ │ │ │ ├── test.h │ │ │ │ ├── thread.h │ │ │ │ ├── truncate.h │ │ │ │ ├── unpack.h │ │ │ │ ├── uvc.h │ │ │ │ ├── uvc_mediafoundation.h │ │ │ │ └── v4l.h │ │ │ │ ├── iostream_operators.h │ │ │ │ ├── stream_encoder_factory.h │ │ │ │ ├── stream_info.h │ │ │ │ ├── video.h │ │ │ │ ├── video_exception.h │ │ │ │ ├── video_input.h │ │ │ │ ├── video_interface.h │ │ │ │ ├── video_output.h │ │ │ │ ├── video_output_interface.h │ │ │ │ └── video_record_repeat.h │ │ └── tinyobj │ │ │ └── tiny_obj_loader.h │ ├── package.xml │ ├── pyexamples │ │ ├── SimpleDisplay.py │ │ ├── SimplePlot.py │ │ └── SimpleVideo.py │ ├── src │ │ ├── CMakeLists.txt │ │ ├── Doxyfile.in │ │ ├── PangolinConfig.cmake.in │ │ ├── PangolinConfigVersion.cmake.in │ │ ├── _embed_ │ │ │ └── fonts │ │ │ │ ├── AnonymousPro.ttf │ │ │ │ └── AnonymousPro.txt │ │ ├── config.h.in │ │ ├── console │ │ │ └── ConsoleView.cpp │ │ ├── display │ │ │ ├── device │ │ │ │ ├── PangolinNSApplication.mm │ │ │ │ ├── PangolinNSGLView.mm │ │ │ │ ├── display_android.cpp │ │ │ │ ├── display_headless.cpp │ │ │ │ ├── display_osx.mm │ │ │ │ ├── display_wayland.cpp │ │ │ │ ├── display_win.cpp │ │ │ │ └── display_x11.cpp │ │ │ ├── display.cpp │ │ │ ├── image_view.cpp │ │ │ ├── opengl_render_state.cpp │ │ │ ├── view.cpp │ │ │ ├── viewport.cpp │ │ │ ├── widgets │ │ │ │ └── widgets.cpp │ │ │ └── window_factory.cpp │ │ ├── geometry │ │ │ ├── geometry.cpp │ │ │ ├── geometry_obj.cpp │ │ │ ├── geometry_ply.cpp │ │ │ ├── glgeometry.cpp │ │ │ └── tinyobj.cpp │ │ ├── gl │ │ │ ├── compat │ │ │ │ └── gl2engine.cpp │ │ │ ├── glchar.cpp │ │ │ ├── gldraw.cpp │ │ │ ├── glfont.cpp │ │ │ ├── glpangoglu.cpp │ │ │ ├── gltext.cpp │ │ │ ├── gltexturecache.cpp │ │ │ └── stb_truetype.h │ │ ├── handler │ │ │ ├── handler.cpp │ │ │ ├── handler_glbuffer.cpp │ │ │ └── handler_image.cpp │ │ ├── image │ │ │ ├── image_io.cpp │ │ │ ├── image_io_exr.cpp │ │ │ ├── image_io_jpg.cpp │ │ │ ├── image_io_lz4.cpp │ │ │ ├── image_io_packed12bit.cpp │ │ │ ├── image_io_pango.cpp │ │ │ ├── image_io_png.cpp │ │ │ ├── image_io_ppm.cpp │ │ │ ├── image_io_raw.cpp │ │ │ ├── image_io_tga.cpp │ │ │ ├── image_io_zstd.cpp │ │ │ └── pixel_format.cpp │ │ ├── ios │ │ │ ├── PangolinAppDelegate.mm │ │ │ └── PangolinUIView.mm │ │ ├── log │ │ │ ├── packet.cpp │ │ │ ├── packetstream.cpp │ │ │ ├── packetstream_reader.cpp │ │ │ ├── packetstream_writer.cpp │ │ │ └── playback_session.cpp │ │ ├── plot │ │ │ ├── datalog.cpp │ │ │ └── plotter.cpp │ │ ├── python │ │ │ ├── pyinterpreter.cpp │ │ │ ├── pypangolin │ │ │ │ ├── attach.cpp │ │ │ │ ├── attach.hpp │ │ │ │ ├── colour.cpp │ │ │ │ ├── colour.hpp │ │ │ │ ├── datalog.cpp │ │ │ │ ├── datalog.hpp │ │ │ │ ├── display.cpp │ │ │ │ ├── display.hpp │ │ │ │ ├── gl.cpp │ │ │ │ ├── gl.hpp │ │ │ │ ├── gl_draw.cpp │ │ │ │ ├── gl_draw.hpp │ │ │ │ ├── glsl.cpp │ │ │ │ ├── glsl.hpp │ │ │ │ ├── handler.cpp │ │ │ │ ├── handler.hpp │ │ │ │ ├── image.cpp │ │ │ │ ├── image.hpp │ │ │ │ ├── image_view.cpp │ │ │ │ ├── image_view.hpp │ │ │ │ ├── opengl_render_state.cpp │ │ │ │ ├── opengl_render_state.hpp │ │ │ │ ├── params.cpp │ │ │ │ ├── params.hpp │ │ │ │ ├── pixel_format.cpp │ │ │ │ ├── pixel_format.hpp │ │ │ │ ├── plotter.cpp │ │ │ │ ├── plotter.hpp │ │ │ │ ├── pypangolin.h │ │ │ │ ├── var.cpp │ │ │ │ ├── var.hpp │ │ │ │ ├── video.cpp │ │ │ │ ├── video.hpp │ │ │ │ ├── view.cpp │ │ │ │ ├── view.hpp │ │ │ │ ├── viewport.cpp │ │ │ │ ├── viewport.hpp │ │ │ │ ├── widget.cpp │ │ │ │ ├── widget.hpp │ │ │ │ ├── window.cpp │ │ │ │ └── window.hpp │ │ │ ├── pypangolin_init.cpp │ │ │ └── pypangolin_module.cpp │ │ ├── tools │ │ │ └── video_viewer.cpp │ │ ├── utils │ │ │ ├── file_extension.cpp │ │ │ ├── file_utils.cpp │ │ │ ├── posix │ │ │ │ ├── condition_variable.cpp │ │ │ │ ├── semaphore.cpp │ │ │ │ └── shared_memory_buffer.cpp │ │ │ ├── sigstate.cpp │ │ │ ├── threadedfilebuf.cpp │ │ │ ├── timer.cpp │ │ │ └── uri.cpp │ │ ├── var │ │ │ ├── input_record_repeat.cpp │ │ │ └── vars.cpp │ │ └── video │ │ │ ├── drivers │ │ │ ├── debayer.cpp │ │ │ ├── deinterlace.cpp │ │ │ ├── depthsense.cpp │ │ │ ├── ffmpeg.cpp │ │ │ ├── firewire.cpp │ │ │ ├── images.cpp │ │ │ ├── images_out.cpp │ │ │ ├── join.cpp │ │ │ ├── json.cpp │ │ │ ├── merge.cpp │ │ │ ├── mirror.cpp │ │ │ ├── openni.cpp │ │ │ ├── openni2.cpp │ │ │ ├── pack.cpp │ │ │ ├── pango.cpp │ │ │ ├── pango_video_output.cpp │ │ │ ├── pleora.cpp │ │ │ ├── pvn.cpp │ │ │ ├── realsense.cpp │ │ │ ├── realsense2.cpp │ │ │ ├── shared_memory.cpp │ │ │ ├── shift.cpp │ │ │ ├── split.cpp │ │ │ ├── teli.cpp │ │ │ ├── test.cpp │ │ │ ├── thread.cpp │ │ │ ├── truncate.cpp │ │ │ ├── unpack.cpp │ │ │ ├── uvc.cpp │ │ │ ├── uvc_mediafoundation.cpp │ │ │ └── v4l.cpp │ │ │ ├── stream_encoder_factory.cpp │ │ │ ├── video.cpp │ │ │ ├── video_input.cpp │ │ │ ├── video_interface_factory.cpp │ │ │ ├── video_output.cpp │ │ │ └── video_output_interface_factory.cpp │ ├── test │ │ ├── CMakeLists.txt │ │ └── log │ │ │ ├── CMakeLists.txt │ │ │ └── testlog.cpp │ └── tools │ │ ├── CMakeLists.txt │ │ ├── ModelViewer │ │ ├── CMakeLists.txt │ │ ├── main.cpp │ │ ├── rendertree.h │ │ ├── shader.h │ │ └── util.h │ │ ├── Plotter │ │ ├── CMakeLists.txt │ │ ├── application-x-pangoplot.xml │ │ ├── csv_data_loader.h │ │ └── main.cpp │ │ ├── VideoConvert │ │ ├── CMakeLists.txt │ │ └── main.cpp │ │ ├── VideoJson │ │ ├── CMakeLists.txt │ │ ├── main-print.cpp │ │ └── main-transform.cpp │ │ └── VideoViewer │ │ ├── CMakeLists.txt │ │ ├── application-x-pango.svg │ │ ├── application-x-pango.xml │ │ └── main.cpp │ └── basalt-headers │ ├── .clang-format │ ├── .gitignore │ ├── .gitlab-ci.yml │ ├── .gitmodules │ ├── CMakeLists.txt │ ├── Doxyfile │ ├── LICENSE │ ├── README.md │ ├── cmake_modules │ ├── FindEigen3.cmake │ └── PreProjectWorkarounds.cmake │ ├── doc │ ├── img │ │ ├── basalt_light.png │ │ ├── ds.png │ │ ├── eucm.png │ │ ├── fov.png │ │ ├── kb.png │ │ ├── mipmap.jpeg │ │ ├── stereographic.png │ │ └── ucm.png │ └── mainpage.dox │ ├── include │ └── basalt │ │ ├── calibration │ │ ├── calib_bias.hpp │ │ └── calibration.hpp │ │ ├── camera │ │ ├── bal_camera.hpp │ │ ├── double_sphere_camera.hpp │ │ ├── extended_camera.hpp │ │ ├── fov_camera.hpp │ │ ├── generic_camera.hpp │ │ ├── kannala_brandt_camera4.hpp │ │ ├── pinhole_camera.hpp │ │ ├── stereographic_param.hpp │ │ └── unified_camera.hpp │ │ ├── image │ │ ├── image.h │ │ └── image_pyr.h │ │ ├── imu │ │ ├── imu_types.h │ │ └── preintegration.h │ │ ├── serialization │ │ ├── eigen_io.h │ │ └── headers_serialization.h │ │ ├── spline │ │ ├── ceres_local_param.hpp │ │ ├── ceres_spline_helper.h │ │ ├── rd_spline.h │ │ ├── se3_spline.h │ │ ├── so3_spline.h │ │ └── spline_common.h │ │ └── utils │ │ ├── assert.h │ │ ├── eigen_utils.hpp │ │ ├── hash.h │ │ └── sophus_utils.hpp │ ├── scripts │ └── clang-format-all.sh │ └── test │ ├── CMakeLists.txt │ ├── include │ └── test_utils.h │ └── src │ ├── benchmark_camera.cpp │ ├── test_camera.cpp │ ├── test_ceres_spline_helper.cpp │ ├── test_image.cpp │ ├── test_preintegration.cpp │ ├── test_sophus.cpp │ ├── test_spline.cpp │ └── test_spline_se3.cpp ├── imu_gps_encoder_msckf └── src │ ├── camera_model │ ├── CMakeLists.txt │ ├── cmake │ │ └── FindEigen.cmake │ ├── include │ │ └── camodocal │ │ │ ├── calib │ │ │ └── CameraCalibration.h │ │ │ ├── camera_models │ │ │ ├── Camera.h │ │ │ ├── CameraFactory.h │ │ │ ├── CataCamera.h │ │ │ ├── CostFunctionFactory.h │ │ │ ├── EquidistantCamera.h │ │ │ ├── PinholeCamera.h │ │ │ └── ScaramuzzaCamera.h │ │ │ ├── chessboard │ │ │ ├── Chessboard.h │ │ │ ├── ChessboardCorner.h │ │ │ ├── ChessboardQuad.h │ │ │ └── Spline.h │ │ │ ├── gpl │ │ │ ├── EigenQuaternionParameterization.h │ │ │ ├── EigenUtils.h │ │ │ └── gpl.h │ │ │ └── sparse_graph │ │ │ └── Transform.h │ ├── instruction │ ├── package.xml │ ├── readme.md │ └── src │ │ ├── calib │ │ └── CameraCalibration.cc │ │ ├── camera_models │ │ ├── Camera.cc │ │ ├── CameraFactory.cc │ │ ├── CataCamera.cc │ │ ├── CostFunctionFactory.cc │ │ ├── EquidistantCamera.cc │ │ ├── PinholeCamera.cc │ │ └── ScaramuzzaCamera.cc │ │ ├── chessboard │ │ └── Chessboard.cc │ │ ├── gpl │ │ ├── EigenQuaternionParameterization.cc │ │ └── gpl.cc │ │ ├── intrinsic_calib.cc │ │ └── sparse_graph │ │ └── Transform.cc │ ├── config │ ├── fisheye_mask.jpg │ ├── kaist.rviz │ └── kaist.yaml │ ├── doc │ ├── 08739427.pdf │ ├── 2021-05-27 12-51-17 的屏幕截图.png │ ├── 2021-05-27 12-55-34 的屏幕截图.png │ ├── 2021-05-27 12-59-27 的屏幕截图.png │ ├── 2021-05-27 13-02-13 的屏幕截图.png │ ├── 2021-05-27 13-09-51 的屏幕截图.png │ ├── DanielMedina_ION19.pdf │ ├── problem.txt │ └── rosgraph.png │ ├── feature_tracker │ ├── CMakeLists.txt │ ├── cmake │ │ └── FindEigen.cmake │ ├── package.xml │ └── src │ │ ├── feature_tracker.cpp │ │ ├── feature_tracker.h │ │ ├── feature_tracker_node.cpp │ │ ├── parameters.cpp │ │ ├── parameters.h │ │ └── tic_toc.h │ ├── msckf_estimator │ ├── CMakeLists.txt │ ├── package.xml │ └── src │ │ ├── estimator.cpp │ │ ├── estimator.h │ │ ├── estimator_node.cpp │ │ ├── parameters.cpp │ │ └── parameters.h │ └── readKaistDataset │ ├── CMakeLists.txt │ ├── launch │ └── kaist.launch │ ├── msg │ ├── encoder.msg │ ├── gps.msg │ └── imu.msg │ ├── package.xml │ ├── src │ ├── encoder_publisher.cpp │ ├── gps_publisher.cpp │ ├── img_publisher.cpp │ ├── imu_publisher.cpp │ └── vrs_gps_publisher.cpp │ └── third_party │ └── GeographicLib │ ├── CMakeLists.txt │ ├── include │ ├── Config.h │ ├── Constants.hpp │ ├── Geocentric.hpp │ ├── LocalCartesian.hpp │ └── Math.hpp │ └── src │ ├── Geocentric.cpp │ ├── LocalCartesian.cpp │ └── Math.cpp ├── imu_gps_localization ├── .vscode │ ├── c_cpp_properties.json │ └── settings.json ├── CMakeLists.txt ├── README.md ├── doc │ └── path.png ├── imu_gps_localizer │ ├── CMakeLists.txt │ ├── include │ │ └── imu_gps_localizer │ │ │ ├── base_type.h │ │ │ ├── gps_processor.h │ │ │ ├── imu_gps_localizer.h │ │ │ ├── imu_processor.h │ │ │ ├── initializer.h │ │ │ └── utils.h │ ├── src │ │ ├── gps_processor.cpp │ │ ├── imu_gps_localizer.cpp │ │ ├── imu_processor.cpp │ │ └── initializer.cpp │ └── third_party │ │ └── GeographicLib │ │ ├── CMakeLists.txt │ │ ├── include │ │ ├── Config.h │ │ ├── Constants.hpp │ │ ├── Geocentric.hpp │ │ ├── LocalCartesian.hpp │ │ └── Math.hpp │ │ └── src │ │ ├── Geocentric.cpp │ │ ├── LocalCartesian.cpp │ │ └── Math.cpp ├── package.xml ├── results │ ├── uppc.txt │ └── uppc_imu.txt └── ros_wrapper │ ├── include │ └── localization_wrapper.h │ ├── launch │ └── imu_gps_localization.launch │ ├── rviz │ └── default.rviz │ └── src │ ├── localization_node.cpp │ └── localization_wrapper.cpp └── results ├── TinyGrapeKit.png ├── imu_gps_encoder_msckf.png └── imu_gps_localization.png /README.md: -------------------------------------------------------------------------------- 1 | # Multi-Sensor-Fusion-Frameworks 2 | 开源的多传感器融合框架(GNSS, IMU, Camera, Lidar) 3 | 4 | 5 | #### TinyGrapeKit 6 | 轮速、视觉、GPS融合定位(https://zhuanlan.zhihu.com/p/330880853) 7 | 8 | 9 | 测试数据:KAIST Urban DataSet ([urban30](https://drive.google.com/drive/folders/1OizXFczlctIfFvfpw4R1klLDKJM-MznU?usp=sharing) [urban22](https://drive.google.com/drive/folders/1iLfzg5Y66GN52komL22CISWVV6_T99O4?usp=sharing)) 10 | 11 | ``` 12 | cd ~/TinyGrapeKit/app/FilterFusion/build 13 | ./RunKAISTData ~/TinyGrapeKit/app/FilterFusion/params/KAIST.yaml ~/kaist 14 | ``` 15 | 16 | ![](results/TinyGrapeKit.png) 17 | 18 | #### imu_gps_encoder_msckf 19 | 20 | IMU、GPS融合定位 21 | 测试数据:KAIST Urban DataSet([urban32](https://drive.google.com/drive/folders/1LCPxO7YKiv1-Kc477g1GRhyikdmgJEzR)) 22 | 23 | ``` 24 | roslaunch read_kaist_dataset kaist.launch 25 | ``` 26 | ![](results/imu_gps_encoder_msckf.png) 27 | 28 | #### imu_gps_localization 29 | 30 | IMU、GPS融合定位 31 | 测试数据:https://drive.google.com/file/d/1S9M0gwNQ1rdXC7CPmH9ke0jbwOlopQpB/view?usp=sharing 32 | 33 | ``` 34 | roslaunch imu_gps_localization imu_gps_localization.launch 35 | ``` 36 | ![](results/imu_gps_localization.png) -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/cmake/FindGlog.cmake: -------------------------------------------------------------------------------- 1 | # The following variables are optionally searched for defaults 2 | # GLOG_ROOT_DIR: Base directory where all GLOG components are found 3 | # 4 | # The following are set after configuration is done: 5 | # GLOG_FOUND 6 | # GLOG_INCLUDE_DIRS 7 | # GLOG_LIBRARIES 8 | 9 | include(FindPackageHandleStandardArgs) 10 | 11 | set(GLOG_ROOT_DIR "" CACHE PATH "Folder contains Google glog") 12 | 13 | if(WIN32) 14 | find_path(GLOG_INCLUDE_DIR glog/logging.h 15 | PATHS ${GLOG_ROOT_DIR}/src/windows) 16 | else() 17 | find_path(GLOG_INCLUDE_DIR glog/logging.h 18 | PATHS ${GLOG_ROOT_DIR}) 19 | endif() 20 | 21 | if(MSVC) 22 | find_library(GLOG_LIBRARY_RELEASE libglog_static 23 | PATHS ${GLOG_ROOT_DIR} 24 | PATH_SUFFIXES Release) 25 | 26 | find_library(GLOG_LIBRARY_DEBUG libglog_static 27 | PATHS ${GLOG_ROOT_DIR} 28 | PATH_SUFFIXES Debug) 29 | 30 | set(GLOG_LIBRARY optimized ${GLOG_LIBRARY_RELEASE} debug ${GLOG_LIBRARY_DEBUG}) 31 | else() 32 | find_library(GLOG_LIBRARY glog 33 | PATHS ${GLOG_ROOT_DIR} 34 | PATH_SUFFIXES 35 | lib 36 | lib64) 37 | endif() 38 | 39 | find_package_handle_standard_args(GLOG DEFAULT_MSG 40 | GLOG_INCLUDE_DIR GLOG_LIBRARY) 41 | 42 | if(GLOG_FOUND) 43 | set(GLOG_INCLUDE_DIRS ${GLOG_INCLUDE_DIR}) 44 | set(GLOG_LIBRARIES ${GLOG_LIBRARY}) 45 | endif() 46 | -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/doc/SIM.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/app/FilterFusion/doc/SIM.png -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/doc/VWO-MSCKF.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/app/FilterFusion/doc/VWO-MSCKF.png -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/doc/Visual-Wheel-GNSS-Localization.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/app/FilterFusion/doc/Visual-Wheel-GNSS-Localization.png -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/GpsUpdater.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | #include 8 | #include 9 | 10 | namespace FilterFusion { 11 | 12 | class GpsUpdater { 13 | public: 14 | GpsUpdater(const Eigen::Vector3d& C_p_Gps); 15 | 16 | bool UpdateState(const TGK::BaseType::GpsDataConstPtr gps_data, State* state); 17 | 18 | void SetInitLonLatHei(const Eigen::Vector3d& init_lon_lat_hei); 19 | 20 | bool GetInitLonLatHei(Eigen::Vector3d* init_lon_lat_hei); 21 | 22 | private: 23 | Eigen::Vector3d C_p_Gps_; 24 | 25 | Eigen::Vector3d init_lon_lat_hei_; 26 | bool init_set = false; 27 | 28 | std::deque gps_data_queue_; 29 | }; 30 | 31 | 32 | Eigen::Vector3d ConvertLonLatHeiToENU(const Eigen::Vector3d& init_long_lat_hei, 33 | const Eigen::Vector3d& point_long_lat_hei); 34 | 35 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/Initializer.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace FilterFusion { 6 | 7 | class Initializer { 8 | public: 9 | Initializer(const Eigen::Matrix3d& O_R_C, const Eigen::Vector3d& O_p_C, 10 | const double kl, const double kr, const double b); 11 | 12 | void Initialize(const double timestamp, State* init_state); 13 | 14 | private: 15 | Eigen::Matrix3d O_R_C_; 16 | Eigen::Vector3d O_p_C_; 17 | 18 | double kl_; 19 | double kr_; 20 | double b_; 21 | }; 22 | 23 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/ParamLoader.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace FilterFusion { 6 | 7 | void LoadParam(const std::string& param_file, Parameter* params); 8 | 9 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/PlaneUpdater.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace FilterFusion { 6 | 7 | class PlaneUpdater { 8 | public: 9 | struct Config { 10 | double plane_rot_noise = 0.01; 11 | double plane_trans_noise = 0.01; 12 | }; 13 | 14 | PlaneUpdater(const Config& config); 15 | 16 | bool UpdateState(State* state); 17 | 18 | private: 19 | Config config_; 20 | }; 21 | 22 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/Propagator.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | #include 7 | 8 | namespace FilterFusion { 9 | 10 | class Propagator { 11 | public: 12 | Propagator(const double kl, const double kr,const double b, const double noise_factor); 13 | 14 | void Propagate(const double begin_wl, const double begin_wr, 15 | const double end_wl, const double end_wr, 16 | State* state); 17 | private: 18 | std::unique_ptr wheel_propagator_; 19 | }; 20 | 21 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/State.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | #include 8 | #include 9 | 10 | namespace FilterFusion { 11 | 12 | struct State { 13 | double timestamp; 14 | 15 | // Wheel Instrinsic. 16 | WheelIntrinsic wheel_intrinsic; 17 | // Extrinsic. 18 | Extrinsic extrinsic; 19 | // The current wheel pose. 20 | WheelPose wheel_pose; 21 | // Camera poses. 22 | std::deque camera_frames; 23 | 24 | // Covariance. 25 | Eigen::MatrixXd covariance; 26 | 27 | void Update(const Eigen::VectorXd& delta_x) { 28 | // Update Wheel_pose. 29 | wheel_pose.Update(delta_x.segment(wheel_pose.state_idx, wheel_pose.size)); 30 | 31 | // Update Camera pose. 32 | for (CameraFramePtr& cam_fm : camera_frames) { 33 | cam_fm->Update(delta_x.segment(cam_fm->state_idx, cam_fm->size)); 34 | } 35 | } 36 | }; 37 | 38 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/StateAugmentor.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | namespace FilterFusion { 5 | 6 | void AugmentState(const double timestamp, const long int frame_id, State* state); 7 | 8 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/StateMarginalizer.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace FilterFusion { 6 | 7 | void MargOldestState(State* state); 8 | 9 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/include/FilterFusion/UpdaterUtil.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | namespace FilterFusion { 8 | 9 | void LeftNullspaceProjection(const Eigen::MatrixXd& Hx, 10 | const Eigen::MatrixXd& Hf, 11 | const Eigen::VectorXd& res, 12 | Eigen::MatrixXd* H, 13 | Eigen::VectorXd* r); 14 | 15 | void CompressMeasurement(const Eigen::MatrixXd& H, 16 | const Eigen::VectorXd& r, 17 | Eigen::MatrixXd* H_cmp, 18 | Eigen::VectorXd* r_cmp); 19 | 20 | void EKFUpdate(const Eigen::MatrixXd& H, 21 | const Eigen::VectorXd& r, 22 | const Eigen::MatrixXd& V, 23 | State* state); 24 | 25 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/src/Initializer.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | namespace FilterFusion { 4 | 5 | Initializer::Initializer(const Eigen::Matrix3d& O_R_C, const Eigen::Vector3d& O_p_C, 6 | const double kl, const double kr, const double b) 7 | : O_R_C_(O_R_C), O_p_C_(O_p_C), kl_(kl), kr_(kr), b_(b) { } 8 | 9 | void Initializer::Initialize(const double timestamp, State* init_state) { 10 | init_state->timestamp = timestamp; 11 | 12 | // Do not estimate extrinsic. 13 | init_state->extrinsic.O_R_C = O_R_C_; 14 | init_state->extrinsic.O_p_C = O_p_C_; 15 | 16 | // Do not estimate intrinsic. 17 | init_state->wheel_intrinsic.kl = kl_; 18 | init_state->wheel_intrinsic.kr = kr_; 19 | init_state->wheel_intrinsic.b = b_; 20 | 21 | // Set initial wheel pose to ZERO. 22 | int state_idx = 0; 23 | init_state->wheel_pose.G_R_O.setIdentity(); 24 | init_state->wheel_pose.G_p_O.setZero(); 25 | init_state->wheel_pose.state_idx = state_idx; 26 | 27 | // Clear camera frame. 28 | init_state->camera_frames.clear(); 29 | 30 | // Set initial covariance. 31 | const int cov_size = init_state->wheel_pose.size; 32 | init_state->covariance.resize(cov_size, cov_size); 33 | init_state->covariance.setIdentity(); 34 | init_state->covariance *= 1e-12; 35 | } 36 | 37 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/FilterFusion/src/StateMarginalizer.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | namespace FilterFusion { 4 | 5 | void MargOldestState(State* state) { 6 | if (state->camera_frames.empty()) { return; } 7 | 8 | // Remove camera state. 9 | int org_state_idx = state->camera_frames.front()->state_idx; 10 | int state_idx = org_state_idx; 11 | state->camera_frames.pop_front(); 12 | for (auto& cam_fm : state->camera_frames) { 13 | cam_fm->state_idx = state_idx; 14 | state_idx += cam_fm->size; 15 | } 16 | 17 | // Remove row and col in covariance matrix. 18 | const int old_cov_size = state->covariance.rows(); 19 | const int new_cov_size = old_cov_size - 6; 20 | Eigen::MatrixXd new_cov(new_cov_size, new_cov_size); 21 | 22 | const Eigen::MatrixXd& old_cov = state->covariance; 23 | new_cov.block<6, 6>(0, 0) = old_cov.block<6, 6>(0, 0); 24 | new_cov.block(0, 6, 6, new_cov_size - 6) = old_cov.block(0, 12, 6, new_cov_size - 6); 25 | new_cov.block(6, 6, new_cov_size - 6, new_cov_size - 6) 26 | = old_cov.block(12, 12, new_cov_size - 6, new_cov_size - 6); 27 | 28 | // Force symetric. 29 | state->covariance = new_cov.selfadjointView(); 30 | } 31 | 32 | } // namespace FilterFusion -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 2.8.12) 2 | project(SINS) 3 | 4 | # Set C++14 5 | add_compile_options(-std=c++14) 6 | 7 | # Third party dependencies 8 | find_package(Eigen3 REQUIRED) 9 | include_directories(${EIGEN3_INCLUDE_DIR}) 10 | find_package(Glog REQUIRED) 11 | include_directories(${GLOG_INCLUDE_DIR}) 12 | 13 | # Make core library 14 | file(GLOB_RECURSE ALL_HEADER_FILES 15 | ${PROJECT_SOURCE_DIR}/Core/*/*.h 16 | ) 17 | file(GLOB_RECURSE ALL_SRC_FILES 18 | ${PROJECT_SOURCE_DIR}/Core/*/*.cpp 19 | ) 20 | 21 | #include_directories(${PROJECT_SOURCE_DIR}/core/*/) 22 | add_library(${PROJECT_NAME}_Core SHARED ${ALL_SRC_FILES} ${ALL_HEADER_FILES}) 23 | 24 | # Make examples. 25 | include_directories(${PROJECT_SOURCE_DIR}/Core/) 26 | add_executable(StationaryCoarseAlignmentExample 27 | Examples/StationaryCoarseAlignmentExample.cpp) 28 | target_link_libraries(StationaryCoarseAlignmentExample 29 | ${PROJECT_NAME}_Core) 30 | 31 | add_executable(CombineData 32 | Tools/CombineData.cpp) 33 | target_link_libraries(CombineData 34 | ${PROJECT_NAME}_Core) 35 | 36 | add_executable(InsUpdateExample 37 | Examples/InsUpdateExample.cpp) 38 | target_link_libraries(InsUpdateExample 39 | ${PROJECT_NAME}_Core) 40 | -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/app/SINS/Core/.DS_Store -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/Alignment/StationaryCoarseAlignment.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace SINS { 6 | 7 | // return: Rotation from body to navigation frame. C_nb: p_n = C_nb * p_b. 8 | Eigen::Matrix3d StationaryCoarseAlign(const Eigen::Vector3d &acc, const Eigen::Vector3d &gyro, 9 | const Eigen::Vector3d &acc_bias = Eigen::Vector3d::Zero(), 10 | const Eigen::Vector3d &gyro_bias = Eigen::Vector3d::Zero()); 11 | 12 | // return: Latitude [radian] 13 | double ComputeLatitude(const Eigen::Vector3d &acc, const Eigen::Vector3d &gyro, 14 | const Eigen::Vector3d &acc_bias = Eigen::Vector3d::Zero(), 15 | const Eigen::Vector3d &gyro_bias = Eigen::Vector3d::Zero()); 16 | 17 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/Base/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/app/SINS/Core/Base/.DS_Store -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/Base/Index.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace SINS { 6 | 7 | constexpr size_t kAttErrIdx = 0u; 8 | constexpr size_t kAttErrDim = 3u; 9 | 10 | constexpr size_t kVelErrIdx = kAttErrIdx + kAttErrDim; 11 | constexpr size_t kVelErrDim = 3u; 12 | 13 | constexpr size_t kPosErrIdx = kVelErrIdx + kVelErrDim; 14 | constexpr size_t kPosErrDim = 3u; 15 | 16 | constexpr size_t kGyroBiasErrIdx = kPosErrIdx + kPosErrDim; 17 | constexpr size_t kGyroBiasErrDim = 3u; 18 | 19 | constexpr size_t kAccBiasErrIdx = kGyroBiasErrIdx + kGyroBiasErrDim; 20 | constexpr size_t kAccBiasErrDim = 3u; 21 | 22 | constexpr size_t kGnssArmIdx = kAccBiasErrIdx + kAccBiasErrDim; 23 | constexpr size_t kGnssArmDim = 3u; 24 | 25 | constexpr size_t kKFStateDim = kAttErrDim + kVelErrDim + kPosErrDim + kGyroBiasErrDim + kAccBiasErrDim + kGnssArmDim; 26 | 27 | constexpr size_t kGyroNoiseIdx = 0u; 28 | constexpr size_t kAccNoiseIdx = 3u; 29 | 30 | using KFMat = Eigen::Matrix; 31 | 32 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/Base/InsState.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace SINS { 6 | 7 | struct InsState { 8 | double time; // [s] 9 | 10 | // AVP 11 | Eigen::Quaterniond orientation; // q_nb 12 | Eigen::Vector3d velocity; // v_nb 13 | Eigen::Vector3d lat_lon_hei; // [rad, rad, m] 14 | 15 | // IMU bias. 16 | Eigen::Vector3d gyro_bias; 17 | Eigen::Vector3d acc_bias; 18 | 19 | // IMU Reading. 20 | Eigen::Vector3d ub_acc; // [m/s^2] 21 | Eigen::Vector3d ub_gyro; // [rad / s] 22 | 23 | // Earth params. 24 | bool update_earth = false; 25 | Eigen::Vector3d gravity = Eigen::Vector3d(0.0, 0.0, -9.8); 26 | double Rm; 27 | double Rn; 28 | Eigen::Vector3d Wnie; 29 | Eigen::Vector3d Wnen; 30 | Eigen::Vector3d Wnin; 31 | 32 | // Mid use 33 | Eigen::Matrix3d Mpv; 34 | }; 35 | 36 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/Base/KFState.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include "Base/Index.h" 5 | 6 | namespace SINS { 7 | 8 | struct KFState { 9 | double time = -1.0; 10 | 11 | /******* Mean ********/ 12 | Eigen::Matrix kf_state; 13 | 14 | // AVP error. 15 | Eigen::Vector3d att_err() { return kf_state.block(kAttErrIdx, 0); } 16 | Eigen::Vector3d vel_err() { return kf_state.block(kVelErrIdx, 0); } 17 | Eigen::Vector3d pos_err() { return kf_state.block(kPosErrIdx, 0); } 18 | 19 | // IMU bias error. 20 | Eigen::Vector3d gyro_bias_err() { return kf_state.block(kGyroBiasErrIdx, 0); } 21 | Eigen::Vector3d acc_bias_err() { return kf_state.block(kAccBiasErrIdx, 0); } 22 | 23 | // GNSS extrinsic. 24 | Eigen::Vector3d gnss_arm() { return kf_state.block(kGnssArmIdx, 0); } 25 | 26 | /******* Covariance ********/ 27 | KFMat cov; 28 | }; 29 | 30 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/Earth/EarthModel.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | namespace SINS { 8 | 9 | class EarthModel { 10 | public: 11 | struct EarthParam { 12 | // Default: WGS84. 13 | double f = 1.0 / 298.257223563; // 扁率. 14 | double Re = 6378137; // 半长轴 15 | double wie = 7.2921151467e-5; // Earth rotation rate [rad/s] 16 | double e2 = f * (2.0 - f); 17 | double e = std::sqrt(e2); 18 | double g0 = 9.7803267714; 19 | }; 20 | 21 | public: 22 | EarthModel() : EarthModel(EarthParam()) { } 23 | explicit EarthModel(const EarthParam ¶m); 24 | 25 | // Singleton. 26 | static EarthModel *Instance() { 27 | static EarthModel earth_mode; 28 | return &earth_mode; 29 | } 30 | 31 | void SetEarthParam(const EarthParam ¶m) { 32 | param_ = param; 33 | } 34 | 35 | void GetRmRn(double latitude, double *Rm, double *Rn); 36 | Eigen::Vector3d GetGravity(double latitude, double hight = 0); 37 | Eigen::Vector3d GetWnie(double latitude); 38 | double Getwie(); 39 | static Eigen::Vector3d GetWnen(double east_vel, double north_vel, double latitude, double height, double Rm, double Rn); 40 | 41 | private: 42 | EarthParam param_; 43 | }; 44 | 45 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/ErrorModel/ErrorModel.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include "Base/Index.h" 6 | #include "Base/InsState.h" 7 | 8 | namespace SINS { 9 | 10 | class ErrorModel { 11 | public: 12 | static KFMat ComputeFMatrix(const InsState &ins_state); 13 | static KFMat ComputePhiMatrix(const InsState &ins_state); 14 | static Eigen::Matrix ComputeGMatrix(const InsState &ins_state); 15 | }; 16 | 17 | Eigen::Matrix3d ComputeMpv(double Rmh, double Rnh, double latitude); 18 | 19 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/InsUpdate/InsUpdater.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "Earth/EarthModel.h" 4 | #include "Base/InsState.h" 5 | 6 | namespace SINS { 7 | 8 | class InsUpdater { 9 | public: 10 | /******* Main Update Interface ********/ 11 | static void UpdateInsState(double time, 12 | const Eigen::Vector3d &delta_theta1, const Eigen::Vector3d &delta_theta2, 13 | const Eigen::Vector3d &delta_v1, const Eigen::Vector3d &delta_v2, 14 | InsState *ins_state, 15 | bool fix_height = false); 16 | 17 | static void UpdateEarthParams(InsState *ins_state); 18 | 19 | static void UpdateEarthParams(double latitude, double height, double east_vel, double north_vel, InsState *ins_state); 20 | 21 | private: 22 | /*** Single Update ***/ 23 | static void UpdateOrientation(double delta_t, 24 | const Eigen::Vector3d &delta_theta1, const Eigen::Vector3d &delta_theta2, 25 | InsState *ins_state); 26 | 27 | static void UpdateVelocity(double delta_t, 28 | const Eigen::Vector3d &delta_theta1, const Eigen::Vector3d &delta_theta2, 29 | const Eigen::Vector3d &delta_v1, const Eigen::Vector3d &delta_v2, 30 | InsState *ins_state); 31 | 32 | static void UpdatePosition(double delta_t, const Eigen::Vector3d &vel_m_1, InsState *ins_state); 33 | }; 34 | 35 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/KFSystem/KFSystem.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | namespace SINS { 9 | 10 | class KFSystem { 11 | public: 12 | KFSystem(double angle_random_walk, double vel_random_walk); 13 | 14 | bool ProcessImu(const ImuData::ConstPtr imu1, const ImuData::ConstPtr imu2, InsState *ins_state, KFState *kf_State); 15 | bool ProcessGnss(const GnssData::ConstPtr gnss_data, InsState *ins_state, KFState *kf_state); 16 | 17 | private: 18 | Eigen::Matrix imu_noise_; 19 | }; 20 | 21 | } // namespace -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/MeasureModel/Measurements.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "Base/InsState.h" 4 | #include "Base/Index.h" 5 | #include "Base/KFState.h" 6 | 7 | namespace SINS { 8 | 9 | class Measurements { 10 | public: 11 | static bool ComputePostionMeasurement(const InsState &ins_state, 12 | const Eigen::Matrix3d &Mpv, 13 | const Eigen::Vector3d &lever_arm, 14 | const Eigen::Vector3d &measure_pos, 15 | Eigen::Vector3d *zk, 16 | Eigen::Matrix *H_wrt_kf_state, 17 | Eigen::Matrix3d *H_wrt_lever_arm) ; 18 | 19 | static bool ComputeVelocityMeasurement(const InsState &ins_state, 20 | const Eigen::Vector3d &lever_arm, 21 | const Eigen::Vector3d &measure_vel, 22 | Eigen::Vector3d *zk, 23 | Eigen::Matrix *H_wrt_kf_state, 24 | Eigen::Matrix3d *H_wrt_lever_arm); 25 | 26 | }; 27 | 28 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/Utils/TimeConverter.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | namespace SINS { 4 | 5 | /// Copy from apollo 6 | class TimeUtil { 7 | public: 8 | // @brief: UNIX timestamp to GPS timestamp, in seconds. 9 | static double Unix2Gps(double unix_time) { 10 | double gps_time = unix_time - UNIX_GPS_DIFF; 11 | if (unix_time < LEAP_SECOND_TIMESTAMP) { 12 | gps_time -= 1.0; 13 | } 14 | return gps_time; 15 | } 16 | 17 | // @brief: GPS timestamp to UNIX timestamp, in seconds. 18 | static double Gps2Unix(double gps_time) { 19 | double unix_time = gps_time + UNIX_GPS_DIFF; 20 | if (unix_time + 1 < LEAP_SECOND_TIMESTAMP) { 21 | unix_time += 1.0; 22 | } 23 | return unix_time; 24 | } 25 | 26 | private: 27 | // unix timestamp(1970.01.01) is different from gps timestamp(1980.01.06) 28 | static const int UNIX_GPS_DIFF = 315964782; 29 | // unix timestamp(2016.12.31 23:59:59(60) UTC/GMT) 30 | static const int LEAP_SECOND_TIMESTAMP = 1483228799; 31 | }; 32 | 33 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Core/Utils/Utils.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace SINS { 6 | 7 | constexpr double kDegToRad = M_PI / 180.0; 8 | constexpr double kRadToDeg = 180.0 / M_PI; 9 | 10 | inline Eigen::Matrix3d SkewMat(const Eigen::Vector3d &v) { 11 | Eigen::Matrix3d skew_mat; 12 | 13 | skew_mat << 0.0, -v.z(), v.y(), 14 | v.z(), 0.0, -v.x(), 15 | -v.y(), v.x(), 0.0; 16 | 17 | return skew_mat; 18 | } 19 | 20 | inline double sec(double theta) { 21 | return 1. / std::cos(theta); 22 | } 23 | 24 | } // namespace SINS -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Data/.DS_Store: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/app/SINS/Data/.DS_Store -------------------------------------------------------------------------------- /TinyGrapeKit/app/SINS/Examples/StationaryCoarseAlignmentExample.cpp: -------------------------------------------------------------------------------- 1 | #include "Alignment/StationaryCoarseAlignment.h" 2 | #include "Utils/SO3.h" 3 | 4 | #include 5 | 6 | using namespace SINS; 7 | 8 | int main(int argc, char **argv) { 9 | // Start. 10 | // const Eigen::Vector3d gyro(4.85072550613717e-07, -2.57168325026221e-07, 4.78749072084102e-07); 11 | // const Eigen::Vector3d acc(-0.00220864776504132, -0.000983490241384058, 0.0980537484095091); 12 | 13 | // End. 14 | const Eigen::Vector3d gyro(-5.17745291091245e-07, 2.09718176638119e-07, 4.59047968234761e-07); 15 | const Eigen::Vector3d acc(-0.00230025125136539, -7.95820184872582e-06, 0.0980495373619216); 16 | 17 | Eigen::Matrix3d C_nb = SINS::StationaryCoarseAlign(acc, gyro); // 18 | const Eigen::Vector3d euler_nb = MatToAtt(C_nb); 19 | 20 | constexpr double kRadToDeg = 180. / M_PI; 21 | std::cout << "C_nb:\n" << std::fixed << C_nb << std::endl << std::endl << std::endl; 22 | std::cout << "euler_nb: " << std::fixed << euler_nb.transpose() * kRadToDeg << std::endl << std::endl; 23 | 24 | double latitude = SINS::ComputeLatitude(acc, gyro); 25 | std::cout << "Latitude: " << std::fixed << latitude * kRadToDeg << std::endl; 26 | 27 | return EXIT_SUCCESS; 28 | } -------------------------------------------------------------------------------- /TinyGrapeKit/build.sh: -------------------------------------------------------------------------------- 1 | ## Build third party -- Pangolin 2 | cd third_party 3 | cd Pangolin 4 | rm -rf build 5 | mkdir build 6 | cd build 7 | cmake -DCMAKE_BUILD_TYPE=Release .. 8 | make -j8 9 | 10 | ## Build third party -- GeographicLib 11 | cd ../../ 12 | cd GeographicLib 13 | rm -rf build 14 | mkdir build 15 | cd build 16 | cmake -DCMAKE_BUILD_TYPE=Release .. 17 | make -j8 18 | 19 | ## Build TinyGrapeKit library. 20 | cd ../../../ 21 | cd library 22 | rm -rf build 23 | mkdir build 24 | cd build 25 | cmake -DCMAKE_BUILD_TYPE=Release .. 26 | make install -j8 27 | 28 | ## Build FilterFusion 29 | cd ../../ 30 | cd app/FilterFusion 31 | rm -rf build 32 | mkdir build 33 | cd build 34 | cmake -DCMAKE_BUILD_TYPE=Release .. 35 | make -j8 -------------------------------------------------------------------------------- /TinyGrapeKit/library/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 2.8.8) 2 | project(TinyGrapeKit) 3 | 4 | # Set C++14 5 | add_compile_options(-std=c++14) 6 | 7 | # Set cmake 8 | set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_SOURCE_DIR}/cmake) 9 | 10 | # Third party dependencies 11 | find_package(Eigen3 REQUIRED) 12 | include_directories(${EIGEN3_INCLUDE_DIR}) 13 | find_package(Glog REQUIRED) 14 | include_directories(${GLOG_INCLUDE_DIR}) 15 | find_package(OpenCV 3 REQUIRED) 16 | include_directories(${OpenCV_INCLUDE_DIRS} ${OpenCV_INCLUDE_DIRS}/opencv4) 17 | find_package(Ceres REQUIRED) 18 | include_directories(${CERES_INCLUDE_DIRS}) 19 | 20 | include_directories(include) 21 | # Make library 22 | file(GLOB_RECURSE ALL_HEADER_FILES 23 | ${PROJECT_SOURCE_DIR}/include/*.h 24 | ) 25 | file(GLOB_RECURSE ALL_SRC_FILES 26 | ${PROJECT_SOURCE_DIR}/src/*.cpp 27 | ) 28 | 29 | add_library(${PROJECT_NAME} SHARED ${ALL_SRC_FILES}) 30 | target_link_libraries(${PROJECT_NAME} ${OpenCV_LIBS} ${CERES_LIBRARIES}) 31 | 32 | # install 33 | set(CMAKE_INSTALL_PREFIX ${CMAKE_SOURCE_DIR}/install) 34 | install(TARGETS ${PROJECT_NAME} 35 | LIBRARY DESTINATION lib 36 | RUNTIME DESTINATION bin 37 | ) 38 | 39 | install( 40 | DIRECTORY include/ 41 | DESTINATION include/TGK 42 | ) 43 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/3.12.2/CMakeDetermineCompilerABI_C.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/3.12.2/CMakeDetermineCompilerABI_C.bin -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/3.12.2/CMakeDetermineCompilerABI_CXX.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/3.12.2/CMakeDetermineCompilerABI_CXX.bin -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/3.12.2/CMakeSystem.cmake: -------------------------------------------------------------------------------- 1 | set(CMAKE_HOST_SYSTEM "Linux-4.15.0-142-generic") 2 | set(CMAKE_HOST_SYSTEM_NAME "Linux") 3 | set(CMAKE_HOST_SYSTEM_VERSION "4.15.0-142-generic") 4 | set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64") 5 | 6 | 7 | 8 | set(CMAKE_SYSTEM "Linux-4.15.0-142-generic") 9 | set(CMAKE_SYSTEM_NAME "Linux") 10 | set(CMAKE_SYSTEM_VERSION "4.15.0-142-generic") 11 | set(CMAKE_SYSTEM_PROCESSOR "x86_64") 12 | 13 | set(CMAKE_CROSSCOMPILING "FALSE") 14 | 15 | set(CMAKE_SYSTEM_LOADED 1) 16 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/3.12.2/CompilerIdC/a.out: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/3.12.2/CompilerIdC/a.out -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/3.12.2/CompilerIdCXX/a.out: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/3.12.2/CompilerIdCXX/a.out -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/CMakeDirectoryInformation.cmake: -------------------------------------------------------------------------------- 1 | # CMAKE generated file: DO NOT EDIT! 2 | # Generated by "Unix Makefiles" Generator, CMake Version 3.12 3 | 4 | # Relative path conversion top directories. 5 | set(CMAKE_RELATIVE_PATH_TOP_SOURCE "/home/touchair/gnss_ws/src/TinyGrapeKit/library") 6 | set(CMAKE_RELATIVE_PATH_TOP_BINARY "/home/touchair/gnss_ws/src/TinyGrapeKit/library/build") 7 | 8 | # Force unix paths in dependencies. 9 | set(CMAKE_FORCE_UNIX_PATHS 1) 10 | 11 | 12 | # The C and CXX include file regular expressions for this directory. 13 | set(CMAKE_C_INCLUDE_REGEX_SCAN "^.*$") 14 | set(CMAKE_C_INCLUDE_REGEX_COMPLAIN "^$") 15 | set(CMAKE_CXX_INCLUDE_REGEX_SCAN ${CMAKE_C_INCLUDE_REGEX_SCAN}) 16 | set(CMAKE_CXX_INCLUDE_REGEX_COMPLAIN ${CMAKE_C_INCLUDE_REGEX_COMPLAIN}) 17 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TargetDirectories.txt: -------------------------------------------------------------------------------- 1 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/build/CMakeFiles/install/strip.dir 2 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/build/CMakeFiles/install/local.dir 3 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/build/CMakeFiles/edit_cache.dir 4 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/build/CMakeFiles/rebuild_cache.dir 5 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir 6 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/build/CMakeFiles/list_install_components.dir 7 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/build/CMakeFiles/install.dir 8 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/cmake_clean.cmake: -------------------------------------------------------------------------------- 1 | file(REMOVE_RECURSE 2 | "CMakeFiles/TinyGrapeKit.dir/src/FeatureTracker.cpp.o" 3 | "CMakeFiles/TinyGrapeKit.dir/src/KLTFeatureTracker.cpp.o" 4 | "CMakeFiles/TinyGrapeKit.dir/src/PinholeRanTanCamera.cpp.o" 5 | "CMakeFiles/TinyGrapeKit.dir/src/SimFeatureTracker.cpp.o" 6 | "CMakeFiles/TinyGrapeKit.dir/src/Triangulator.cpp.o" 7 | "CMakeFiles/TinyGrapeKit.dir/src/TriangulatorUtil.cpp.o" 8 | "CMakeFiles/TinyGrapeKit.dir/src/VisualWheelCircleSim.cpp.o" 9 | "CMakeFiles/TinyGrapeKit.dir/src/WheelImageSynchronizer.cpp.o" 10 | "CMakeFiles/TinyGrapeKit.dir/src/WheelPropagator.cpp.o" 11 | "libTinyGrapeKit.pdb" 12 | "libTinyGrapeKit.so" 13 | ) 14 | 15 | # Per-language clean rules from dependency scanning. 16 | foreach(lang CXX) 17 | include(CMakeFiles/TinyGrapeKit.dir/cmake_clean_${lang}.cmake OPTIONAL) 18 | endforeach() 19 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/flags.make: -------------------------------------------------------------------------------- 1 | # CMAKE generated file: DO NOT EDIT! 2 | # Generated by "Unix Makefiles" Generator, CMake Version 3.12 3 | 4 | # compile CXX with /usr/bin/g++-9 5 | CXX_FLAGS = -O3 -DNDEBUG -fPIC -std=c++14 6 | 7 | CXX_DEFINES = -DGFLAGS_IS_A_DLL=0 -DTinyGrapeKit_EXPORTS 8 | 9 | CXX_INCLUDES = -I/usr/local/include/eigen3 -I/opt/ros/kinetic/include/opencv-3.3.1-dev/opencv/opencv4 -I/home/touchair/gnss_ws/src/TinyGrapeKit/library/include -isystem /opt/ros/kinetic/include/opencv-3.3.1-dev -isystem /opt/ros/kinetic/include/opencv-3.3.1-dev/opencv -isystem /usr/local/include 10 | 11 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/progress.make: -------------------------------------------------------------------------------- 1 | CMAKE_PROGRESS_1 = 1 2 | CMAKE_PROGRESS_2 = 2 3 | CMAKE_PROGRESS_3 = 3 4 | CMAKE_PROGRESS_4 = 4 5 | CMAKE_PROGRESS_5 = 5 6 | CMAKE_PROGRESS_6 = 6 7 | CMAKE_PROGRESS_7 = 7 8 | CMAKE_PROGRESS_8 = 8 9 | CMAKE_PROGRESS_9 = 9 10 | CMAKE_PROGRESS_10 = 10 11 | 12 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/FeatureTracker.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/FeatureTracker.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/KLTFeatureTracker.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/KLTFeatureTracker.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/PinholeRanTanCamera.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/PinholeRanTanCamera.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/SimFeatureTracker.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/SimFeatureTracker.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/Triangulator.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/Triangulator.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/TriangulatorUtil.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/TriangulatorUtil.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/VisualWheelCircleSim.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/VisualWheelCircleSim.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/WheelImageSynchronizer.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/WheelImageSynchronizer.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/WheelPropagator.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/TinyGrapeKit.dir/src/WheelPropagator.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/cmake.check_cache: -------------------------------------------------------------------------------- 1 | # This file is generated by cmake for dependency checking of the CMakeCache.txt file 2 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/feature_tests.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/CMakeFiles/feature_tests.bin -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/feature_tests.c: -------------------------------------------------------------------------------- 1 | 2 | const char features[] = {"\n" 3 | "C_FEATURE:" 4 | #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 304 5 | "1" 6 | #else 7 | "0" 8 | #endif 9 | "c_function_prototypes\n" 10 | "C_FEATURE:" 11 | #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 304 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L 12 | "1" 13 | #else 14 | "0" 15 | #endif 16 | "c_restrict\n" 17 | "C_FEATURE:" 18 | #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 406 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201000L 19 | "1" 20 | #else 21 | "0" 22 | #endif 23 | "c_static_assert\n" 24 | "C_FEATURE:" 25 | #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 304 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L 26 | "1" 27 | #else 28 | "0" 29 | #endif 30 | "c_variadic_macros\n" 31 | 32 | }; 33 | 34 | int main(int argc, char** argv) { (void)argv; return features[argc]; } 35 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/CMakeFiles/progress.marks: -------------------------------------------------------------------------------- 1 | 10 2 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/install_manifest.txt: -------------------------------------------------------------------------------- 1 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/lib/libTinyGrapeKit.so 2 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/Camera/Camera.h 3 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/Camera/PinholeRanTanCamera.h 4 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/Geometry/Triangulator.h 5 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/Geometry/TriangulatorUtil.h 6 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/Simulation/VisualWheelCircleSim.h 7 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/BaseType/Measurement.h 8 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/WheelProcessor/WheelPropagator.h 9 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/ImageProcessor/KLTFeatureTracker.h 10 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/ImageProcessor/SimFeatureTracker.h 11 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/ImageProcessor/FeatureTracker.h 12 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/DataSynchronizer/DataSynchronizerUtil.h 13 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/DataSynchronizer/WheelImageSynchronizer.h 14 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/Const/Const.h 15 | /home/touchair/gnss_ws/src/TinyGrapeKit/library/install/include/TGK/Util/Util.h -------------------------------------------------------------------------------- /TinyGrapeKit/library/build/libTinyGrapeKit.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/build/libTinyGrapeKit.so -------------------------------------------------------------------------------- /TinyGrapeKit/library/cmake/FindGlog.cmake: -------------------------------------------------------------------------------- 1 | # The following variables are optionally searched for defaults 2 | # GLOG_ROOT_DIR: Base directory where all GLOG components are found 3 | # 4 | # The following are set after configuration is done: 5 | # GLOG_FOUND 6 | # GLOG_INCLUDE_DIRS 7 | # GLOG_LIBRARIES 8 | 9 | include(FindPackageHandleStandardArgs) 10 | 11 | set(GLOG_ROOT_DIR "" CACHE PATH "Folder contains Google glog") 12 | 13 | if(WIN32) 14 | find_path(GLOG_INCLUDE_DIR glog/logging.h 15 | PATHS ${GLOG_ROOT_DIR}/src/windows) 16 | else() 17 | find_path(GLOG_INCLUDE_DIR glog/logging.h 18 | PATHS ${GLOG_ROOT_DIR}) 19 | endif() 20 | 21 | if(MSVC) 22 | find_library(GLOG_LIBRARY_RELEASE libglog_static 23 | PATHS ${GLOG_ROOT_DIR} 24 | PATH_SUFFIXES Release) 25 | 26 | find_library(GLOG_LIBRARY_DEBUG libglog_static 27 | PATHS ${GLOG_ROOT_DIR} 28 | PATH_SUFFIXES Debug) 29 | 30 | set(GLOG_LIBRARY optimized ${GLOG_LIBRARY_RELEASE} debug ${GLOG_LIBRARY_DEBUG}) 31 | else() 32 | find_library(GLOG_LIBRARY glog 33 | PATHS ${GLOG_ROOT_DIR} 34 | PATH_SUFFIXES 35 | lib 36 | lib64) 37 | endif() 38 | 39 | find_package_handle_standard_args(GLOG DEFAULT_MSG 40 | GLOG_INCLUDE_DIR GLOG_LIBRARY) 41 | 42 | if(GLOG_FOUND) 43 | set(GLOG_INCLUDE_DIRS ${GLOG_INCLUDE_DIR}) 44 | set(GLOG_LIBRARIES ${GLOG_LIBRARY}) 45 | endif() 46 | -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/Camera/Camera.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | namespace TGK { 8 | namespace Camera { 9 | 10 | class Camera { 11 | public: 12 | Camera(const int width, const int height) : width_(width), height_(height) { } 13 | 14 | virtual bool CameraToImage(const Eigen::Vector3d& C_p, Eigen::Vector2d* I_p, 15 | Eigen::Matrix* J_Ip_wrt_Cp = nullptr) const = 0; 16 | 17 | virtual bool NSPToImage(const Eigen::Vector2d& NSP_p, Eigen::Vector2d* I_p, 18 | Eigen::Matrix2d* J_Ip_wrt_NSP = nullptr) const = 0; 19 | 20 | virtual Eigen::Vector3d ImageToCamera(const Eigen::Vector2d& I_p, const double z = 1.) const = 0; 21 | 22 | inline bool InImage(const int u, const int v, const int u_edge = 0, const int v_edge = 0) const { 23 | if (u < u_edge || v < v_edge || u >= (width_ - u_edge) || v >= (height_ - v_edge)) { 24 | return false; 25 | } 26 | return true; 27 | } 28 | 29 | inline bool InImage(const Eigen::Vector2d& I_p) const { 30 | return InImage(I_p[0], I_p[1]); 31 | } 32 | 33 | inline int width() { return width_; } 34 | inline int height() { return height_; } 35 | 36 | protected: 37 | int width_; 38 | int height_; 39 | }; 40 | 41 | using CameraPtr = std::shared_ptr; 42 | 43 | } // namespace Camera 44 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/Const/Const.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | constexpr double kDeg2Rad = M_PI / 180.; 6 | constexpr double kRad2Deg = 180. / M_PI; -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/DataSynchronizer/WheelImageSynchronizer.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace TGK { 6 | namespace DataSynchronizer { 7 | 8 | class WheelImageSynchronizer { 9 | public: 10 | WheelImageSynchronizer(const int max_wheel_buffer_length = 1000, 11 | const int max_image_buffer_length = 10); 12 | 13 | bool FeedWheelData(const BaseType::WheelDataConstPtr& wheel_data, 14 | std::vector* wheel_data_vec, 15 | BaseType::MonoImageDataConstPtr* mono_image_data); 16 | 17 | void FeedMonoImageData(const BaseType::MonoImageDataConstPtr& mono_image_data); 18 | 19 | private: 20 | int max_wheel_buffer_length_; 21 | int max_image_buffer_length_; 22 | double last_image_timestamp_; 23 | 24 | std::deque wheel_buffer_; 25 | std::deque image_buffer_; 26 | }; 27 | 28 | } // namespace DataSynchronizer 29 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/Geometry/Triangulator.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | namespace TGK { 7 | namespace Geometry { 8 | 9 | class Triangulator { 10 | public: 11 | struct Config { 12 | double max_proj_res = 3.; 13 | double min_dist = 0.1; 14 | double max_dist = 50.; 15 | }; 16 | 17 | Triangulator(const Config& config, const Camera::CameraPtr camera); 18 | 19 | bool Triangulate(const std::vector& G_R_Cs, 20 | const std::vector& G_p_Cs, 21 | const std::vector& im_pts, 22 | Eigen::Vector3d* G_p); 23 | 24 | private: 25 | Camera::CameraPtr camera_; 26 | Config config_; 27 | }; 28 | 29 | } // namespace Geometry 30 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/Geometry/TriangulatorUtil.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | #include 7 | 8 | namespace TGK { 9 | namespace Geometry { 10 | 11 | bool TriangulateDLT(const std::vector& C_R_Gs, 12 | const std::vector& C_p_Gs, 13 | const std::vector& NSP_points, 14 | Eigen::Vector3d* G_p); 15 | 16 | bool RefineGlobalPoint(const Camera::CameraPtr camera, 17 | const std::vector& C_R_Gs, 18 | const std::vector& C_p_Gs, 19 | const std::vector& im_points, 20 | Eigen::Vector3d* G_p); 21 | 22 | } // namespace Geometry 23 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/ImageProcessor/FeatureTracker.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | namespace TGK { 7 | namespace ImageProcessor { 8 | 9 | class FeatureTracker { 10 | public: 11 | FeatureTracker(); 12 | virtual ~FeatureTracker() { } 13 | 14 | virtual void TrackImage(const cv::Mat& image, 15 | std::vector* tracked_pts, 16 | std::vector* tracked_pt_ids, 17 | std::vector* lost_pt_ids = nullptr, 18 | std::set* new_pt_ids = nullptr) = 0; 19 | 20 | virtual void DeleteFeature(const long int pt_id) = 0; 21 | 22 | protected: 23 | static long int corner_id_; 24 | }; 25 | 26 | } // namespace ImageProcessor 27 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/ImageProcessor/KLTFeatureTracker.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | #include 7 | 8 | #include 9 | 10 | namespace TGK { 11 | namespace ImageProcessor { 12 | 13 | class KLTFeatureTracker : public FeatureTracker { 14 | public: 15 | struct Config { 16 | int max_num_corners = 100; 17 | double quality_level = 0.01; 18 | double min_dist = 40.; 19 | }; 20 | 21 | KLTFeatureTracker(const Config& config); 22 | 23 | virtual void TrackImage(const cv::Mat& image, 24 | std::vector* tracked_pts, 25 | std::vector* tracked_pt_ids, 26 | std::vector* lost_pt_ids = nullptr, 27 | std::set* new_pt_ids = nullptr); 28 | 29 | virtual void DeleteFeature(const long int pt_id); 30 | 31 | private: 32 | void CreateMask(const int width, const int heigth, const std::vector& points, cv::Mat* mask); 33 | 34 | Config config_; 35 | cv::Mat last_image_; 36 | std::vector last_cv_pts_; 37 | std::vector last_pt_ids_; 38 | }; 39 | 40 | } // namespace ImageProcessor 41 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/ImageProcessor/SimFeatureTracker.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | #include 6 | 7 | #include 8 | 9 | namespace TGK { 10 | namespace ImageProcessor { 11 | 12 | class SimFeatureTrakcer { 13 | public: 14 | SimFeatureTrakcer(); 15 | 16 | void TrackSimFrame(const std::vector& sim_features, const std::vector sim_feature_ids, 17 | std::vector* tracked_pts, 18 | std::vector* tracked_pt_ids, 19 | std::vector* lost_pt_ids = nullptr, 20 | std::set* new_pt_ids = nullptr); 21 | 22 | virtual void DeleteFeature(const long int ft_id); 23 | 24 | private: 25 | std::unordered_map last_features_; 26 | }; 27 | 28 | } // namespace ImageProcessor 29 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/Util/Util.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace TGK { 6 | namespace Util { 7 | 8 | inline Eigen::Matrix3d Skew(const Eigen::Vector3d& v) { 9 | Eigen::Matrix3d w; 10 | w << 0., -v(2), v(1), 11 | v(2), 0., -v(0), 12 | -v(1), v(0), 0.; 13 | return w; 14 | } 15 | 16 | } // namespace Util 17 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/include/WheelProcessor/WheelPropagator.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace TGK { 6 | namespace WheelProcessor { 7 | 8 | class WheelPropagator { 9 | public: 10 | WheelPropagator(const double kl, const double kr, const double b, 11 | const double noise_factor = 0.02, 12 | const double roll_pitch_noise = 1e-6, 13 | const double z_noise = 0.0001); 14 | 15 | void PropagateUsingEncoder(const double begin_wl, const double begin_wr, 16 | const double end_wl, const double end_wr, 17 | Eigen::Matrix3d* G_R_O, Eigen::Vector3d* G_p_O, 18 | Eigen::Matrix* J_wrt_pose = nullptr, 19 | Eigen::Matrix* cov = nullptr); 20 | 21 | private: 22 | // Intrinsic. 23 | double kl_; 24 | double kr_; 25 | double b_; 26 | 27 | // Noise. 28 | double noise_factor_; 29 | double roll_pitch_noise_; 30 | double z_noise_; 31 | }; 32 | 33 | } // namespace WheelProcessor 34 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/Camera/Camera.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | namespace TGK { 8 | namespace Camera { 9 | 10 | class Camera { 11 | public: 12 | Camera(const int width, const int height) : width_(width), height_(height) { } 13 | 14 | virtual bool CameraToImage(const Eigen::Vector3d& C_p, Eigen::Vector2d* I_p, 15 | Eigen::Matrix* J_Ip_wrt_Cp = nullptr) const = 0; 16 | 17 | virtual bool NSPToImage(const Eigen::Vector2d& NSP_p, Eigen::Vector2d* I_p, 18 | Eigen::Matrix2d* J_Ip_wrt_NSP = nullptr) const = 0; 19 | 20 | virtual Eigen::Vector3d ImageToCamera(const Eigen::Vector2d& I_p, const double z = 1.) const = 0; 21 | 22 | inline bool InImage(const int u, const int v, const int u_edge = 0, const int v_edge = 0) const { 23 | if (u < u_edge || v < v_edge || u >= (width_ - u_edge) || v >= (height_ - v_edge)) { 24 | return false; 25 | } 26 | return true; 27 | } 28 | 29 | inline bool InImage(const Eigen::Vector2d& I_p) const { 30 | return InImage(I_p[0], I_p[1]); 31 | } 32 | 33 | inline int width() { return width_; } 34 | inline int height() { return height_; } 35 | 36 | protected: 37 | int width_; 38 | int height_; 39 | }; 40 | 41 | using CameraPtr = std::shared_ptr; 42 | 43 | } // namespace Camera 44 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/Const/Const.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | constexpr double kDeg2Rad = M_PI / 180.; 6 | constexpr double kRad2Deg = 180. / M_PI; -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/DataSynchronizer/WheelImageSynchronizer.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace TGK { 6 | namespace DataSynchronizer { 7 | 8 | class WheelImageSynchronizer { 9 | public: 10 | WheelImageSynchronizer(const int max_wheel_buffer_length = 1000, 11 | const int max_image_buffer_length = 10); 12 | 13 | bool FeedWheelData(const BaseType::WheelDataConstPtr& wheel_data, 14 | std::vector* wheel_data_vec, 15 | BaseType::MonoImageDataConstPtr* mono_image_data); 16 | 17 | void FeedMonoImageData(const BaseType::MonoImageDataConstPtr& mono_image_data); 18 | 19 | private: 20 | int max_wheel_buffer_length_; 21 | int max_image_buffer_length_; 22 | double last_image_timestamp_; 23 | 24 | std::deque wheel_buffer_; 25 | std::deque image_buffer_; 26 | }; 27 | 28 | } // namespace DataSynchronizer 29 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/Geometry/Triangulator.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | namespace TGK { 7 | namespace Geometry { 8 | 9 | class Triangulator { 10 | public: 11 | struct Config { 12 | double max_proj_res = 3.; 13 | double min_dist = 0.1; 14 | double max_dist = 50.; 15 | }; 16 | 17 | Triangulator(const Config& config, const Camera::CameraPtr camera); 18 | 19 | bool Triangulate(const std::vector& G_R_Cs, 20 | const std::vector& G_p_Cs, 21 | const std::vector& im_pts, 22 | Eigen::Vector3d* G_p); 23 | 24 | private: 25 | Camera::CameraPtr camera_; 26 | Config config_; 27 | }; 28 | 29 | } // namespace Geometry 30 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/Geometry/TriangulatorUtil.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | #include 7 | 8 | namespace TGK { 9 | namespace Geometry { 10 | 11 | bool TriangulateDLT(const std::vector& C_R_Gs, 12 | const std::vector& C_p_Gs, 13 | const std::vector& NSP_points, 14 | Eigen::Vector3d* G_p); 15 | 16 | bool RefineGlobalPoint(const Camera::CameraPtr camera, 17 | const std::vector& C_R_Gs, 18 | const std::vector& C_p_Gs, 19 | const std::vector& im_points, 20 | Eigen::Vector3d* G_p); 21 | 22 | } // namespace Geometry 23 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/ImageProcessor/FeatureTracker.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | namespace TGK { 7 | namespace ImageProcessor { 8 | 9 | class FeatureTracker { 10 | public: 11 | FeatureTracker(); 12 | virtual ~FeatureTracker() { } 13 | 14 | virtual void TrackImage(const cv::Mat& image, 15 | std::vector* tracked_pts, 16 | std::vector* tracked_pt_ids, 17 | std::vector* lost_pt_ids = nullptr, 18 | std::set* new_pt_ids = nullptr) = 0; 19 | 20 | virtual void DeleteFeature(const long int pt_id) = 0; 21 | 22 | protected: 23 | static long int corner_id_; 24 | }; 25 | 26 | } // namespace ImageProcessor 27 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/ImageProcessor/KLTFeatureTracker.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | #include 7 | 8 | #include 9 | 10 | namespace TGK { 11 | namespace ImageProcessor { 12 | 13 | class KLTFeatureTracker : public FeatureTracker { 14 | public: 15 | struct Config { 16 | int max_num_corners = 100; 17 | double quality_level = 0.01; 18 | double min_dist = 40.; 19 | }; 20 | 21 | KLTFeatureTracker(const Config& config); 22 | 23 | virtual void TrackImage(const cv::Mat& image, 24 | std::vector* tracked_pts, 25 | std::vector* tracked_pt_ids, 26 | std::vector* lost_pt_ids = nullptr, 27 | std::set* new_pt_ids = nullptr); 28 | 29 | virtual void DeleteFeature(const long int pt_id); 30 | 31 | private: 32 | void CreateMask(const int width, const int heigth, const std::vector& points, cv::Mat* mask); 33 | 34 | Config config_; 35 | cv::Mat last_image_; 36 | std::vector last_cv_pts_; 37 | std::vector last_pt_ids_; 38 | }; 39 | 40 | } // namespace ImageProcessor 41 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/ImageProcessor/SimFeatureTracker.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | #include 6 | 7 | #include 8 | 9 | namespace TGK { 10 | namespace ImageProcessor { 11 | 12 | class SimFeatureTrakcer { 13 | public: 14 | SimFeatureTrakcer(); 15 | 16 | void TrackSimFrame(const std::vector& sim_features, const std::vector sim_feature_ids, 17 | std::vector* tracked_pts, 18 | std::vector* tracked_pt_ids, 19 | std::vector* lost_pt_ids = nullptr, 20 | std::set* new_pt_ids = nullptr); 21 | 22 | virtual void DeleteFeature(const long int ft_id); 23 | 24 | private: 25 | std::unordered_map last_features_; 26 | }; 27 | 28 | } // namespace ImageProcessor 29 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/Util/Util.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace TGK { 6 | namespace Util { 7 | 8 | inline Eigen::Matrix3d Skew(const Eigen::Vector3d& v) { 9 | Eigen::Matrix3d w; 10 | w << 0., -v(2), v(1), 11 | v(2), 0., -v(0), 12 | -v(1), v(0), 0.; 13 | return w; 14 | } 15 | 16 | } // namespace Util 17 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/include/TGK/WheelProcessor/WheelPropagator.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace TGK { 6 | namespace WheelProcessor { 7 | 8 | class WheelPropagator { 9 | public: 10 | WheelPropagator(const double kl, const double kr, const double b, 11 | const double noise_factor = 0.02, 12 | const double roll_pitch_noise = 1e-6, 13 | const double z_noise = 0.0001); 14 | 15 | void PropagateUsingEncoder(const double begin_wl, const double begin_wr, 16 | const double end_wl, const double end_wr, 17 | Eigen::Matrix3d* G_R_O, Eigen::Vector3d* G_p_O, 18 | Eigen::Matrix* J_wrt_pose = nullptr, 19 | Eigen::Matrix* cov = nullptr); 20 | 21 | private: 22 | // Intrinsic. 23 | double kl_; 24 | double kr_; 25 | double b_; 26 | 27 | // Noise. 28 | double noise_factor_; 29 | double roll_pitch_noise_; 30 | double z_noise_; 31 | }; 32 | 33 | } // namespace WheelProcessor 34 | } // namespace TGK -------------------------------------------------------------------------------- /TinyGrapeKit/library/install/lib/libTinyGrapeKit.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/library/install/lib/libTinyGrapeKit.so -------------------------------------------------------------------------------- /TinyGrapeKit/library/src/FeatureTracker.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | namespace TGK { 4 | namespace ImageProcessor { 5 | 6 | long int FeatureTracker::corner_id_ = 0; 7 | 8 | FeatureTracker::FeatureTracker() { } 9 | 10 | } // namespace ImageProcessor 11 | } // namespace TGK 12 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project (GeographicLib) 2 | 3 | # Version information 4 | set (PROJECT_VERSION_MAJOR 1) 5 | set (PROJECT_VERSION_MINOR 49) 6 | set (PROJECT_VERSION_PATCH 0) 7 | set (PROJECT_VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}") 8 | if (PROJECT_VERSION_PATCH GREATER 0) 9 | set (PROJECT_VERSION "${PROJECT_VERSION}.${PROJECT_VERSION_PATCH}") 10 | endif () 11 | 12 | # The library version tracks the numbering given by libtool in the 13 | # autoconf set up. 14 | set (LIBVERSION_API 17) 15 | set (LIBVERSION_BUILD 17.1.2) 16 | string (TOLOWER ${PROJECT_NAME} PROJECT_NAME_LOWER) 17 | string (TOUPPER ${PROJECT_NAME} PROJECT_NAME_UPPER) 18 | 19 | cmake_minimum_required (VERSION 2.8.4) # This version was released 2011-02-16 20 | 21 | # (7) Set the default "real" precision. This should probably be left 22 | # at 2 (double). 23 | set (GEOGRAPHICLIB_PRECISION 2 CACHE STRING 24 | "Precision: 1 = float, 2 = double, 3 = extended, 4 = quadruple, 5 = variable") 25 | set_property (CACHE GEOGRAPHICLIB_PRECISION PROPERTY STRINGS 1 2 3 4 5) 26 | 27 | 28 | set (LIBNAME Geographic) 29 | 30 | include_directories( 31 | ./include/ 32 | ) 33 | 34 | add_library(libGeographiccc SHARED src/LocalCartesian.cpp 35 | src/Geocentric.cpp 36 | src/Math.cpp) -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CMakeDetermineCompilerABI_C.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CMakeDetermineCompilerABI_C.bin -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CMakeDetermineCompilerABI_CXX.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CMakeDetermineCompilerABI_CXX.bin -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CMakeSystem.cmake: -------------------------------------------------------------------------------- 1 | set(CMAKE_HOST_SYSTEM "Linux-4.15.0-142-generic") 2 | set(CMAKE_HOST_SYSTEM_NAME "Linux") 3 | set(CMAKE_HOST_SYSTEM_VERSION "4.15.0-142-generic") 4 | set(CMAKE_HOST_SYSTEM_PROCESSOR "x86_64") 5 | 6 | 7 | 8 | set(CMAKE_SYSTEM "Linux-4.15.0-142-generic") 9 | set(CMAKE_SYSTEM_NAME "Linux") 10 | set(CMAKE_SYSTEM_VERSION "4.15.0-142-generic") 11 | set(CMAKE_SYSTEM_PROCESSOR "x86_64") 12 | 13 | set(CMAKE_CROSSCOMPILING "FALSE") 14 | 15 | set(CMAKE_SYSTEM_LOADED 1) 16 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CompilerIdC/a.out: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CompilerIdC/a.out -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CompilerIdCXX/a.out: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/3.12.2/CompilerIdCXX/a.out -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/CMakeDirectoryInformation.cmake: -------------------------------------------------------------------------------- 1 | # CMAKE generated file: DO NOT EDIT! 2 | # Generated by "Unix Makefiles" Generator, CMake Version 3.12 3 | 4 | # Relative path conversion top directories. 5 | set(CMAKE_RELATIVE_PATH_TOP_SOURCE "/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib") 6 | set(CMAKE_RELATIVE_PATH_TOP_BINARY "/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/build") 7 | 8 | # Force unix paths in dependencies. 9 | set(CMAKE_FORCE_UNIX_PATHS 1) 10 | 11 | 12 | # The C and CXX include file regular expressions for this directory. 13 | set(CMAKE_C_INCLUDE_REGEX_SCAN "^.*$") 14 | set(CMAKE_C_INCLUDE_REGEX_COMPLAIN "^$") 15 | set(CMAKE_CXX_INCLUDE_REGEX_SCAN ${CMAKE_C_INCLUDE_REGEX_SCAN}) 16 | set(CMAKE_CXX_INCLUDE_REGEX_COMPLAIN ${CMAKE_C_INCLUDE_REGEX_COMPLAIN}) 17 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/TargetDirectories.txt: -------------------------------------------------------------------------------- 1 | /home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/rebuild_cache.dir 2 | /home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir 3 | /home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/edit_cache.dir 4 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/cmake.check_cache: -------------------------------------------------------------------------------- 1 | # This file is generated by cmake for dependency checking of the CMakeCache.txt file 2 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/feature_tests.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/feature_tests.bin -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/feature_tests.c: -------------------------------------------------------------------------------- 1 | 2 | const char features[] = {"\n" 3 | "C_FEATURE:" 4 | #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 304 5 | "1" 6 | #else 7 | "0" 8 | #endif 9 | "c_function_prototypes\n" 10 | "C_FEATURE:" 11 | #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 304 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L 12 | "1" 13 | #else 14 | "0" 15 | #endif 16 | "c_restrict\n" 17 | "C_FEATURE:" 18 | #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 406 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201000L 19 | "1" 20 | #else 21 | "0" 22 | #endif 23 | "c_static_assert\n" 24 | "C_FEATURE:" 25 | #if (__GNUC__ * 100 + __GNUC_MINOR__) >= 304 && defined(__STDC_VERSION__) && __STDC_VERSION__ >= 199901L 26 | "1" 27 | #else 28 | "0" 29 | #endif 30 | "c_variadic_macros\n" 31 | 32 | }; 33 | 34 | int main(int argc, char** argv) { (void)argv; return features[argc]; } 35 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/DependInfo.cmake: -------------------------------------------------------------------------------- 1 | # The set of languages for which implicit dependencies are needed: 2 | set(CMAKE_DEPENDS_LANGUAGES 3 | "CXX" 4 | ) 5 | # The set of files for implicit dependencies of each language: 6 | set(CMAKE_DEPENDS_CHECK_CXX 7 | "/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/src/Geocentric.cpp" "/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o" 8 | "/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/src/LocalCartesian.cpp" "/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o" 9 | "/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/src/Math.cpp" "/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/Math.cpp.o" 10 | ) 11 | set(CMAKE_CXX_COMPILER_ID "GNU") 12 | 13 | # The include file search paths: 14 | set(CMAKE_CXX_TARGET_INCLUDE_PATH 15 | ".././include" 16 | ) 17 | 18 | # Targets to which this target links. 19 | set(CMAKE_TARGET_LINKED_INFO_FILES 20 | ) 21 | 22 | # Fortran module output directory. 23 | set(CMAKE_Fortran_TARGET_MODULE_DIR "") 24 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/cmake_clean.cmake: -------------------------------------------------------------------------------- 1 | file(REMOVE_RECURSE 2 | "CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o" 3 | "CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o" 4 | "CMakeFiles/libGeographiccc.dir/src/Math.cpp.o" 5 | "liblibGeographiccc.pdb" 6 | "liblibGeographiccc.so" 7 | ) 8 | 9 | # Per-language clean rules from dependency scanning. 10 | foreach(lang CXX) 11 | include(CMakeFiles/libGeographiccc.dir/cmake_clean_${lang}.cmake OPTIONAL) 12 | endforeach() 13 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/depend.internal: -------------------------------------------------------------------------------- 1 | # CMAKE generated file: DO NOT EDIT! 2 | # Generated by "Unix Makefiles" Generator, CMake Version 3.12 3 | 4 | CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o 5 | .././include/Config.h 6 | .././include/Constants.hpp 7 | .././include/Geocentric.hpp 8 | .././include/Math.hpp 9 | /home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/src/Geocentric.cpp 10 | CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o 11 | .././include/Config.h 12 | .././include/Constants.hpp 13 | .././include/Geocentric.hpp 14 | .././include/LocalCartesian.hpp 15 | .././include/Math.hpp 16 | /home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/src/LocalCartesian.cpp 17 | CMakeFiles/libGeographiccc.dir/src/Math.cpp.o 18 | .././include/Config.h 19 | .././include/Constants.hpp 20 | .././include/Math.hpp 21 | /home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/src/Math.cpp 22 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/depend.make: -------------------------------------------------------------------------------- 1 | # CMAKE generated file: DO NOT EDIT! 2 | # Generated by "Unix Makefiles" Generator, CMake Version 3.12 3 | 4 | CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o: .././include/Config.h 5 | CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o: .././include/Constants.hpp 6 | CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o: .././include/Geocentric.hpp 7 | CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o: .././include/Math.hpp 8 | CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o: ../src/Geocentric.cpp 9 | 10 | CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o: .././include/Config.h 11 | CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o: .././include/Constants.hpp 12 | CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o: .././include/Geocentric.hpp 13 | CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o: .././include/LocalCartesian.hpp 14 | CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o: .././include/Math.hpp 15 | CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o: ../src/LocalCartesian.cpp 16 | 17 | CMakeFiles/libGeographiccc.dir/src/Math.cpp.o: .././include/Config.h 18 | CMakeFiles/libGeographiccc.dir/src/Math.cpp.o: .././include/Constants.hpp 19 | CMakeFiles/libGeographiccc.dir/src/Math.cpp.o: .././include/Math.hpp 20 | CMakeFiles/libGeographiccc.dir/src/Math.cpp.o: ../src/Math.cpp 21 | 22 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/flags.make: -------------------------------------------------------------------------------- 1 | # CMAKE generated file: DO NOT EDIT! 2 | # Generated by "Unix Makefiles" Generator, CMake Version 3.12 3 | 4 | # compile CXX with /usr/bin/g++-9 5 | CXX_FLAGS = -O3 -DNDEBUG -fPIC 6 | 7 | CXX_DEFINES = -DlibGeographiccc_EXPORTS 8 | 9 | CXX_INCLUDES = -I/home/touchair/gnss_ws/src/TinyGrapeKit/third_party/GeographicLib/./include 10 | 11 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/link.txt: -------------------------------------------------------------------------------- 1 | /usr/bin/g++-9 -fPIC -O3 -DNDEBUG -shared -Wl,-soname,liblibGeographiccc.so -o liblibGeographiccc.so CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o CMakeFiles/libGeographiccc.dir/src/Math.cpp.o 2 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/progress.make: -------------------------------------------------------------------------------- 1 | CMAKE_PROGRESS_1 = 1 2 | CMAKE_PROGRESS_2 = 2 3 | CMAKE_PROGRESS_3 = 3 4 | CMAKE_PROGRESS_4 = 4 5 | 6 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/Geocentric.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/LocalCartesian.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/Math.cpp.o: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/libGeographiccc.dir/src/Math.cpp.o -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/CMakeFiles/progress.marks: -------------------------------------------------------------------------------- 1 | 4 2 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/build/liblibGeographiccc.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/GeographicLib/build/liblibGeographiccc.so -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/GeographicLib/include/Config.h: -------------------------------------------------------------------------------- 1 | // This will be overwritten by ./configure 2 | 3 | #define GEOGRAPHICLIB_VERSION_STRING "1.49" 4 | #define GEOGRAPHICLIB_VERSION_MAJOR 1 5 | #define GEOGRAPHICLIB_VERSION_MINOR 49 6 | #define GEOGRAPHICLIB_VERSION_PATCH 0 7 | 8 | // Undefine HAVE_LONG_DOUBLE if this type is unknown to the compiler 9 | #define GEOGRAPHICLIB_HAVE_LONG_DOUBLE 1 10 | 11 | // Define WORDS_BIGENDIAN to be 1 if your machine is big endian 12 | /* #undef WORDS_BIGENDIAN */ 13 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/.clang-format: -------------------------------------------------------------------------------- 1 | DisableFormat: true 2 | SortIncludes: false 3 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | CMakeLists.txt.user 3 | build* 4 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "external/pybind11"] 2 | path = external/pybind11 3 | url = https://github.com/pybind/pybind11.git 4 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/.travis.yml: -------------------------------------------------------------------------------- 1 | sudo: required 2 | dist: xenial 3 | 4 | before_install: 5 | - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt -qq update ; fi 6 | - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then sudo apt install -qq --no-install-suggests --no-install-recommends libeigen3-dev libglew-dev libc++-dev libwayland-dev libxkbcommon-dev wayland-protocols libegl1-mesa-dev; fi 7 | - if [[ "$TRAVIS_OS_NAME" == "linux" ]]; then pyenv versions && pyenv global system 3.7; fi 8 | - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew update ; fi 9 | - if [[ "$TRAVIS_OS_NAME" == "osx" ]]; then brew install eigen glew ; fi 10 | 11 | language: cpp 12 | 13 | matrix: 14 | include: 15 | - os: linux 16 | compiler: gcc 17 | env: PARALLEL_BUILD="-- -j 8" 18 | - os: linux 19 | compiler: clang 20 | env: PARALLEL_BUILD="-- -j 8" 21 | - os: osx 22 | env: PARALLEL_BUILD="-- -j 8" 23 | - os: windows 24 | env: PARALLEL_BUILD="--parallel 8" 25 | 26 | script: 27 | - mkdir build 28 | - cd build 29 | - cmake -D CMAKE_BUILD_TYPE=Release .. 30 | - cmake --build . $PARALLEL_BUILD 31 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/CreateMethodCallFile.cmake: -------------------------------------------------------------------------------- 1 | macro( CreateMethodCallFile filename namespace function symbols) 2 | file(WRITE ${filename} "// CMake generated file. Do Not Edit.\n\n#pragma once\n\nnamespace ${namespace} {\n\n") 3 | foreach( symbol ${symbols} ) 4 | file(APPEND ${filename} "void ${symbol}();\n") 5 | endforeach() 6 | file(APPEND ${filename} "\ninline bool ${function}()\n{\n") 7 | foreach( symbol ${symbols} ) 8 | file(APPEND ${filename} " ${symbol}();\n") 9 | endforeach() 10 | file(APPEND ${filename} " return true;\n}\n\n} // ${namespace}\n") 11 | endmacro() 12 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/EmbedBinaryFiles.cmake: -------------------------------------------------------------------------------- 1 | # Creates C resources file from files in given directory 2 | # Based on http://stackoverflow.com/a/27206982 3 | function(embed_binary_files file_glob output) 4 | # Collect input files 5 | file(GLOB bins ${file_glob}) 6 | # Stop when output file is newer than all binary files 7 | set(output_newer_than_bins 1) 8 | foreach(bin ${bins}) 9 | if(bin IS_NEWER_THAN output) 10 | set(output_newer_than_bins 0) 11 | break() 12 | endif() 13 | endforeach() 14 | if(output_newer_than_bins) 15 | return() 16 | endif() 17 | # Create empty output file 18 | file(WRITE ${output} "") 19 | # Iterate through input files 20 | foreach(bin ${bins}) 21 | # Get short filename 22 | string(REGEX MATCH "([^/]+)$" filename ${bin}) 23 | # Replace filename spaces & extension separator for C compatibility 24 | string(REGEX REPLACE "\\.| " "_" filename ${filename}) 25 | # Read hex data from file 26 | file(READ ${bin} filedata HEX) 27 | # Convert hex data for C compatibility 28 | string(REGEX REPLACE "([0-9a-f][0-9a-f])" "0x\\1," filedata ${filedata}) 29 | # Append data to output file 30 | file(APPEND ${output} "extern const unsigned char ${filename}[] = {${filedata}};\nextern const unsigned ${filename}_size = sizeof(${filename});\n") 31 | endforeach() 32 | endfunction() 33 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindDC1394.cmake: -------------------------------------------------------------------------------- 1 | # Try to find the dc1394 v2 lib and include files 2 | # 3 | # DC1394_INCLUDE_DIR 4 | # DC1394_LIBRARIES 5 | # DC1394_FOUND 6 | 7 | FIND_PATH( DC1394_INCLUDE_DIR dc1394/control.h 8 | /usr/include 9 | /usr/local/include 10 | ) 11 | 12 | FIND_LIBRARY( DC1394_LIBRARY dc1394 13 | /usr/lib64 14 | /usr/lib 15 | /usr/local/lib 16 | ) 17 | 18 | IF(DC1394_INCLUDE_DIR AND DC1394_LIBRARY) 19 | SET( DC1394_FOUND TRUE ) 20 | SET( DC1394_LIBRARIES ${DC1394_LIBRARY} ) 21 | ENDIF(DC1394_INCLUDE_DIR AND DC1394_LIBRARY) 22 | 23 | IF(DC1394_FOUND) 24 | IF(NOT DC1394_FIND_QUIETLY) 25 | MESSAGE(STATUS "Found DC1394: ${DC1394_LIBRARY}") 26 | ENDIF(NOT DC1394_FIND_QUIETLY) 27 | ELSE(DC1394_FOUND) 28 | IF(DC1394_FIND_REQUIRED) 29 | MESSAGE(FATAL_ERROR "Could not find libdc1394") 30 | ENDIF(DC1394_FIND_REQUIRED) 31 | ENDIF(DC1394_FOUND) 32 | 33 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindDepthSense.cmake: -------------------------------------------------------------------------------- 1 | # Try to find the DepthSense SDK For SoftKinetic Cameras 2 | # 3 | # DepthSense_INCLUDE_DIRS 4 | # DepthSense_LIBRARIES 5 | # DepthSense_FOUND 6 | 7 | FIND_PATH( DepthSense_INCLUDE_DIR DepthSense.hxx 8 | PATHS 9 | "${PROGRAM_FILES}/SoftKinetic/DepthSenseSDK/include" 10 | "${PROGRAM_FILES}/Meta/DepthSenseSDK/include" 11 | /usr/include 12 | /usr/local/include 13 | /opt/local/include 14 | /opt/softkinetic/DepthSenseSDK/include 15 | ) 16 | 17 | FIND_LIBRARY( DepthSense_LIBRARY DepthSense 18 | PATHS 19 | "${PROGRAM_FILES}/SoftKinetic/DepthSenseSDK/lib" 20 | "${PROGRAM_FILES}/Meta/DepthSenseSDK/lib" 21 | /usr/lib64 22 | /usr/lib 23 | /usr/local/lib 24 | /opt/local/lib 25 | /opt/softkinetic/DepthSenseSDK/lib 26 | ) 27 | 28 | IF(DepthSense_INCLUDE_DIR AND DepthSense_LIBRARY) 29 | SET( DepthSense_FOUND TRUE ) 30 | SET( DepthSense_LIBRARIES ${DepthSense_LIBRARY} ) 31 | SET( DepthSense_INCLUDE_DIRS ${DepthSense_INCLUDE_DIR} ) 32 | ENDIF() 33 | 34 | IF(DepthSense_FOUND) 35 | IF(NOT DepthSense_FIND_QUIETLY) 36 | MESSAGE(STATUS "Found DepthSense: ${DepthSense_LIBRARY}") 37 | ENDIF() 38 | ELSE() 39 | IF(DepthSense_FIND_REQUIRED) 40 | MESSAGE(FATAL_ERROR "Could not find DepthSense") 41 | ENDIF() 42 | ENDIF() 43 | 44 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindFREEGLUT.cmake: -------------------------------------------------------------------------------- 1 | # Try to find the FREEGLUT library 2 | # 3 | # FREEGLUT_INCLUDE_DIR 4 | # FREEGLUT_LIBRARY 5 | # FREEGLUT_FOUND 6 | 7 | FIND_PATH( 8 | FREEGLUT_INCLUDE_DIR GL/freeglut.h 9 | ${CMAKE_INCLUDE_PATH} 10 | $ENV{include} 11 | ${OPENGL_INCLUDE_DIR} 12 | /usr/include 13 | /usr/local/include 14 | ) 15 | 16 | SET(STORE_CMAKE_FIND_FRAMEWORK ${CMAKE_FIND_FRAMEWORK}) 17 | SET(CMAKE_FIND_FRAMEWORK NEVER) 18 | 19 | FIND_LIBRARY( 20 | FREEGLUT_LIBRARY 21 | NAMES freeglut_static freeglut glut 22 | PATH 23 | /opt/local/lib 24 | ${CMAKE_LIBRARY_PATH} 25 | $ENV{lib} 26 | /usr/lib 27 | /usr/local/lib 28 | ) 29 | 30 | SET(CMAKE_FIND_FRAMEWORK ${STORE_CMAKE_FIND_FRAMEWORK}) 31 | 32 | IF (FREEGLUT_INCLUDE_DIR AND FREEGLUT_LIBRARY) 33 | SET(FREEGLUT_FOUND TRUE) 34 | ENDIF (FREEGLUT_INCLUDE_DIR AND FREEGLUT_LIBRARY) 35 | 36 | IF (FREEGLUT_FOUND) 37 | IF (NOT FREEGLUT_FIND_QUIETLY) 38 | MESSAGE(STATUS "Found FREEGLUT: ${FREEGLUT_LIBRARY}") 39 | ENDIF (NOT FREEGLUT_FIND_QUIETLY) 40 | ELSE (FREEGLUT_FOUND) 41 | IF (FREEGLUT_FIND_REQUIRED) 42 | MESSAGE(FATAL_ERROR "Could not find FREEGLUT") 43 | ENDIF (FREEGLUT_FIND_REQUIRED) 44 | ENDIF (FREEGLUT_FOUND) 45 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindGLUES.cmake: -------------------------------------------------------------------------------- 1 | # Try to find the GLUES lib and include files 2 | # 3 | # GLUES_INCLUDE_DIR 4 | # GLUES_LIBRARIES 5 | # GLUES_FOUND 6 | 7 | FIND_PATH( GLUES_INCLUDE_DIR glues/glues.h 8 | /usr/include 9 | /usr/local/include 10 | /opt/include 11 | /opt/local/include 12 | ${CMAKE_INSTALL_PREFIX}/include 13 | ) 14 | 15 | FIND_LIBRARY( GLUES_LIBRARY glues 16 | /usr/lib64 17 | /usr/lib 18 | /usr/local/lib 19 | /opt/local/lib 20 | /opt/local/lib64 21 | ${CMAKE_INSTALL_PREFIX}/lib 22 | ) 23 | 24 | IF(GLUES_INCLUDE_DIR AND GLUES_LIBRARY) 25 | SET( GLUES_FOUND TRUE ) 26 | SET( GLUES_LIBRARIES ${GLUES_LIBRARY} ) 27 | ENDIF(GLUES_INCLUDE_DIR AND GLUES_LIBRARY) 28 | 29 | IF(GLUES_FOUND) 30 | IF(NOT GLUES_FIND_QUIETLY) 31 | MESSAGE(STATUS "Found GLUES: ${GLUES_LIBRARY}") 32 | ENDIF(NOT GLUES_FIND_QUIETLY) 33 | ELSE(GLUES_FOUND) 34 | IF(GLUES_FIND_REQUIRED) 35 | MESSAGE(FATAL_ERROR "Could not find GLUES") 36 | ENDIF(GLUES_FIND_REQUIRED) 37 | ENDIF(GLUES_FOUND) 38 | 39 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindLibRealSense.cmake: -------------------------------------------------------------------------------- 1 | # -*- mode: cmake; -*- 2 | ############################################################################### 3 | # Find librealsense https://github.com/IntelRealSense/librealsense 4 | # 5 | # This sets the following variables: 6 | # LIBREALSENSE_FOUND - True if OPENNI was found. 7 | # LIBREALSENSE_INCLUDE_DIRS - Directories containing the OPENNI include files. 8 | # LIBREALSENSE_LIBRARIES - Libraries needed to use OPENNI. 9 | # LIBREALSENSE_DEFINITIONS - Compiler flags for OPENNI. 10 | # 11 | # File forked from augmented_dev, project of alantrrs 12 | # (https://github.com/alantrrs/augmented_dev). 13 | 14 | find_package(PkgConfig) 15 | if(${CMAKE_VERSION} VERSION_LESS 2.8.2) 16 | endif() 17 | 18 | #add a hint so that it can find it without the pkg-config 19 | find_path(LIBREALSENSE_INCLUDE_DIR librealsense/rs.h 20 | HINTS /usr/include/ /usr/local/include) 21 | #add a hint so that it can find it without the pkg-config 22 | find_library(LIBREALSENSE_LIBRARY 23 | NAMES librealsense.so 24 | HINTS /usr/lib /usr/local/lib ) 25 | 26 | set(LIBREALSENSE_INCLUDE_DIRS ${LIBREALSENSE_INCLUDE_DIR}) 27 | set(LIBREALSENSE_LIBRARIES ${LIBREALSENSE_LIBRARY}) 28 | 29 | include(FindPackageHandleStandardArgs) 30 | find_package_handle_standard_args(LibRealSense DEFAULT_MSG 31 | LIBREALSENSE_LIBRARY LIBREALSENSE_INCLUDE_DIR) 32 | 33 | mark_as_advanced(LIBREALSENSE_LIBRARY LIBREALSENSE_INCLUDE_DIR) 34 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindLibRealSense2.cmake: -------------------------------------------------------------------------------- 1 | # -*- mode: cmake; -*- 2 | ############################################################################### 3 | # Find librealsense2 https://github.com/IntelRealSense/librealsense 4 | # 5 | # This sets the following variables: 6 | # LIBREALSENSE2_FOUND - True if LIBREALSENSE2 was found. 7 | # LIBREALSENSE2_INCLUDE_DIRS - Directories containing the LIBREALSENSE2 include files. 8 | # LIBREALSENSE2_LIBRARIES - Libraries needed to use LIBREALSENSE2. 9 | # LIBREALSENSE2_DEFINITIONS - Compiler flags for LIBREALSENSE2. 10 | # 11 | # File forked from augmented_dev, project of alantrrs 12 | # (https://github.com/alantrrs/augmented_dev). 13 | 14 | find_package(PkgConfig) 15 | if(${CMAKE_VERSION} VERSION_LESS 2.8.2) 16 | endif() 17 | 18 | #add a hint so that it can find it without the pkg-config 19 | find_path(LIBREALSENSE2_INCLUDE_DIR librealsense2/rs.h 20 | HINTS /usr/include/ /usr/local/include) 21 | #add a hint so that it can find it without the pkg-config 22 | find_library(LIBREALSENSE2_LIBRARY 23 | NAMES librealsense2.so 24 | HINTS /usr/lib /usr/local/lib ) 25 | 26 | set(LIBREALSENSE2_INCLUDE_DIRS ${LIBREALSENSE2_INCLUDE_DIR}) 27 | set(LIBREALSENSE2_LIBRARIES ${LIBREALSENSE2_LIBRARY}) 28 | 29 | include(FindPackageHandleStandardArgs) 30 | find_package_handle_standard_args(LibRealSense2 DEFAULT_MSG 31 | LIBREALSENSE2_LIBRARY LIBREALSENSE2_INCLUDE_DIR) 32 | 33 | mark_as_advanced(LIBREALSENSE2_LIBRARY LIBREALSENSE2_INCLUDE_DIR) 34 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindLz4.cmake: -------------------------------------------------------------------------------- 1 | 2 | find_path(Lz4_INCLUDE_DIRS 3 | NAMES lz4frame.h 4 | PATHS 5 | /opt/local/include 6 | /usr/local/include 7 | /usr/include 8 | ) 9 | 10 | find_library(Lz4_LIBRARIES 11 | NAMES lz4 12 | PATHS 13 | /usr/local/lib 14 | /opt/local/lib 15 | /user/local/lib 16 | /usr/lib 17 | ) 18 | 19 | include(FindPackageHandleStandardArgs) 20 | find_package_handle_standard_args(Lz4 REQUIRED_VARS Lz4_LIBRARIES Lz4_INCLUDE_DIRS) 21 | 22 | mark_as_advanced( 23 | Lz4_INCLUDE_DIRS 24 | Lz4_LIBRARIES 25 | Lz4_FOUND 26 | ) 27 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindMediaFoundation.cmake: -------------------------------------------------------------------------------- 1 | # - Find MediaFoundation 2 | # Find the Windows SDK MediaFoundation libraries 3 | # 4 | # MediaFoundation_LIBRARIES - List of libraries when using MediaFoundation 5 | # MediaFoundation_FOUND - True if MediaFoundation found 6 | 7 | IF (MSVC) 8 | SET( MediaFoundation_LIBRARIES mf.lib mfplat.lib mfreadwrite.lib mfuuid.lib strmiids.lib ) 9 | SET( MediaFoundation_FOUND true ) 10 | ENDIF (MSVC) 11 | 12 | IF (MediaFoundation_FOUND) 13 | IF (NOT MediaFoundation_FIND_QUIETLY) 14 | MESSAGE(STATUS "Found MediaFoundation: ${MediaFoundation_LIBRARIES}") 15 | ENDIF (NOT MediaFoundation_FIND_QUIETLY) 16 | ELSE (MediaFoundation_FOUND) 17 | IF (MediaFoundation_FIND_REQUIRED) 18 | MESSAGE(FATAL_ERROR "Could not find MediaFoundation") 19 | ENDIF (MediaFoundation_FIND_REQUIRED) 20 | ENDIF (MediaFoundation_FOUND) 21 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindOpenEXR.cmake: -------------------------------------------------------------------------------- 1 | # Try to find the OpenEXR v2 lib and include files 2 | # 3 | # OpenEXR_INCLUDE_DIR 4 | # OpenEXR_LIBRARIES 5 | # OpenEXR_FOUND 6 | 7 | FIND_PATH( OpenEXR_INCLUDE_DIR ImfHeader.h 8 | /usr/include 9 | /usr/local/include 10 | PATH_SUFFIXES OpenEXR 11 | ) 12 | 13 | FIND_LIBRARY( OpenEXR_LIBRARY IlmImf 14 | /usr/lib64 15 | /usr/lib 16 | /usr/local/lib 17 | ) 18 | 19 | IF(OpenEXR_INCLUDE_DIR AND OpenEXR_LIBRARY) 20 | SET( OpenEXR_FOUND TRUE ) 21 | SET( OpenEXR_LIBRARIES ${OpenEXR_LIBRARY} ) 22 | ENDIF() 23 | 24 | IF(OpenEXR_FOUND) 25 | IF(NOT OpenEXR_FIND_QUIETLY) 26 | MESSAGE(STATUS "Found OpenEXR: ${OpenEXR_LIBRARY}") 27 | ENDIF(NOT OpenEXR_FIND_QUIETLY) 28 | ELSE(OpenEXR_FOUND) 29 | IF(OpenEXR_FIND_REQUIRED) 30 | MESSAGE(FATAL_ERROR "Could not find libOpenEXR") 31 | ENDIF(OpenEXR_FIND_REQUIRED) 32 | ENDIF(OpenEXR_FOUND) 33 | 34 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindROBOTVISION.cmake: -------------------------------------------------------------------------------- 1 | # - Try to find librobotvision 2 | # 3 | # ROBOTVISION_FOUND - system has librobotvision 4 | # ROBOTVISION_INCLUDE_DIR - the librobotvision include directories 5 | # ROBOTVISION_LIBRARY - link these to use librobotvision 6 | 7 | FIND_PATH( 8 | ROBOTVISION_INCLUDE_DIR 9 | NAMES robotvision/bundle_adjuster.h 10 | PATHS ${CMAKE_SOURCE_DIR}/.. /usr/include/robotvision /usr/local/include/robotvision 11 | ) 12 | 13 | FIND_LIBRARY( 14 | ROBOTVISION_LIBRARY 15 | NAMES robotvision 16 | PATHS ${CMAKE_SOURCE_DIR}/../robotvision/release /usr/lib /usr/local/lib 17 | ) 18 | 19 | IF (ROBOTVISION_INCLUDE_DIR AND ROBOTVISION_LIBRARY) 20 | SET(ROBOTVISION_FOUND TRUE) 21 | ENDIF (ROBOTVISION_INCLUDE_DIR AND ROBOTVISION_LIBRARY) 22 | 23 | IF (ROBOTVISION_FOUND) 24 | IF (NOT ROBOTVISION_FIND_QUIETLY) 25 | MESSAGE(STATUS "Found ROBOTVISION: ${ROBOTVISION_LIBRARY}") 26 | ENDIF (NOT ROBOTVISION_FIND_QUIETLY) 27 | ELSE (ROBOTVISION_FOUND) 28 | IF (ROBOTVISION_FIND_REQUIRED) 29 | MESSAGE(FATAL_ERROR "Could not find ROBOTVISION") 30 | ENDIF (ROBOTVISION_FIND_REQUIRED) 31 | ENDIF (ROBOTVISION_FOUND) 32 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindTooN.cmake: -------------------------------------------------------------------------------- 1 | # - Try to find libTooN 2 | # 3 | # TooN_FOUND - system has libTooN 4 | # TooN_INCLUDE_DIR - the libTooN include directories 5 | 6 | FIND_PATH( 7 | TooN_INCLUDE_DIR 8 | NAMES TooN/TooN.h 9 | PATHS 10 | ${CMAKE_SOURCE_DIR} 11 | ${CMAKE_SOURCE_DIR}/.. 12 | /usr/include 13 | /usr/local/include 14 | ) 15 | 16 | IF(TooN_INCLUDE_DIR) 17 | SET(TooN_FOUND TRUE) 18 | ENDIF() 19 | 20 | IF(TooN_FOUND) 21 | IF(NOT TooN_FIND_QUIETLY) 22 | MESSAGE(STATUS "Found TooN: ${TooN_INCLUDE_DIR}") 23 | ENDIF() 24 | ELSE() 25 | IF(TooN_FIND_REQUIRED) 26 | MESSAGE(FATAL_ERROR "Could not find TooN") 27 | ENDIF() 28 | ENDIF() 29 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/FindXrandr.cmake: -------------------------------------------------------------------------------- 1 | # - Try to find Xrandr 2 | # 3 | # Xrandr_FOUND - system has libXrandr 4 | # Xrandr_INCLUDE_DIRS - the libXrandr include directories 5 | # Xrandr_LIBRARIES - link these to use libXrandr 6 | 7 | FIND_PATH( 8 | Xrandr_INCLUDE_DIRS 9 | NAMES X11/extensions/Xrandr.h 10 | PATH_SUFFIXES X11/extensions 11 | DOC "The Xrandr include directory" 12 | ) 13 | 14 | FIND_LIBRARY( 15 | Xrandr_LIBRARIES 16 | NAMES Xrandr 17 | DOC "The Xrandr library" 18 | ) 19 | 20 | IF (Xrandr_INCLUDE_DIRS AND Xrandr_LIBRARIES) 21 | SET(Xrandr_FOUND TRUE) 22 | ENDIF (Xrandr_INCLUDE_DIRS AND Xrandr_LIBRARIES) 23 | 24 | IF (Xrandr_FOUND) 25 | IF (NOT Xrandr_FIND_QUIETLY) 26 | MESSAGE(STATUS "Found Xrandr: ${Xrandr_LIBRARIES}") 27 | ENDIF (NOT Xrandr_FIND_QUIETLY) 28 | ELSE (Xrandr_FOUND) 29 | IF (Xrandr_FIND_REQUIRED) 30 | MESSAGE(FATAL_ERROR "Could not find Xrandr") 31 | ENDIF (Xrandr_FIND_REQUIRED) 32 | ENDIF (Xrandr_FOUND) 33 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/Findlibusb1.cmake: -------------------------------------------------------------------------------- 1 | # - Try to find libusb1 2 | # 3 | # libusb1_FOUND - system has libusb1 4 | # libusb1_INCLUDE_DIRS - the libusb1 include directories 5 | # libusb1_LIBRARIES - link these to use libusb1 6 | 7 | FIND_PATH( 8 | libusb1_INCLUDE_DIRS 9 | NAMES libusb-1.0/libusb.h 10 | PATHS 11 | c:/dev/sysroot32/usr/include 12 | ${CMAKE_SOURCE_DIR}/../libusb1/include 13 | /usr/include/ 14 | /usr/local/include 15 | /opt/local/include 16 | ) 17 | 18 | FIND_LIBRARY( 19 | libusb1_LIBRARIES 20 | NAMES libusb-1.0 21 | PATHS 22 | c:/dev/sysroot32/usr/lib 23 | ${CMAKE_SOURCE_DIR}/../libusb1/lib 24 | /usr/lib 25 | /usr/local/lib 26 | /opt/local/lib 27 | ) 28 | 29 | IF(libusb1_INCLUDE_DIRS AND libusb1_LIBRARIES) 30 | SET(libusb1_FOUND TRUE) 31 | ENDIF(libusb1_INCLUDE_DIRS AND libusb1_LIBRARIES) 32 | 33 | IF(libusb1_FOUND) 34 | IF(NOT libusb1_FIND_QUIETLY) 35 | MESSAGE(STATUS "Found libusb1: ${libusb1_LIBRARIES}") 36 | ENDIF(NOT libusb1_FIND_QUIETLY) 37 | ELSE(libusb1_FOUND) 38 | message(STATUS "libusb1 NOT found") 39 | IF(libusb1_FIND_REQUIRED) 40 | MESSAGE(FATAL_ERROR "Could not find libusb1") 41 | ENDIF(libusb1_FIND_REQUIRED) 42 | ENDIF(libusb1_FOUND) 43 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/Findpthread.cmake: -------------------------------------------------------------------------------- 1 | # - Try to find pthread 2 | # 3 | # pthread_FOUND - system has pthread 4 | # pthread_INCLUDE_DIRS - the pthread include directories 5 | # pthread_LIBRARIES - link these to use pthread 6 | 7 | FIND_PATH( 8 | pthread_INCLUDE_DIRS 9 | NAMES pthread.h 10 | PATHS 11 | c:/dev/sysroot32/usr/include 12 | ${CMAKE_SOURCE_DIR}/../pthread/include 13 | /usr/include/ 14 | /usr/local/include 15 | /opt/local/include 16 | ) 17 | 18 | FIND_LIBRARY( 19 | pthread_LIBRARIES 20 | NAMES pthreadVSE2 pthread 21 | PATHS 22 | c:/dev/sysroot32/usr/lib 23 | ${CMAKE_SOURCE_DIR}/../pthread/lib 24 | /usr/lib 25 | /usr/local/lib 26 | /opt/local/lib 27 | ) 28 | 29 | IF(pthread_INCLUDE_DIRS AND pthread_LIBRARIES) 30 | SET(pthread_FOUND TRUE) 31 | ENDIF(pthread_INCLUDE_DIRS AND pthread_LIBRARIES) 32 | 33 | IF(pthread_FOUND) 34 | IF(NOT pthread_FIND_QUIETLY) 35 | MESSAGE(STATUS "Found pthread: ${pthread_LIBRARIES}") 36 | ENDIF(NOT pthread_FIND_QUIETLY) 37 | ELSE(pthread_FOUND) 38 | message(STATUS "pthread NOT found") 39 | IF(pthread_FIND_REQUIRED) 40 | MESSAGE(FATAL_ERROR "Could not find pthread") 41 | ENDIF(pthread_FIND_REQUIRED) 42 | ENDIF(pthread_FOUND) 43 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/Finduvc.cmake: -------------------------------------------------------------------------------- 1 | # - Try to find uvc 2 | # 3 | # uvc_FOUND - system has libuvc 4 | # uvc_INCLUDE_DIRS - the libuvc include directories 5 | # uvc_LIBRARIES - link these to use libuvc 6 | 7 | FIND_PATH( 8 | uvc_INCLUDE_DIRS 9 | NAMES libuvc/libuvc.h 10 | PATHS 11 | ${CMAKE_SOURCE_DIR}/.. 12 | /usr/include/ 13 | /usr/local/include 14 | /opt/local/include 15 | ) 16 | 17 | FIND_LIBRARY( 18 | uvc_LIBRARIES 19 | NAMES uvc 20 | PATHS 21 | ${CMAKE_SOURCE_DIR}/../uvc/build 22 | /usr/lib 23 | /usr/local/lib 24 | /opt/local/lib 25 | ) 26 | 27 | IF (uvc_INCLUDE_DIRS AND uvc_LIBRARIES) 28 | SET(uvc_FOUND TRUE) 29 | ENDIF (uvc_INCLUDE_DIRS AND uvc_LIBRARIES) 30 | 31 | IF (uvc_FOUND) 32 | IF (NOT uvc_FIND_QUIETLY) 33 | MESSAGE(STATUS "Found uvc: ${uvc_LIBRARIES}") 34 | ENDIF (NOT uvc_FIND_QUIETLY) 35 | ELSE (uvc_FOUND) 36 | IF (uvc_FIND_REQUIRED) 37 | MESSAGE(FATAL_ERROR "Could not find uvc") 38 | ENDIF (uvc_FIND_REQUIRED) 39 | ENDIF (uvc_FOUND) 40 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/Findzstd.cmake: -------------------------------------------------------------------------------- 1 | ############################################################################### 2 | # Find Toshiba TeliCam 3 | # 4 | # This sets the following variables: 5 | # TeliCam_FOUND - True if TeliCam was found. 6 | # TeliCam_INCLUDE_DIRS - Directories containing the TeliCam include files. 7 | # TeliCam_LIBRARIES - Libraries needed to use TeliCam. 8 | 9 | find_path( 10 | zstd_INCLUDE_DIR zstd.h 11 | PATHS 12 | /opt/local/include 13 | /usr/local/include 14 | /usr/include 15 | PATH_SUFFIXES TeliCam 16 | ) 17 | 18 | find_library( 19 | zstd_LIBRARY 20 | NAMES zstd 21 | PATHS 22 | /opt/local/lib 23 | /user/local/lib 24 | /usr/lib 25 | ) 26 | 27 | # Plural forms 28 | set(zstd_INCLUDE_DIRS ${zstd_INCLUDE_DIR}) 29 | set(zstd_LIBRARIES ${zstd_LIBRARY}) 30 | 31 | include(FindPackageHandleStandardArgs) 32 | find_package_handle_standard_args( zstd 33 | FOUND_VAR zstd_FOUND 34 | REQUIRED_VARS zstd_INCLUDE_DIR zstd_LIBRARY 35 | ) 36 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/CMakeModules/SetPlatformVars.cmake: -------------------------------------------------------------------------------- 1 | ## Compiler configuration 2 | IF(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_GNUCC) 3 | SET(_GCC_ 1) 4 | ENDIF() 5 | 6 | IF(${CMAKE_CXX_COMPILER_ID} STREQUAL "Clang") 7 | SET(_CLANG_ 1) 8 | ENDIF() 9 | 10 | IF(MSVC) 11 | SET(_MSVC_ 1) 12 | ENDIF() 13 | 14 | ## Platform configuration 15 | 16 | IF(WIN32 OR WIN64) 17 | SET(_WIN_ 1) 18 | ENDIF() 19 | 20 | IF(UNIX) 21 | SET(_UNIX_ 1) 22 | ENDIF() 23 | 24 | IF(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") 25 | SET(_OSX_ 1) 26 | ENDIF() 27 | 28 | IF(${CMAKE_SYSTEM_NAME} MATCHES "Linux") 29 | SET(_LINUX_ 1) 30 | ENDIF() 31 | 32 | IF(ANDROID) 33 | SET(_ANDROID_ 1) 34 | ENDIF() 35 | 36 | IF(IOS) 37 | SET(_APPLE_IOS_ 1) 38 | ENDIF() 39 | 40 | 41 | 42 | ## Default search paths 43 | 44 | IF(_WIN_) 45 | IF(${CMAKE_CL_64}) 46 | LIST(APPEND CMAKE_INCLUDE_PATH "c:/dev/sysroot64/usr/include") 47 | LIST(APPEND CMAKE_LIBRARY_PATH "c:/dev/sysroot64/usr/lib") 48 | LIST(APPEND CMAKE_LIBRARY_PATH "c:/dev/sysroot64/usr/bin") 49 | set(PROGRAM_FILES "$ENV{PROGRAMW6432}" ) 50 | ELSE() 51 | LIST(APPEND CMAKE_INCLUDE_PATH "c:/dev/sysroot32/usr/include") 52 | LIST(APPEND CMAKE_LIBRARY_PATH "c:/dev/sysroot32/usr/lib") 53 | LIST(APPEND CMAKE_LIBRARY_PATH "c:/dev/sysroot32/usr/bin") 54 | set(PROGRAM_FILES "$ENV{PROGRAMFILES}" ) 55 | ENDIF() 56 | ENDIF() 57 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/LICENCE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2011 Steven Lovegrove and Richard Newcombe 2 | 3 | Permission is hereby granted, free of charge, to any person 4 | obtaining a copy of this software and associated documentation 5 | files (the "Software"), to deal in the Software without 6 | restriction, including without limitation the rights to use, 7 | copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | copies of the Software, and to permit persons to whom the 9 | Software is furnished to do so, subject to the following 10 | conditions: 11 | 12 | The above copyright notice and this permission notice shall be 13 | included in all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 16 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 17 | OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 18 | NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 19 | HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 20 | WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 21 | FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 22 | OTHER DEALINGS IN THE SOFTWARE. 23 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/appveyor.yml: -------------------------------------------------------------------------------- 1 | os: Visual Studio 2015 2 | 3 | clone_folder: c:/projects/Pangolin 4 | 5 | platform: x64 6 | configuration: Release 7 | 8 | build: 9 | verbosity: minimal 10 | project: c:/projects/Pangolin/build/Pangolin.sln 11 | 12 | install: 13 | - ps: wget http://bitbucket.org/eigen/eigen/get/3.2.10.zip -outfile eigen3.zip 14 | - cmd: 7z x eigen3.zip -o"C:/projects" -y > nul 15 | 16 | before_build: 17 | - cd c:/projects/Pangolin 18 | - mkdir bin 19 | - mkdir build 20 | - cd build 21 | - cmake -G "Visual Studio 14 2015 Win64" -D EIGEN3_INCLUDE_DIR=C:/projects/eigen-eigen-b9cd8366d4e8 -D CMAKE_INSTALL_PREFIX=../bin .. 22 | 23 | on_success: 24 | - 7z a pangolin_build.zip "c:/projects/Pangolin/build/src/include" "c:/projects/Pangolin/build/src/Release/pangolin.lib" "c:/projects/Pangolin/build/tools/*/Release/*.exe" "c:/projects/Pangolin/build/examples/*/Release/*.exe" 25 | - appveyor PushArtifact pangolin_build.zip 26 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/cmake_uninstall.cmake.in: -------------------------------------------------------------------------------- 1 | # ----------------------------------------------- 2 | # File that provides "make uninstall" target 3 | # We use the file 'install_manifest.txt' 4 | # ----------------------------------------------- 5 | IF(NOT EXISTS "@CMAKE_BINARY_DIR@/install_manifest.txt") 6 | MESSAGE(FATAL_ERROR "Cannot find install manifest: \"@CMAKE_BINARY_DIR@/install_manifest.txt\"") 7 | ENDIF(NOT EXISTS "@CMAKE_BINARY_DIR@/install_manifest.txt") 8 | 9 | FILE(READ "@CMAKE_BINARY_DIR@/install_manifest.txt" files) 10 | STRING(REGEX REPLACE "\n" ";" files "${files}") 11 | FOREACH(file ${files}) 12 | MESSAGE(STATUS "Uninstalling \"$ENV{DESTDIR}${file}\"") 13 | IF(EXISTS "$ENV{DESTDIR}${file}") 14 | EXEC_PROGRAM( 15 | "@CMAKE_COMMAND@" ARGS "-E remove \"$ENV{DESTDIR}${file}\"" 16 | OUTPUT_VARIABLE rm_out 17 | RETURN_VALUE rm_retval 18 | ) 19 | IF(NOT "${rm_retval}" STREQUAL 0) 20 | MESSAGE(FATAL_ERROR "Problem when removing \"$ENV{DESTDIR}${file}\"") 21 | ENDIF(NOT "${rm_retval}" STREQUAL 0) 22 | ELSE(EXISTS "$ENV{DESTDIR}${file}") 23 | MESSAGE(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.") 24 | ENDIF(EXISTS "$ENV{DESTDIR}${file}") 25 | ENDFOREACH(file) 26 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # All examples depend on Pangolin GUI 2 | if(BUILD_PANGOLIN_GUI) 3 | add_subdirectory(HelloPangolin) 4 | add_subdirectory(HelloPangolinOffscreen) 5 | add_subdirectory(HelloPangolinThreads) 6 | add_subdirectory(SimpleMultiDisplay) 7 | add_subdirectory(SimpleDisplayImage) 8 | add_subdirectory(SimpleScene) 9 | 10 | if(NOT HAVE_GLES OR HAVE_GLES_2) 11 | add_subdirectory(SimplePlot) 12 | endif() 13 | 14 | ## These samples require Pangolin Var support 15 | if(BUILD_PANGOLIN_VARS) 16 | add_subdirectory(SimpleDisplay) 17 | 18 | ## Video Samples require Pangolin Video support 19 | if(BUILD_PANGOLIN_VIDEO) 20 | add_subdirectory(SimpleVideo) 21 | add_subdirectory(SimpleRecord) 22 | add_subdirectory(SharedMemoryCamera) 23 | endif() 24 | 25 | # # This sample fails on many platforms, so exclude it for now, 26 | # # until we can create a better cmake test for support. 27 | # find_package(CUDA QUIET) 28 | # if( CUDA_FOUND ) 29 | # add_subdirectory(VBODisplay) 30 | # endif() 31 | 32 | endif() 33 | endif() 34 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/HelloPangolin/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(HelloPangolin main.cpp) 6 | target_link_libraries(HelloPangolin ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/HelloPangolin/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | int main( int /*argc*/, char** /*argv*/ ) 4 | { 5 | pangolin::CreateWindowAndBind("Main",640,480); 6 | glEnable(GL_DEPTH_TEST); 7 | 8 | // Define Projection and initial ModelView matrix 9 | pangolin::OpenGlRenderState s_cam( 10 | pangolin::ProjectionMatrix(640,480,420,420,320,240,0.2,100), 11 | pangolin::ModelViewLookAt(-2,2,-2, 0,0,0, pangolin::AxisY) 12 | ); 13 | 14 | // Create Interactive View in window 15 | pangolin::Handler3D handler(s_cam); 16 | pangolin::View& d_cam = pangolin::CreateDisplay() 17 | .SetBounds(0.0, 1.0, 0.0, 1.0, -640.0f/480.0f) 18 | .SetHandler(&handler); 19 | 20 | while( !pangolin::ShouldQuit() ) 21 | { 22 | // Clear screen and activate view to render into 23 | glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); 24 | d_cam.Activate(s_cam); 25 | 26 | // Render OpenGL Cube 27 | pangolin::glDrawColouredCube(); 28 | 29 | // Swap frames and Process Events 30 | pangolin::FinishFrame(); 31 | } 32 | 33 | return 0; 34 | } 35 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/HelloPangolinOffscreen/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.5 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(HelloPangolinOffscreen main.cpp) 6 | target_link_libraries(HelloPangolinOffscreen ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/HelloPangolinThreads/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.5 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(HelloPangolinThreads main.cpp) 6 | target_link_libraries(HelloPangolinThreads ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SharedMemoryCamera/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | if(UNIX) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(SharedMemoryCamera main.cpp) 6 | target_link_libraries(SharedMemoryCamera ${Pangolin_LIBRARIES}) 7 | endif() 8 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleDisplay/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(SimpleDisplay main.cpp) 6 | target_link_libraries(SimpleDisplay ${Pangolin_LIBRARIES} ) 7 | 8 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleDisplay/app.cfg: -------------------------------------------------------------------------------- 1 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 2 | % Pangolin Sample configuration file 3 | % Comments start with '%' or '#' 4 | % 5 | % Declarations are name value pairs, 6 | % seperated with '=' and terminated with ';' 7 | 8 | % We can set any variable referenced in code directly 9 | ui.A Double = 3.2; 10 | ui.A Checkbox = false; 11 | 12 | % We can set unreferenced variables too 13 | a.b = 1; 14 | a.c = 2; 15 | z.b = 3; 16 | z.c = 4; 17 | start = z; 18 | 19 | % Which we might refer to by reference 20 | ui.An Int = ${${start}.c}; 21 | 22 | % Declarations can span multiple lines 23 | M = 24 | [1, 0, 0 25 | 0, 1, 0 26 | 0, 0, 1]; 27 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleDisplayImage/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(SimpleDisplayImage main.cpp) 6 | target_link_libraries(SimpleDisplayImage ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleMultiDisplay/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(SimpleMultiDisplay main.cpp) 6 | target_link_libraries(SimpleMultiDisplay ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleMultiDisplay/app.cfg: -------------------------------------------------------------------------------- 1 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% 2 | % Pangolin Sample configuration file 3 | % Comments start with '%' or '#' 4 | % 5 | % Declarations are name value pairs, 6 | % seperated with '=' and terminated with ';' 7 | 8 | % We can set any variable referenced in code directly 9 | ui.A Double = 3.2; 10 | 11 | % We can set unreferenced variables too 12 | a.b = 1; 13 | a.c = 2; 14 | z.b = 3; 15 | z.c = 4; 16 | start = z; 17 | 18 | % Which we might refer to by reference 19 | ui.An Int = ${${start}.c}; 20 | 21 | % Declarations can span multiple lines 22 | M = 23 | [1, 0, 0 24 | 0, 1, 0 25 | 0, 0, 1]; 26 | 27 | ui.Aliased Double = @ui.A Double; 28 | ui.Aliased Double = 2.0; 29 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimplePlot/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(SimplePlot main.cpp) 6 | target_link_libraries(SimplePlot ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleRecord/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(SimpleRecord main.cpp) 6 | target_link_libraries(SimpleRecord ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleScene/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(SimpleScene main.cpp) 6 | target_link_libraries(SimpleScene ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleScene/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | 5 | int main( int /*argc*/, char** /*argv*/ ) 6 | { 7 | pangolin::CreateWindowAndBind("Main",640,480); 8 | glEnable(GL_DEPTH_TEST); 9 | 10 | // Define Projection and initial ModelView matrix 11 | pangolin::OpenGlRenderState s_cam( 12 | pangolin::ProjectionMatrix(640,480,420,420,320,240,0.2,100), 13 | pangolin::ModelViewLookAt(-2,2,-2, 0,0,0, pangolin::AxisY) 14 | ); 15 | 16 | pangolin::Renderable tree; 17 | tree.Add( std::make_shared() ); 18 | 19 | // Create Interactive View in window 20 | pangolin::SceneHandler handler(tree, s_cam); 21 | pangolin::View& d_cam = pangolin::CreateDisplay() 22 | .SetBounds(0.0, 1.0, 0.0, 1.0, -640.0f/480.0f) 23 | .SetHandler(&handler); 24 | 25 | d_cam.SetDrawFunction([&](pangolin::View& view){ 26 | view.Activate(s_cam); 27 | tree.Render(); 28 | }); 29 | 30 | while( !pangolin::ShouldQuit() ) 31 | { 32 | // Clear screen and activate view to render into 33 | glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); 34 | 35 | // Swap frames and Process Events 36 | pangolin::FinishFrame(); 37 | } 38 | 39 | return 0; 40 | } 41 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/SimpleVideo/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(SimpleVideo main.cpp) 6 | target_link_libraries(SimpleVideo ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/VBODisplay/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | link_directories(${Pangolin_LIBRARY_DIRS}) 5 | link_libraries(${Pangolin_LIBRARIES}) 6 | 7 | find_package(CUDA QUIET) 8 | 9 | # This example could be made to work with C++11, but the kernel code must be 10 | # compiled without it. 11 | if(CUDA_FOUND) 12 | cuda_include_directories(${CMAKE_CURRENT_SOURCE_DIR}) 13 | 14 | cuda_add_executable( 15 | VBODisplay 16 | main.cpp kernal.cu 17 | ) 18 | 19 | endif() 20 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/examples/VBODisplay/kernal.cu: -------------------------------------------------------------------------------- 1 | // Colour Sine wave Kernal 2 | // Based on kernal_colour in kernelVBO.cpp by Rob Farber 3 | __global__ void kernel(float4* dVertexArray, uchar4 *dColorArray, 4 | unsigned int width, unsigned int height, float time) 5 | { 6 | unsigned int x = blockIdx.x*blockDim.x + threadIdx.x; 7 | unsigned int y = blockIdx.y*blockDim.y + threadIdx.y; 8 | 9 | // Each thread is unique point (u,v) in interval [-1,1],[-1,1] 10 | const float u = 2.0f* (x/(float)width) - 1.0f; 11 | const float v = 2.0f* (y/(float)height) - 1.0f; 12 | const float w = 0.5f * sinf(4.0f*u + time) * cosf(4.0f*v + time); 13 | 14 | // Update vertex array for point 15 | dVertexArray[y*width+x] = make_float4(u, w, v, 1.0f); 16 | 17 | // Update colour array for point 18 | dColorArray[y*width+x].w = 0.0f; 19 | dColorArray[y*width+x].x = 255.0f *0.5f*(1.f+sinf(w+x)); 20 | dColorArray[y*width+x].y = 255.0f *0.5f*(1.f+sinf(x)*cosf(y)); 21 | dColorArray[y*width+x].z = 255.0f *0.5f*(1.f+sinf(w+time/10.0f)); 22 | } 23 | 24 | extern "C" void launch_kernel(float4* dVertexArray, uchar4* dColourArray, 25 | unsigned int width, unsigned int height, float time) 26 | { 27 | dim3 block(8, 8, 1); 28 | dim3 grid(width / block.x, height / block.y, 1); 29 | kernel<<< grid, block>>>(dVertexArray, dColourArray, width, height, time); 30 | } 31 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/compat/optional.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | // Use either C++17 optional, or the standalone backwards compatible version 6 | #if (__cplusplus >= 201703L) 7 | # include 8 | #else 9 | # include 10 | #endif 11 | 12 | namespace pangolin { 13 | #if (__cplusplus >= 201703L) 14 | template 15 | using optional = std::optional; 16 | #else 17 | template 18 | using optional = std::experimental::optional; 19 | #endif 20 | } 21 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/compat/variant.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | // Use either C++17 variant, or the standalone backwards compatible version 6 | // of M. Park. 7 | #if (__cplusplus >= 201703L) 8 | # include 9 | #else 10 | # include 11 | #endif 12 | 13 | namespace pangolin { 14 | #if (__cplusplus >= 201703L) 15 | using std::variant; 16 | using std::get; 17 | using std::get_if; 18 | using std::visit; 19 | #else 20 | using mpark::variant; 21 | using mpark::get; 22 | using mpark::get_if; 23 | using mpark::visit; 24 | #endif 25 | } 26 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/display/device/X11GlContext.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/Pangolin/include/pangolin/display/device/X11GlContext.h -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/geometry/geometry_obj.h: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) 2011 Steven Lovegrove 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #include 29 | 30 | namespace pangolin { 31 | 32 | pangolin::Geometry LoadGeometryObj(const std::string& filename); 33 | 34 | } 35 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/image/image_convert.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | namespace pangolin 7 | { 8 | 9 | template 10 | void ImageConvert(Image& dst, const Image& src, To scale = 1.0) 11 | { 12 | for(unsigned int y = 0; y < dst.h; ++y) 13 | { 14 | const T* prs = src.RowPtr(y); 15 | To* prd = dst.RowPtr(y); 16 | for(unsigned int x = 0; x < dst.w; ++x) 17 | { 18 | *(prd++) = scale * ComponentCast::cast(*(prs++)); 19 | } 20 | } 21 | } 22 | 23 | template 24 | ManagedImage ImageConvert(const Image& src, To scale = 1.0) 25 | { 26 | ManagedImage dst(src.w, src.h); 27 | ImageConvert(dst,src,scale); 28 | return dst; 29 | } 30 | 31 | } 32 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/ios/PangolinUIView.h: -------------------------------------------------------------------------------- 1 | // 2 | // GlTestViewController.h 3 | // gltest 4 | // 5 | // Created by Steven Lovegrove on 30/01/2014. 6 | // Copyright (c) 2014 Steven Lovegrove. All rights reserved. 7 | // 8 | 9 | #import 10 | 11 | #include 12 | #include 13 | 14 | @interface PangolinUIView : UIView { 15 | CAEAGLLayer* _eaglLayer; 16 | EAGLContext* _context; 17 | 18 | GLuint _colorRenderBuffer; 19 | GLuint _depthRenderBuffer; 20 | } 21 | 22 | @end -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/log/playback_session.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | #include 7 | #include 8 | #include 9 | 10 | namespace pangolin { 11 | 12 | class Params; 13 | 14 | class PlaybackSession 15 | { 16 | public: 17 | // Singleton Instance 18 | static std::shared_ptr Default(); 19 | 20 | // Return thread-safe, shared instance of PacketStreamReader, providing 21 | // serialised read for PacketStreamReader 22 | std::shared_ptr Open(const std::string& filename) 23 | { 24 | const std::string path = SanitizePath(PathExpand(filename)); 25 | 26 | auto i = readers.find(path); 27 | if(i == readers.end()) { 28 | auto psr = std::make_shared(path); 29 | readers[path] = psr; 30 | return psr; 31 | }else{ 32 | return i->second; 33 | } 34 | } 35 | 36 | SyncTime& Time() 37 | { 38 | return time; 39 | } 40 | 41 | static std::shared_ptr ChooseFromParams(const Params& params); 42 | 43 | private: 44 | std::map> readers; 45 | SyncTime time; 46 | }; 47 | 48 | } 49 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/scene/tree.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | namespace pangolin { 7 | 8 | template 9 | struct TreeNode 10 | { 11 | struct Edge 12 | { 13 | TEdge parent_child; 14 | TreeNode node; 15 | }; 16 | 17 | T item; 18 | std::vector edges; 19 | }; 20 | 21 | template 22 | using NodeFunction = std::function&,const TEdge&)>; 23 | 24 | //template 25 | //void VisitDepthFirst(TreeNode& node, const NodeFunction& func, const TEdge& T_root_node = TEdge()) 26 | //{ 27 | // func(node, T_root_node); 28 | // for(auto& e : node.edges) { 29 | // const TEdge T_root_child = T_root_node * e.parent_child; 30 | // VisitDepthFirst(e.node, func, T_root_child); 31 | // } 32 | //} 33 | 34 | //void Eg() 35 | //{ 36 | // using RenderNode = TreeNode,OpenGlMatrix>; 37 | 38 | // RenderNode root; 39 | // VisitDepthFirst,OpenGlMatrix>( 40 | // root, [](RenderNode& node, const OpenGlMatrix& T_root_node) { 41 | // if(node.item) { 42 | // node.item->DoRender(); 43 | // } 44 | // }, IdentityMatrix()); 45 | 46 | //} 47 | 48 | 49 | } 50 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/utils/compontent_cast.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #ifdef HAVE_EIGEN 6 | # include 7 | #endif 8 | 9 | namespace pangolin 10 | { 11 | 12 | // Scalar / Vector agnostic static_cast-like thing 13 | // 14 | // e.g. Promote float to double: 15 | // ComponentCast::cast(0.14f); 16 | // 17 | // e.g. Promote Eigen::Vector2f to Eigen::Vector2d: 18 | // ComponentCast::cast(Eigen::Vector2f(0.1,0.2); 19 | 20 | template 21 | struct ComponentCast 22 | { 23 | PANGO_HOST_DEVICE 24 | static To cast(const From& val) 25 | { 26 | return static_cast(val); 27 | } 28 | }; 29 | 30 | #ifdef HAVE_EIGEN 31 | template 32 | struct ComponentCast > 33 | { 34 | PANGO_HOST_DEVICE 35 | static To cast(const Eigen::MatrixBase& val) 36 | { 37 | return val.template cast(); 38 | } 39 | }; 40 | #endif 41 | 42 | } 43 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/utils/memstreambuf.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | namespace pangolin { 7 | 8 | // A simple streambuf wrapper around std::vector for memory buffer use 9 | struct memstreambuf : public std::streambuf 10 | { 11 | public: 12 | memstreambuf(size_t initial_buffer_size) 13 | { 14 | buffer.reserve(initial_buffer_size); 15 | } 16 | 17 | // Avoiding use of std::streambuf's move constructor, since it is missing for old GCC 18 | memstreambuf(memstreambuf&& o) 19 | : buffer(std::move(o.buffer)) 20 | { 21 | pubseekpos(o.pubseekoff(0, std::ios_base::cur)); 22 | } 23 | 24 | size_t size() const 25 | { 26 | return buffer.size(); 27 | } 28 | 29 | const unsigned char* data() const 30 | { 31 | return buffer.data(); 32 | } 33 | 34 | void clear() 35 | { 36 | buffer.clear(); 37 | } 38 | 39 | std::vector buffer; 40 | 41 | protected: 42 | std::streamsize xsputn(const char_type* __s, std::streamsize __n) override 43 | { 44 | buffer.insert(buffer.end(), __s, __s + __n); 45 | return __n; 46 | } 47 | 48 | int_type overflow(int_type __c) override 49 | { 50 | buffer.push_back( static_cast(__c) ); 51 | return __c; 52 | } 53 | }; 54 | 55 | } 56 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/utils/posix/condition_variable.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | namespace pangolin 8 | { 9 | 10 | class ConditionVariableInterface 11 | { 12 | public: 13 | virtual ~ConditionVariableInterface() 14 | { 15 | } 16 | 17 | virtual void wait() = 0; 18 | virtual bool wait(timespec t) = 0; 19 | virtual void signal() = 0; 20 | virtual void broadcast() = 0; 21 | }; 22 | 23 | std::shared_ptr create_named_condition_variable(const 24 | std::string& name); 25 | std::shared_ptr open_named_condition_variable(const 26 | std::string& name); 27 | } 28 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/utils/posix/semaphore.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | namespace pangolin 8 | { 9 | 10 | class SemaphoreInterface 11 | { 12 | public: 13 | 14 | virtual ~SemaphoreInterface() { 15 | } 16 | 17 | virtual bool tryAcquire() = 0; 18 | virtual void acquire() = 0; 19 | virtual void release() = 0; 20 | }; 21 | 22 | std::shared_ptr create_named_semaphore(const std::string& name, 23 | unsigned int value); 24 | std::shared_ptr open_named_semaphore(const std::string& name); 25 | 26 | } 27 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/utils/posix/shared_memory_buffer.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | namespace pangolin 8 | { 9 | class SharedMemoryBufferInterface 10 | { 11 | public: 12 | virtual ~SharedMemoryBufferInterface() { 13 | } 14 | virtual bool tryLock() = 0; 15 | virtual void lock() = 0; 16 | virtual void unlock() = 0; 17 | virtual unsigned char *ptr() = 0; 18 | virtual std::string name() = 0; 19 | }; 20 | 21 | std::shared_ptr create_named_shared_memory_buffer(const 22 | std::string& name, size_t size); 23 | std::shared_ptr open_named_shared_memory_buffer(const 24 | std::string& name, bool readwrite); 25 | } 26 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/utils/registration.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace pangolin { 6 | 7 | template 8 | class Registration 9 | { 10 | public: 11 | using UnregisterFunc = std::function; 12 | 13 | Registration() 14 | : token() 15 | { 16 | } 17 | 18 | Registration(TokenType token, UnregisterFunc unregister) 19 | : token(token), unregister(unregister) 20 | { 21 | 22 | } 23 | 24 | // No copy constructor 25 | Registration(const Registration&) = delete; 26 | 27 | // Default move constructor 28 | Registration(Registration&& o) 29 | { 30 | *this = std::move(o); 31 | } 32 | 33 | Registration& operator =(Registration&& o) 34 | { 35 | token = o.token; 36 | unregister = std::move(o.unregister); 37 | o.unregister = nullptr; 38 | return *this; 39 | } 40 | 41 | ~Registration() 42 | { 43 | Release(); 44 | } 45 | 46 | void Release() 47 | { 48 | if(unregister) { 49 | unregister(token); 50 | token = TokenType(); 51 | } 52 | } 53 | 54 | const TokenType& Token() 55 | { 56 | return token; 57 | } 58 | 59 | private: 60 | TokenType token; 61 | UnregisterFunc unregister; 62 | }; 63 | 64 | } 65 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/utils/signal_slot.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | #include 7 | 8 | namespace pangolin { 9 | 10 | // Based on http://simmesimme.github.io/tutorials/2015/09/20/signal-slot 11 | template 12 | class Signal 13 | { 14 | public: 15 | using Id = size_t; 16 | using Reg = Registration; 17 | 18 | Signal() 19 | : current_id_(0) 20 | { 21 | } 22 | 23 | Signal(const Signal&) = delete; 24 | 25 | Signal(Signal&&) = default; 26 | 27 | // connects a std::function to the signal. The returned 28 | // value can be used to disconnect the function again 29 | Reg Connect(const std::function& slot) const { 30 | slots_.insert(std::make_pair(++current_id_, slot)); 31 | return Reg(current_id_, [this](Id id){ Disconnect(id);}); 32 | } 33 | 34 | // disconnects a previously connected function 35 | void Disconnect(Id id) const { 36 | slots_.erase(id); 37 | } 38 | 39 | // disconnects all previously connected functions 40 | void DisconnectAll() const { 41 | slots_.clear(); 42 | } 43 | 44 | // calls all connected functions 45 | void operator()(Args... p) { 46 | for(auto it : slots_) { 47 | it.second(p...); 48 | } 49 | } 50 | 51 | private: 52 | mutable std::map> slots_; 53 | mutable Id current_id_; 54 | }; 55 | 56 | } 57 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/utils/variadic_all.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace pangolin { 6 | 7 | template 8 | bool all_of(TPred pred, const T& i) 9 | { 10 | return pred(i); 11 | } 12 | 13 | template 14 | bool all_of(const TPred& pred, const T& i, const Targs& ... ins) 15 | { 16 | return pred(i) && all_of(pred, ins...); 17 | } 18 | 19 | template 20 | bool any_of(TPred pred, const T& i) 21 | { 22 | return pred(i); 23 | } 24 | 25 | template 26 | bool any_of(const TPred& pred, const T& i, Targs& ... ins) 27 | { 28 | return pred(i) || any_of(pred, ins...); 29 | } 30 | 31 | template 32 | bool all_found(const TContainer& c, const Targs& ... its) 33 | { 34 | using T1 = typename std::tuple_element<0, std::tuple>::type; 35 | return all_of([&c](const T1& it){return it != c.end();}, its...); 36 | } 37 | 38 | template 39 | bool all_equal(const T& v1, const Targs& ... its) 40 | { 41 | return all_of([v1](const T& o){return v1 == o;}, its...); 42 | } 43 | 44 | } 45 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/video/drivers/shared_memory.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | #include 9 | #include 10 | 11 | namespace pangolin 12 | { 13 | 14 | class SharedMemoryVideo : public VideoInterface 15 | { 16 | public: 17 | SharedMemoryVideo(size_t w, size_t h, std::string pix_fmt, 18 | const std::shared_ptr& shared_memory, 19 | const std::shared_ptr& buffer_full); 20 | ~SharedMemoryVideo(); 21 | 22 | size_t SizeBytes() const; 23 | const std::vector& Streams() const; 24 | void Start(); 25 | void Stop(); 26 | bool GrabNext(unsigned char *image, bool wait); 27 | bool GrabNewest(unsigned char *image, bool wait); 28 | 29 | private: 30 | PixelFormat _fmt; 31 | size_t _frame_size; 32 | std::vector _streams; 33 | std::shared_ptr _shared_memory; 34 | std::shared_ptr _buffer_full; 35 | }; 36 | 37 | } 38 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/video/stream_encoder_factory.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include 6 | 7 | namespace pangolin { 8 | 9 | using ImageEncoderFunc = std::function&)>; 10 | using ImageDecoderFunc = std::function; 11 | 12 | class StreamEncoderFactory 13 | { 14 | public: 15 | static StreamEncoderFactory& I(); 16 | 17 | ImageEncoderFunc GetEncoder(const std::string& encoder_spec, const PixelFormat& fmt); 18 | 19 | ImageDecoderFunc GetDecoder(const std::string& encoder_spec, const PixelFormat& fmt); 20 | }; 21 | 22 | } 23 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/video/video_exception.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | #include 6 | 7 | namespace pangolin { 8 | 9 | struct PANGOLIN_EXPORT VideoException : std::exception 10 | { 11 | VideoException(std::string str) : desc(str) {} 12 | VideoException(std::string str, std::string detail) { 13 | desc = str + "\n\t" + detail; 14 | } 15 | ~VideoException() throw() {} 16 | const char* what() const throw() { return desc.c_str(); } 17 | std::string desc; 18 | }; 19 | 20 | struct PANGOLIN_EXPORT VideoExceptionNoKnownHandler : public VideoException 21 | { 22 | VideoExceptionNoKnownHandler(const std::string& scheme) 23 | : VideoException("No known video handler for URI '" + scheme + "'") 24 | { 25 | } 26 | }; 27 | 28 | } 29 | 30 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/include/pangolin/video/video_record_repeat.h: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) 2011 Steven Lovegrove 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | // VideoInput subsumes the previous VideoRecordRepeat class. 31 | #include 32 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/package.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | pangolin 4 | 0.5.0 5 | pangolin 6 | Steven Lovegrove 7 | Steven Lovegrove 8 | MIT 9 | cmake 10 | libglew-dev 11 | cmake 12 | python 13 | 14 | cmake 15 | 16 | 17 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/pyexamples/SimplePlot.py: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env python3 2 | import sys 3 | sys.path.append('../build/src') 4 | 5 | from OpenGL.GL import * 6 | import pypangolin as pango 7 | import math 8 | 9 | def main(): 10 | win = pango.CreateWindowAndBind("main py_pangolin", 640, 480) 11 | log = pango.DataLog() 12 | log.SetLabels(["sin(t)", "cos(t)", "sin(t)+cos(t)"]) 13 | 14 | t=0; 15 | tinc=0.01 16 | 17 | plotter = pango.Plotter(log,0,4*math.pi/tinc,-2,2,math.pi/(4*tinc),0.5); 18 | plotter.Track("$i") 19 | plotter.AddMarker(pango.Marker.Vertical, -1000, pango.Marker.LessThan, pango.Colour.Blue().WithAlpha(0.2)) 20 | plotter.AddMarker(pango.Marker.Horizontal, 100, pango.Marker.GreaterThan, pango.Colour.Red().WithAlpha(0.2)) 21 | plotter.AddMarker(pango.Marker.Horizontal, 10, pango.Marker.Equal, pango.Colour.Green().WithAlpha(0.2)) 22 | plotter.SetBounds(pango.Attach(0), pango.Attach(1), 23 | pango.Attach(0), pango.Attach(1)) 24 | 25 | pango.DisplayBase().AddDisplay(plotter) 26 | 27 | while not pango.ShouldQuit(): 28 | glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT) 29 | 30 | log.Log(math.sin(t), math.cos(t), math.sin(t)+math.cos(t)) 31 | t+=tinc 32 | 33 | pango.FinishFrame() 34 | 35 | if __name__ == "__main__": 36 | main() 37 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/PangolinConfig.cmake.in: -------------------------------------------------------------------------------- 1 | # Compute paths 2 | get_filename_component( PROJECT_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH ) 3 | SET( Pangolin_INCLUDE_DIRS "@EXPORT_LIB_INC_DIR@;@USER_INC@" ) 4 | SET( Pangolin_INCLUDE_DIR "@EXPORT_LIB_INC_DIR@;@USER_INC@" ) 5 | 6 | # Library dependencies (contains definitions for IMPORTED targets) 7 | if( NOT TARGET @LIBRARY_NAME@ AND NOT @PROJECT_NAME@_BINARY_DIR ) 8 | include( "${PROJECT_CMAKE_DIR}/@PROJECT_NAME@Targets.cmake" ) 9 | @ExternConfig@ 10 | endif() 11 | 12 | SET( Pangolin_LIBRARIES @LIBRARY_NAME@ ) 13 | SET( Pangolin_LIBRARY @LIBRARY_NAME@ ) 14 | SET( Pangolin_CMAKEMODULES @CMAKE_CURRENT_SOURCE_DIR@/../CMakeModules ) 15 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/PangolinConfigVersion.cmake.in: -------------------------------------------------------------------------------- 1 | set(PACKAGE_VERSION "@PANGOLIN_VERSION@") 2 | 3 | # Check build type is valid 4 | if( "System:${CMAKE_SYSTEM_NAME},Win64:${CMAKE_CL_64},Android:${ANDROID},iOS:${IOS}" STREQUAL 5 | "System:@CMAKE_SYSTEM_NAME@,Win64:@CMAKE_CL_64@,Android:@ANDROID@,iOS:@IOS@" ) 6 | # Check whether the requested PACKAGE_FIND_VERSION is compatible 7 | if("${PACKAGE_VERSION}" VERSION_LESS "${PACKAGE_FIND_VERSION}") 8 | set(PACKAGE_VERSION_COMPATIBLE FALSE) 9 | else() 10 | set(PACKAGE_VERSION_COMPATIBLE TRUE) 11 | if ("${PACKAGE_VERSION}" VERSION_EQUAL "${PACKAGE_FIND_VERSION}") 12 | set(PACKAGE_VERSION_EXACT TRUE) 13 | endif() 14 | endif() 15 | else() 16 | set(PACKAGE_VERSION_COMPATIBLE FALSE) 17 | endif() 18 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/_embed_/fonts/AnonymousPro.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/Pangolin/src/_embed_/fonts/AnonymousPro.ttf -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/geometry/tinyobj.cpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) 2011 Steven Lovegrove 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #define TINYOBJLOADER_IMPLEMENTATION 29 | #include 30 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/gl/gltexturecache.cpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) 2013 Steven Lovegrove 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #include 29 | 30 | namespace pangolin 31 | { 32 | 33 | TextureCache& TextureCache::I() { 34 | static TextureCache instance; 35 | return instance; 36 | } 37 | 38 | } -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/image/image_io_raw.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | 4 | namespace pangolin { 5 | 6 | TypedImage LoadImage( 7 | const std::string& filename, 8 | const PixelFormat& raw_fmt, 9 | size_t raw_width, size_t raw_height, size_t raw_pitch 10 | ) { 11 | TypedImage img(raw_width, raw_height, raw_fmt, raw_pitch); 12 | 13 | // Read from file, row at a time. 14 | std::ifstream bFile( filename.c_str(), std::ios::in | std::ios::binary ); 15 | for(size_t r=0; r 2 | #include 3 | 4 | namespace pangolin { 5 | 6 | std::shared_ptr PlaybackSession::Default() 7 | { 8 | static std::shared_ptr instance = std::make_shared(); 9 | return instance; 10 | } 11 | 12 | std::shared_ptr PlaybackSession::ChooseFromParams(const Params& params) 13 | { 14 | bool use_ordered_playback = params.Get("OrderedPlayback", false); 15 | std::shared_ptr playback_session; 16 | if(use_ordered_playback) 17 | { 18 | return Default(); 19 | } 20 | else 21 | { 22 | return std::make_shared(); 23 | } 24 | } 25 | 26 | } 27 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/attach.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_attach(pybind11::module &m); 35 | 36 | } // py_pangolin 37 | 38 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/colour.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_colour(pybind11::module& m); 35 | 36 | } // py_pangolin 37 | 38 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/datalog.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_datalog(pybind11::module& m); 35 | 36 | } // py_pangolin 37 | 38 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/display.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_display(pybind11::module &m); 35 | 36 | } // py_pangolin 37 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/gl.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_gl(pybind11::module &m); 35 | 36 | } // py_pangolin 37 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/gl_draw.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_gl_draw(pybind11::module &m); 35 | 36 | } // py_pangolin 37 | 38 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/glsl.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_glsl(pybind11::module &m); 35 | 36 | } // py_pangolin 37 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/image.cpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #include "image.hpp" 29 | #include 30 | 31 | namespace py_pangolin { 32 | 33 | } // py_pangolin 34 | 35 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/params.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_params(pybind11::module &m); 35 | 36 | } // py_pangolin 37 | 38 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin/video.hpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Andrey Mnatsakanov 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #pragma once 29 | 30 | #include 31 | 32 | namespace py_pangolin { 33 | 34 | void bind_video(pybind11::module& m); 35 | 36 | } // py_pangolin 37 | 38 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/python/pypangolin_module.cpp: -------------------------------------------------------------------------------- 1 | /* This file is part of the Pangolin Project. 2 | * http://github.com/stevenlovegrove/Pangolin 3 | * 4 | * Copyright (c) Steven Lovegrove 5 | * 6 | * Permission is hereby granted, free of charge, to any person 7 | * obtaining a copy of this software and associated documentation 8 | * files (the "Software"), to deal in the Software without 9 | * restriction, including without limitation the rights to use, 10 | * copy, modify, merge, publish, distribute, sublicense, and/or sell 11 | * copies of the Software, and to permit persons to whom the 12 | * Software is furnished to do so, subject to the following 13 | * conditions: 14 | * 15 | * The above copyright notice and this permission notice shall be 16 | * included in all copies or substantial portions of the Software. 17 | * 18 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 19 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES 20 | * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND 21 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT 22 | * HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 23 | * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING 24 | * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 25 | * OTHER DEALINGS IN THE SOFTWARE. 26 | */ 27 | 28 | #include "pypangolin/pypangolin.h" 29 | 30 | PYBIND11_MODULE(pypangolin, m) { 31 | pypangolin::PopulateModule(m); 32 | } 33 | 34 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/src/utils/timer.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/Pangolin/src/utils/timer.cpp -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/test/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_subdirectory("log") -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/test/log/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | #add_executable(Testlog testlog.cpp ) 6 | #target_link_libraries(Testlog ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/tools/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | if(BUILD_PANGOLIN_GUI AND BUILD_PANGOLIN_VARS ) 2 | if(BUILD_PANGOLIN_VIDEO) 3 | add_subdirectory(VideoViewer) 4 | add_subdirectory(VideoConvert) 5 | add_subdirectory(VideoJson) 6 | add_subdirectory(Plotter) 7 | endif() 8 | 9 | option(BUILD_PANGOLIN_EIGEN "Build support for Eigen matrix types" ON) 10 | if(BUILD_PANGOLIN_EIGEN) 11 | find_package(Eigen QUIET) 12 | if(EIGEN_FOUND) 13 | add_subdirectory(ModelViewer) 14 | endif() 15 | endif() 16 | 17 | endif() 18 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/tools/ModelViewer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.3 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(ModelViewer main.cpp) 6 | target_link_libraries(ModelViewer ${Pangolin_LIBRARIES}) 7 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/tools/ModelViewer/util.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | template 4 | bool is_ready(std::future const& f) 5 | { return f.wait_for(std::chrono::seconds(0)) == std::future_status::ready; } 6 | 7 | inline std::vector ExpandGlobOption(const argagg::option_results& opt) 8 | { 9 | std::vector expanded; 10 | for(const auto& o : opt.all) 11 | { 12 | const std::string r = o.as(); 13 | pangolin::FilesMatchingWildcard(r, expanded); 14 | } 15 | return expanded; 16 | } 17 | 18 | template 19 | inline std::vector TryLoad(const std::vector& in, const F& load_func) 20 | { 21 | std::vector loaded; 22 | for(const Tin& file : in) 23 | { 24 | try { 25 | loaded.emplace_back(load_func(file)); 26 | }catch(const std::exception&) { 27 | } 28 | } 29 | return loaded; 30 | } 31 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/tools/Plotter/application-x-pangoplot.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Pangolin Video File 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/tools/VideoConvert/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(VideoConvert main.cpp) 6 | target_link_libraries(VideoConvert ${Pangolin_LIBRARIES}) 7 | 8 | ####################################################### 9 | ## Install 10 | 11 | install(TARGETS VideoConvert 12 | RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}/bin 13 | LIBRARY DESTINATION ${CMAKE_INSTALL_PREFIX}/lib 14 | ARCHIVE DESTINATION ${CMAKE_INSTALL_PREFIX}/lib 15 | ) 16 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/tools/VideoJson/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | # Find Pangolin (https://github.com/stevenlovegrove/Pangolin) 2 | find_package(Pangolin 0.4 REQUIRED) 3 | include_directories(${Pangolin_INCLUDE_DIRS}) 4 | 5 | add_executable(VideoJsonPrint main-print.cpp) 6 | target_link_libraries(VideoJsonPrint ${Pangolin_LIBRARIES}) 7 | 8 | add_executable(VideoJsonTransform main-transform.cpp) 9 | target_link_libraries(VideoJsonTransform ${Pangolin_LIBRARIES}) 10 | 11 | ####################################################### 12 | ## Install 13 | 14 | install(TARGETS VideoJsonPrint VideoJsonTransform 15 | RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX}/bin 16 | LIBRARY DESTINATION ${CMAKE_INSTALL_PREFIX}/lib 17 | ARCHIVE DESTINATION ${CMAKE_INSTALL_PREFIX}/lib 18 | ) 19 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/tools/VideoJson/main-print.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #include 4 | #include 5 | #include 6 | 7 | int main( int argc, char* argv[] ) 8 | { 9 | if( argc == 2) { 10 | const std::string filename = std::string(argv[1]); 11 | pangolin::PacketStreamReader reader(filename); 12 | 13 | // Extract JSON 14 | picojson::value all_properties; 15 | 16 | for(size_t i=0; i < reader.Sources().size(); ++i) { 17 | picojson::value source_props; 18 | 19 | const pangolin::PacketStreamSource& src = reader.Sources()[i]; 20 | source_props["device_properties"] = src.info["device"]; 21 | 22 | // Seek through index, loading frame properties 23 | for(size_t framenum=0; framenum < src.index.size(); ++framenum) { 24 | reader.Seek(src.id, framenum); 25 | pangolin::Packet pkt = reader.NextFrame(); 26 | source_props["frame_properties"].push_back(pkt.meta); 27 | } 28 | 29 | all_properties.push_back(source_props); 30 | } 31 | 32 | std::cout << all_properties.serialize(true) << std::endl; 33 | }else{ 34 | std::cout << "Usage: \n\tPangoJsonPrint filename.pango" << std::endl; 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/Pangolin/tools/VideoViewer/application-x-pango.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | Pangolin Video File 5 | 6 | 7 | 8 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/.clang-format: -------------------------------------------------------------------------------- 1 | --- 2 | Language: Cpp 3 | BasedOnStyle: Google 4 | IndentWidth: 2 5 | IncludeBlocks: Preserve 6 | ... 7 | 8 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/.gitignore: -------------------------------------------------------------------------------- 1 | cmake-build* 2 | .idea 3 | CMakeLists.txt.user 4 | build* 5 | public 6 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/.gitmodules: -------------------------------------------------------------------------------- 1 | [submodule "thirdparty/Sophus"] 2 | path = thirdparty/Sophus 3 | url = https://github.com/strasdat/Sophus.git 4 | [submodule "thirdparty/cereal"] 5 | path = thirdparty/cereal 6 | url = https://github.com/USCiLab/cereal.git 7 | [submodule "test/googletest"] 8 | path = test/googletest 9 | url = https://github.com/google/googletest.git 10 | [submodule "test/benchmark"] 11 | path = test/benchmark 12 | url = https://github.com/google/benchmark.git 13 | [submodule "thirdparty/eigen"] 14 | path = thirdparty/eigen 15 | url = https://gitlab.com/libeigen/eigen.git 16 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/cmake_modules/PreProjectWorkarounds.cmake: -------------------------------------------------------------------------------- 1 | # workarounds that need to be applied before the `project(...)` call 2 | 3 | # macOS < 10.15 requires that we set CMAKE_OSX_DEPLOYMENT_TARGET to 4 | # 10.15 before `project(...)` is called, otherwise clang thinks 5 | # certain C++17 STL features such as std::visit and std::filesystem 6 | # are not available. 7 | if(APPLE) 8 | # Note: CMAKE_SYSTEM_VERSION doesn't work before `project(...)` 9 | execute_process(COMMAND sw_vers -productVersion OUTPUT_VARIABLE _macos_version) 10 | string(REGEX REPLACE "\n$" "" _macos_version "${_macos_version}") 11 | if (_macos_version VERSION_LESS 10.15.0) 12 | message(STATUS "Detected macOS version '${_macos_version}', which is earlier than macOS 10.15 Catalina. Applying workarounds for clang and libc++...") 13 | 14 | # Ensure libc++ enables all features. 15 | # See: https://stackoverflow.com/a/53868971/1813258 16 | # See: https://stackoverflow.com/a/53887048/1813258 17 | set(CMAKE_OSX_DEPLOYMENT_TARGET "10.15" CACHE STRING "Minimum OS X deployment version") 18 | message(STATUS "... setting deployment target to '${CMAKE_OSX_DEPLOYMENT_TARGET}' to trick libc++ into not disabling some features (like std::visit)") 19 | message(STATUS "... compiler set to '${CMAKE_C_COMPILER}' and '${CMAKE_CXX_COMPILER}'") 20 | else() 21 | message(STATUS "Detected macOS version '${_macos_version}', which is newer or equal to macOS 10.15 Catalina. Not applying workarounds.") 22 | endif() 23 | endif() 24 | 25 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/doc/img/basalt_light.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/basalt-headers/doc/img/basalt_light.png -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/doc/img/ds.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/basalt-headers/doc/img/ds.png -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/doc/img/eucm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/basalt-headers/doc/img/eucm.png -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/doc/img/fov.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/basalt-headers/doc/img/fov.png -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/doc/img/kb.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/basalt-headers/doc/img/kb.png -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/doc/img/mipmap.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/basalt-headers/doc/img/mipmap.jpeg -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/doc/img/stereographic.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/basalt-headers/doc/img/stereographic.png -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/doc/img/ucm.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/TinyGrapeKit/third_party/basalt-headers/doc/img/ucm.png -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/include/basalt/utils/hash.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | namespace basalt { 6 | 7 | // to work around static_assert(false, ...) 8 | template 9 | struct dependent_false : std::false_type {}; 10 | 11 | template 12 | inline void hash_combine(std::size_t& seed, const T& value) { 13 | // Simple hash_combine, see e.g. here: 14 | // https://github.com/HowardHinnant/hash_append/issues/7 15 | // Not sure we ever need 32bit, but here it is... 16 | if constexpr (sizeof(std::size_t) == 4) { 17 | seed ^= std::hash{}(value) + 0x9e3779b9U + (seed << 6) + (seed >> 2); 18 | } else if constexpr (sizeof(std::size_t) == 8) { 19 | seed ^= std::hash{}(value) + 0x9e3779b97f4a7c15LLU + (seed << 12) + 20 | (seed >> 4); 21 | } else { 22 | static_assert(dependent_false::value, "hash_combine not implemented"); 23 | } 24 | } 25 | 26 | } // namespace basalt 27 | -------------------------------------------------------------------------------- /TinyGrapeKit/third_party/basalt-headers/scripts/clang-format-all.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | # Format all source files in the project. 4 | # Optionally take folder as argument; default is full inlude and src dirs. 5 | 6 | set -e 7 | 8 | SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" 9 | 10 | FOLDER="${1:-$SCRIPT_DIR/../include $SCRIPT_DIR/../test/src $SCRIPT_DIR/../test/include}" 11 | 12 | CLANG_FORMAT_COMMANDS="clang-format-11 clang-format-10 clang-format-9 clang-format" 13 | 14 | # find the first available command: 15 | for CMD in $CLANG_FORMAT_COMMANDS; do 16 | if hash $CMD 2>/dev/null; then 17 | CLANG_FORMAT_CMD=$CMD 18 | break 19 | fi 20 | done 21 | 22 | if [ -z $CLANG_FORMAT_CMD ]; then 23 | echo "clang-format not installed..." 24 | exit 1 25 | fi 26 | 27 | # clang format check version 28 | MAJOR_VERSION_NEEDED=8 29 | 30 | MAJOR_VERSION_DETECTED=`$CLANG_FORMAT_CMD -version | sed -n -E 's/.*version ([0-9]+).*/\1/p'` 31 | if [ -z $MAJOR_VERSION_DETECTED ]; then 32 | echo "Failed to parse major version (`$CLANG_FORMAT_CMD -version`)" 33 | exit 1 34 | fi 35 | 36 | echo "clang-format version $MAJOR_VERSION_DETECTED (`$CLANG_FORMAT_CMD -version`)" 37 | 38 | if [ $MAJOR_VERSION_DETECTED -lt $MAJOR_VERSION_NEEDED ]; then 39 | echo "Looks like your clang format is too old; need at least version $MAJOR_VERSION_NEEDED" 40 | exit 1 41 | fi 42 | 43 | find $FOLDER -iname "*.?pp" -or -iname "*.h" | xargs $CLANG_FORMAT_CMD -verbose -i 44 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/camera_model/include/camodocal/camera_models/CameraFactory.h: -------------------------------------------------------------------------------- 1 | #ifndef CAMERAFACTORY_H 2 | #define CAMERAFACTORY_H 3 | 4 | #include 5 | #include 6 | 7 | #include "camodocal/camera_models/Camera.h" 8 | 9 | namespace camodocal 10 | { 11 | 12 | class CameraFactory 13 | { 14 | public: 15 | EIGEN_MAKE_ALIGNED_OPERATOR_NEW 16 | CameraFactory(); 17 | 18 | static boost::shared_ptr instance(void); 19 | 20 | CameraPtr generateCamera(Camera::ModelType modelType, 21 | const std::string& cameraName, 22 | cv::Size imageSize) const; 23 | 24 | CameraPtr generateCameraFromYamlFile(const std::string& filename); 25 | 26 | private: 27 | static boost::shared_ptr m_instance; 28 | }; 29 | 30 | } 31 | 32 | #endif 33 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/camera_model/include/camodocal/chessboard/ChessboardCorner.h: -------------------------------------------------------------------------------- 1 | #ifndef CHESSBOARDCORNER_H 2 | #define CHESSBOARDCORNER_H 3 | 4 | #include 5 | #include 6 | 7 | namespace camodocal 8 | { 9 | 10 | class ChessboardCorner; 11 | typedef boost::shared_ptr ChessboardCornerPtr; 12 | 13 | class ChessboardCorner 14 | { 15 | public: 16 | ChessboardCorner() : row(0), column(0), needsNeighbor(true), count(0) {} 17 | 18 | float meanDist(int &n) const 19 | { 20 | float sum = 0; 21 | n = 0; 22 | for (int i = 0; i < 4; ++i) 23 | { 24 | if (neighbors[i].get()) 25 | { 26 | float dx = neighbors[i]->pt.x - pt.x; 27 | float dy = neighbors[i]->pt.y - pt.y; 28 | sum += sqrt(dx*dx + dy*dy); 29 | n++; 30 | } 31 | } 32 | return sum / std::max(n, 1); 33 | } 34 | 35 | cv::Point2f pt; // X and y coordinates 36 | int row; // Row and column of the corner 37 | int column; // in the found pattern 38 | bool needsNeighbor; // Does the corner require a neighbor? 39 | int count; // number of corner neighbors 40 | ChessboardCornerPtr neighbors[4]; // pointer to all corner neighbors 41 | }; 42 | 43 | } 44 | 45 | #endif 46 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/camera_model/include/camodocal/chessboard/ChessboardQuad.h: -------------------------------------------------------------------------------- 1 | #ifndef CHESSBOARDQUAD_H 2 | #define CHESSBOARDQUAD_H 3 | 4 | #include 5 | 6 | #include "camodocal/chessboard/ChessboardCorner.h" 7 | 8 | namespace camodocal 9 | { 10 | 11 | class ChessboardQuad; 12 | typedef boost::shared_ptr ChessboardQuadPtr; 13 | 14 | class ChessboardQuad 15 | { 16 | public: 17 | ChessboardQuad() : count(0), group_idx(-1), edge_len(FLT_MAX), labeled(false) {} 18 | 19 | int count; // Number of quad neighbors 20 | int group_idx; // Quad group ID 21 | float edge_len; // Smallest side length^2 22 | ChessboardCornerPtr corners[4]; // Coordinates of quad corners 23 | ChessboardQuadPtr neighbors[4]; // Pointers of quad neighbors 24 | bool labeled; // Has this corner been labeled? 25 | }; 26 | 27 | } 28 | 29 | #endif 30 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/camera_model/include/camodocal/gpl/EigenQuaternionParameterization.h: -------------------------------------------------------------------------------- 1 | #ifndef EIGENQUATERNIONPARAMETERIZATION_H 2 | #define EIGENQUATERNIONPARAMETERIZATION_H 3 | 4 | #include "ceres/local_parameterization.h" 5 | 6 | namespace camodocal 7 | { 8 | 9 | class EigenQuaternionParameterization : public ceres::LocalParameterization 10 | { 11 | public: 12 | virtual ~EigenQuaternionParameterization() {} 13 | virtual bool Plus(const double* x, 14 | const double* delta, 15 | double* x_plus_delta) const; 16 | virtual bool ComputeJacobian(const double* x, 17 | double* jacobian) const; 18 | virtual int GlobalSize() const { return 4; } 19 | virtual int LocalSize() const { return 3; } 20 | 21 | private: 22 | template 23 | void EigenQuaternionProduct(const T z[4], const T w[4], T zw[4]) const; 24 | }; 25 | 26 | 27 | template 28 | void 29 | EigenQuaternionParameterization::EigenQuaternionProduct(const T z[4], const T w[4], T zw[4]) const 30 | { 31 | zw[0] = z[3] * w[0] + z[0] * w[3] + z[1] * w[2] - z[2] * w[1]; 32 | zw[1] = z[3] * w[1] - z[0] * w[2] + z[1] * w[3] + z[2] * w[0]; 33 | zw[2] = z[3] * w[2] + z[0] * w[1] - z[1] * w[0] + z[2] * w[3]; 34 | zw[3] = z[3] * w[3] - z[0] * w[0] - z[1] * w[1] - z[2] * w[2]; 35 | } 36 | 37 | } 38 | 39 | #endif 40 | 41 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/camera_model/include/camodocal/sparse_graph/Transform.h: -------------------------------------------------------------------------------- 1 | #ifndef TRANSFORM_H 2 | #define TRANSFORM_H 3 | 4 | #include 5 | #include 6 | #include 7 | 8 | namespace camodocal 9 | { 10 | 11 | class Transform 12 | { 13 | public: 14 | EIGEN_MAKE_ALIGNED_OPERATOR_NEW 15 | 16 | Transform(); 17 | Transform(const Eigen::Matrix4d& H); 18 | 19 | Eigen::Quaterniond& rotation(void); 20 | const Eigen::Quaterniond& rotation(void) const; 21 | double* rotationData(void); 22 | const double* const rotationData(void) const; 23 | 24 | Eigen::Vector3d& translation(void); 25 | const Eigen::Vector3d& translation(void) const; 26 | double* translationData(void); 27 | const double* const translationData(void) const; 28 | 29 | Eigen::Matrix4d toMatrix(void) const; 30 | 31 | private: 32 | Eigen::Quaterniond m_q; 33 | Eigen::Vector3d m_t; 34 | }; 35 | 36 | } 37 | 38 | #endif 39 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/camera_model/instruction: -------------------------------------------------------------------------------- 1 | rosrun camera_model Calibration -w 8 -h 11 -s 70 -i ~/bag/PX/calib/ 2 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/camera_model/readme.md: -------------------------------------------------------------------------------- 1 | part of [camodocal](https://github.com/hengli/camodocal) 2 | 3 | [Google Ceres](http://ceres-solver.org) is needed. 4 | 5 | # Calibration: 6 | 7 | Use [intrinsic_calib.cc](https://github.com/dvorak0/camera_model/blob/master/src/intrinsic_calib.cc) to calibrate your camera. 8 | 9 | # Undistortion: 10 | 11 | See [Camera.h](https://github.com/dvorak0/camera_model/blob/master/include/camodocal/camera_models/Camera.h) for general interface: 12 | 13 | - liftProjective: Lift points from the image plane to the projective space. 14 | - spaceToPlane: Projects 3D points to the image plane (Pi function) 15 | 16 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/camera_model/src/sparse_graph/Transform.cc: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | namespace camodocal 4 | { 5 | 6 | Transform::Transform() 7 | { 8 | m_q.setIdentity(); 9 | m_t.setZero(); 10 | } 11 | 12 | Transform::Transform(const Eigen::Matrix4d& H) 13 | { 14 | m_q = Eigen::Quaterniond(H.block<3,3>(0,0)); 15 | m_t = H.block<3,1>(0,3); 16 | } 17 | 18 | Eigen::Quaterniond& 19 | Transform::rotation(void) 20 | { 21 | return m_q; 22 | } 23 | 24 | const Eigen::Quaterniond& 25 | Transform::rotation(void) const 26 | { 27 | return m_q; 28 | } 29 | 30 | double* 31 | Transform::rotationData(void) 32 | { 33 | return m_q.coeffs().data(); 34 | } 35 | 36 | const double* const 37 | Transform::rotationData(void) const 38 | { 39 | return m_q.coeffs().data(); 40 | } 41 | 42 | Eigen::Vector3d& 43 | Transform::translation(void) 44 | { 45 | return m_t; 46 | } 47 | 48 | const Eigen::Vector3d& 49 | Transform::translation(void) const 50 | { 51 | return m_t; 52 | } 53 | 54 | double* 55 | Transform::translationData(void) 56 | { 57 | return m_t.data(); 58 | } 59 | 60 | const double* const 61 | Transform::translationData(void) const 62 | { 63 | return m_t.data(); 64 | } 65 | 66 | Eigen::Matrix4d 67 | Transform::toMatrix(void) const 68 | { 69 | Eigen::Matrix4d H; 70 | H.setIdentity(); 71 | H.block<3,3>(0,0) = m_q.toRotationMatrix(); 72 | H.block<3,1>(0,3) = m_t; 73 | 74 | return H; 75 | } 76 | 77 | } 78 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/config/fisheye_mask.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/config/fisheye_mask.jpg -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/08739427.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/doc/08739427.pdf -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/2021-05-27 12-51-17 的屏幕截图.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/doc/2021-05-27 12-51-17 的屏幕截图.png -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/2021-05-27 12-55-34 的屏幕截图.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/doc/2021-05-27 12-55-34 的屏幕截图.png -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/2021-05-27 12-59-27 的屏幕截图.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/doc/2021-05-27 12-59-27 的屏幕截图.png -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/2021-05-27 13-02-13 的屏幕截图.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/doc/2021-05-27 13-02-13 的屏幕截图.png -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/2021-05-27 13-09-51 的屏幕截图.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/doc/2021-05-27 13-09-51 的屏幕截图.png -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/DanielMedina_ION19.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/doc/DanielMedina_ION19.pdf -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/problem.txt: -------------------------------------------------------------------------------- 1 | 问题: 2 | rotation不对: 3 | 绝对方向确定! 4 | gps静止时的扰动 5 | 干扰定位结果! -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/doc/rosgraph.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_encoder_msckf/src/doc/rosgraph.png -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/feature_tracker/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 2.8.3) 2 | project(feature_tracker) 3 | 4 | set(CMAKE_BUILD_TYPE "Release") 5 | set(CMAKE_CXX_FLAGS "-std=c++11") 6 | set(CMAKE_CXX_FLAGS_RELEASE "-O3 -Wall -g") 7 | 8 | find_package(catkin REQUIRED COMPONENTS 9 | roscpp 10 | std_msgs 11 | sensor_msgs 12 | cv_bridge 13 | camera_model 14 | ) 15 | 16 | find_package(OpenCV REQUIRED) 17 | 18 | catkin_package() 19 | 20 | include_directories( 21 | ${catkin_INCLUDE_DIRS} 22 | ) 23 | 24 | set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) 25 | find_package(Eigen3) 26 | include_directories( 27 | ${catkin_INCLUDE_DIRS} 28 | ${EIGEN3_INCLUDE_DIR} 29 | ) 30 | 31 | add_executable(feature_tracker 32 | src/feature_tracker_node.cpp 33 | src/parameters.cpp 34 | src/feature_tracker.cpp 35 | ) 36 | 37 | target_link_libraries(feature_tracker ${catkin_LIBRARIES} ${OpenCV_LIBS}) 38 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/feature_tracker/src/parameters.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | 5 | extern int ROW; 6 | extern int COL; 7 | extern int FOCAL_LENGTH; 8 | const int NUM_OF_CAM = 1; 9 | 10 | 11 | extern std::string IMAGE_TOPIC; 12 | extern std::string IMU_TOPIC; 13 | extern std::string FISHEYE_MASK; 14 | extern std::vector CAM_NAMES; 15 | extern int MAX_CNT; 16 | extern int MIN_DIST; 17 | extern int WINDOW_SIZE; 18 | extern int FREQ; 19 | extern double F_THRESHOLD; 20 | extern int SHOW_TRACK; 21 | extern int STEREO_TRACK; 22 | extern int EQUALIZE; 23 | extern int FISHEYE; 24 | extern bool PUB_THIS_FRAME; 25 | 26 | void readParameters(ros::NodeHandle &n); 27 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/feature_tracker/src/tic_toc.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | #include 6 | 7 | class TicToc 8 | { 9 | public: 10 | TicToc() 11 | { 12 | tic(); 13 | } 14 | 15 | void tic() 16 | { 17 | start = std::chrono::system_clock::now(); 18 | } 19 | 20 | double toc() 21 | { 22 | end = std::chrono::system_clock::now(); 23 | std::chrono::duration elapsed_seconds = end - start; 24 | return elapsed_seconds.count() * 1000; 25 | } 26 | 27 | private: 28 | std::chrono::time_point start, end; 29 | }; 30 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/msckf_estimator/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 2.8.3) 2 | project(msckf_estimator) 3 | 4 | set(CMAKE_BUILD_TYPE "Release") 5 | set(CMAKE_CXX_FLAGS "-std=c++11") 6 | #-DEIGEN_USE_MKL_ALL") 7 | set(CMAKE_CXX_FLAGS_RELEASE "-O3 -Wall -g") 8 | add_definitions(-w) 9 | 10 | find_package(catkin REQUIRED COMPONENTS 11 | roscpp 12 | std_msgs 13 | geometry_msgs 14 | nav_msgs 15 | tf 16 | cv_bridge 17 | ) 18 | 19 | find_package(OpenCV REQUIRED) 20 | 21 | find_package(Eigen3) 22 | 23 | 24 | include_directories( 25 | ${catkin_INCLUDE_DIRS} 26 | ${EIGEN3_INCLUDE_DIR} 27 | /home/touchair/multi_ws/src/imu_gps_encoder_msckf/src/readKaistDataset/third_party/GeographicLib/include 28 | "/home/touchair/multi_ws/devel/include" 29 | "/usr/include/eigen3" 30 | 31 | ) 32 | 33 | catkin_package() 34 | 35 | add_executable(msckf_estimator 36 | src/estimator_node.cpp 37 | src/parameters.cpp 38 | src/estimator.cpp 39 | ) 40 | target_link_libraries(msckf_estimator ${catkin_LIBRARIES} ${OpenCV_LIBS} libGeographiccc) -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/msckf_estimator/src/parameters.h: -------------------------------------------------------------------------------- 1 | #ifndef PARAMETER_H 2 | #define PARAMETER_H 3 | 4 | #include 5 | #include 6 | // #include 7 | #include 8 | #include 9 | #include 10 | #include 11 | 12 | const double FOCAL_LENGTH = (816.90378992770002 + 811.56803828490001) / 2; 13 | 14 | extern std::string IMU_TOPIC; 15 | extern std::string GPS_TOPIC; 16 | extern std::string ENCODER_TOPIC; 17 | extern Eigen::Vector3d t_o_g; 18 | extern Eigen::Matrix3d R_o_i; 19 | extern Eigen::Vector3d t_o_i; 20 | extern Eigen::Matrix3d R_o_c; 21 | extern Eigen::Vector3d t_o_c; 22 | extern double acc_noise; 23 | extern double acc_bias_noise; 24 | extern double gyro_noise; 25 | extern double gyro_bias_noise; 26 | extern double left_wheel_diameter; 27 | extern double right_wheel_diameter; 28 | extern double wheel_base; 29 | 30 | void readParameters(ros::NodeHandle &n); 31 | 32 | inline Eigen::Matrix3d GetSkewMatrix(const Eigen::Vector3d& v) { 33 | Eigen::Matrix3d w; 34 | w << 0., -v(2), v(1), 35 | v(2), 0., -v(0), 36 | -v(1), v(0), 0.; 37 | return w; 38 | } 39 | 40 | #endif -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/readKaistDataset/launch/kaist.launch: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/readKaistDataset/msg/encoder.msg: -------------------------------------------------------------------------------- 1 | float64 timeStamp 2 | float64 leftEncoder 3 | float64 rightEncoder -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/readKaistDataset/msg/gps.msg: -------------------------------------------------------------------------------- 1 | float64 timeStamp 2 | float64 latitude 3 | float64 longitude 4 | float64 altitude 5 | float64 cov00 6 | float64 cov01 7 | float64 cov02 8 | float64 cov10 9 | float64 cov11 10 | float64 cov12 11 | float64 cov20 12 | float64 cov21 13 | float64 cov22 -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/readKaistDataset/msg/imu.msg: -------------------------------------------------------------------------------- 1 | float64 timeStamp 2 | float64 gx 3 | float64 gy 4 | float64 gz 5 | float64 ax 6 | float64 ay 7 | float64 az -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/readKaistDataset/third_party/GeographicLib/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project (GeographicLib) 2 | 3 | # Version information 4 | set (PROJECT_VERSION_MAJOR 1) 5 | set (PROJECT_VERSION_MINOR 49) 6 | set (PROJECT_VERSION_PATCH 0) 7 | set (PROJECT_VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}") 8 | if (PROJECT_VERSION_PATCH GREATER 0) 9 | set (PROJECT_VERSION "${PROJECT_VERSION}.${PROJECT_VERSION_PATCH}") 10 | endif () 11 | 12 | # The library version tracks the numbering given by libtool in the 13 | # autoconf set up. 14 | set (LIBVERSION_API 17) 15 | set (LIBVERSION_BUILD 17.1.2) 16 | string (TOLOWER ${PROJECT_NAME} PROJECT_NAME_LOWER) 17 | string (TOUPPER ${PROJECT_NAME} PROJECT_NAME_UPPER) 18 | 19 | cmake_minimum_required (VERSION 2.8.4) # This version was released 2011-02-16 20 | 21 | # (7) Set the default "real" precision. This should probably be left 22 | # at 2 (double). 23 | set (GEOGRAPHICLIB_PRECISION 2 CACHE STRING 24 | "Precision: 1 = float, 2 = double, 3 = extended, 4 = quadruple, 5 = variable") 25 | set_property (CACHE GEOGRAPHICLIB_PRECISION PROPERTY STRINGS 1 2 3 4 5) 26 | 27 | 28 | set (LIBNAME Geographic) 29 | 30 | include_directories( 31 | ./include/ 32 | ) 33 | 34 | add_library(libGeographiccc src/LocalCartesian.cpp 35 | src/Geocentric.cpp 36 | src/Math.cpp) -------------------------------------------------------------------------------- /imu_gps_encoder_msckf/src/readKaistDataset/third_party/GeographicLib/include/Config.h: -------------------------------------------------------------------------------- 1 | // This will be overwritten by ./configure 2 | 3 | #define GEOGRAPHICLIB_VERSION_STRING "1.49" 4 | #define GEOGRAPHICLIB_VERSION_MAJOR 1 5 | #define GEOGRAPHICLIB_VERSION_MINOR 49 6 | #define GEOGRAPHICLIB_VERSION_PATCH 0 7 | 8 | // Undefine HAVE_LONG_DOUBLE if this type is unknown to the compiler 9 | #define GEOGRAPHICLIB_HAVE_LONG_DOUBLE 1 10 | 11 | // Define WORDS_BIGENDIAN to be 1 if your machine is big endian 12 | /* #undef WORDS_BIGENDIAN */ 13 | -------------------------------------------------------------------------------- /imu_gps_localization/.vscode/c_cpp_properties.json: -------------------------------------------------------------------------------- 1 | { 2 | "configurations": [ 3 | { 4 | "name": "Linux", 5 | "includePath": [ 6 | "${workspaceFolder}/**", 7 | "/opt/ros/kinetic/include", 8 | "/usr/include/eigen3" 9 | ], 10 | "defines": [], 11 | "compilerPath": "/usr/bin/clang-4.0", 12 | "cStandard": "c11", 13 | "cppStandard": "c++17", 14 | "intelliSenseMode": "clang-x64" 15 | } 16 | ], 17 | "version": 4 18 | } -------------------------------------------------------------------------------- /imu_gps_localization/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 2.8.3) 2 | project(imu_gps_localization) 3 | 4 | add_compile_options(-std=c++14) 5 | 6 | ## Find catkin macros and libraries 7 | find_package(catkin REQUIRED COMPONENTS 8 | roscpp 9 | nav_msgs 10 | ) 11 | 12 | catkin_package() 13 | 14 | add_subdirectory(imu_gps_localizer) 15 | 16 | include_directories( 17 | ${catkin_INCLUDE_DIRS} 18 | ${EIGEN3_INCLUDE_DIR} 19 | imu_gps_localizer/include 20 | ros_wrapper/include 21 | ) 22 | 23 | add_library(ros_wrapper_lib 24 | ros_wrapper/src/localization_wrapper.cpp 25 | ) 26 | target_link_libraries(ros_wrapper_lib 27 | ${catkin_LIBRARIES} 28 | imu_gps_localizer_lib 29 | glog 30 | ) 31 | 32 | ## Localization node. 33 | add_executable(${PROJECT_NAME}_node ros_wrapper/src/localization_node.cpp) 34 | target_link_libraries(${PROJECT_NAME}_node 35 | ros_wrapper_lib 36 | ) 37 | -------------------------------------------------------------------------------- /imu_gps_localization/README.md: -------------------------------------------------------------------------------- 1 | # IMU & GPS localization 2 | ## Using EKF to fuse IMU and GPS data to achieve global localization. 3 | ### The code is implemented base on the book "Quaterniond kinematics for the error-state Kalman filter" 4 | 5 | ![image](https://github.com/ydsf16/imu_gps_localization/blob/master/doc/path.png) 6 | 7 | ## For details, please refer to:https://zhuanlan.zhihu.com/p/152662055 8 | 9 | ## Dataset 10 | https://epan-utbm.github.io/utbm_robocar_dataset/ 11 | 12 | For any issues, please feel free to contact **[Dongsheng Yang](https://github.com/ydsf16)**: 13 | -------------------------------------------------------------------------------- /imu_gps_localization/doc/path.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/imu_gps_localization/doc/path.png -------------------------------------------------------------------------------- /imu_gps_localization/imu_gps_localizer/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 2.8.3) 2 | project(imu_gps_localizer) 3 | 4 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++14") 5 | 6 | find_package(Eigen3 REQUIRED) 7 | 8 | find_package(OpenCV REQUIRED) 9 | 10 | # Add GeographicLib. 11 | add_subdirectory(third_party/GeographicLib) 12 | 13 | include_directories( 14 | include 15 | ${EIGEN3_INCLUDE_DIR} 16 | third_party/GeographicLib/include 17 | ) 18 | 19 | add_library(imu_gps_localizer_lib 20 | src/imu_gps_localizer.cpp 21 | src/initializer.cpp 22 | src/imu_processor.cpp 23 | src/gps_processor.cpp 24 | ) 25 | 26 | target_link_libraries(imu_gps_localizer_lib 27 | ${EIGEN3_LIBS} 28 | libGeographiccc 29 | ${OpenCV_LIBS} 30 | ) -------------------------------------------------------------------------------- /imu_gps_localization/imu_gps_localizer/include/imu_gps_localizer/base_type.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | namespace ImuGpsLocalization { 7 | 8 | struct ImuData { 9 | double timestamp; // In second. 10 | 11 | Eigen::Vector3d acc; // Acceleration in m/s^2 12 | Eigen::Vector3d gyro; // Angular velocity in radian/s. 13 | }; 14 | using ImuDataPtr = std::shared_ptr; 15 | 16 | struct GpsPositionData { 17 | double timestamp; // In second. 18 | 19 | Eigen::Vector3d lla; // Latitude in degree, longitude in degree, and altitude in meter. 20 | Eigen::Matrix3d cov; // Covariance in m^2. 21 | }; 22 | using GpsPositionDataPtr = std::shared_ptr; 23 | 24 | struct State { 25 | double timestamp; 26 | 27 | Eigen::Vector3d lla; // WGS84 position. 28 | Eigen::Vector3d G_p_I; // The original point of the IMU frame in the Global frame. 29 | Eigen::Vector3d G_v_I; // The velocity original point of the IMU frame in the Global frame. 30 | Eigen::Matrix3d G_R_I; // The rotation from the IMU frame to the Global frame. 31 | Eigen::Vector3d acc_bias; // The bias of the acceleration sensor. 32 | Eigen::Vector3d gyro_bias; // The bias of the gyroscope sensor. 33 | 34 | // Covariance. 35 | Eigen::Matrix cov; 36 | 37 | // The imu data. 38 | ImuDataPtr imu_data_ptr; 39 | }; 40 | 41 | } // ImuGpsLocalization -------------------------------------------------------------------------------- /imu_gps_localization/imu_gps_localizer/include/imu_gps_localizer/gps_processor.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | #include 5 | 6 | #include "imu_gps_localizer/base_type.h" 7 | 8 | namespace ImuGpsLocalization { 9 | 10 | class GpsProcessor { 11 | public: 12 | GpsProcessor(const Eigen::Vector3d& I_p_Gps); 13 | 14 | bool UpdateStateByGpsPosition(const Eigen::Vector3d& init_lla, const GpsPositionDataPtr gps_data_ptr, State* state); 15 | 16 | private: 17 | 18 | void SavePose(std::ofstream &ofs, const Eigen::Matrix4d &pose); 19 | 20 | void ComputeJacobianAndResidual(const Eigen::Vector3d& init_lla, 21 | const GpsPositionDataPtr gps_data, 22 | const State& state, 23 | Eigen::Matrix* jacobian, 24 | Eigen::Vector3d* residual); 25 | 26 | const Eigen::Vector3d I_p_Gps_; 27 | std::ofstream file_gps_noise_; 28 | 29 | double gps_count_; 30 | 31 | }; 32 | 33 | void AddDeltaToState(const Eigen::Matrix& delta_x, State* state); 34 | 35 | } // namespace ImuGpsLocalization -------------------------------------------------------------------------------- /imu_gps_localization/imu_gps_localizer/include/imu_gps_localizer/imu_gps_localizer.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include "imu_gps_localizer/base_type.h" 6 | #include "imu_gps_localizer/gps_processor.h" 7 | #include "imu_gps_localizer/imu_processor.h" 8 | #include "imu_gps_localizer/initializer.h" 9 | 10 | namespace ImuGpsLocalization { 11 | 12 | class ImuGpsLocalizer { 13 | public: 14 | ImuGpsLocalizer(const double acc_noise, const double gyro_noise, 15 | const double acc_bias_noise, const double gyro_bias_noise, 16 | const Eigen::Vector3d& I_p_Gps); 17 | 18 | bool ProcessImuData(const ImuDataPtr imu_data_ptr, State* fused_state, double gps_timestamp); 19 | 20 | bool ProcessGpsPositionData(const GpsPositionDataPtr gps_data_ptr, State* fused_state); 21 | 22 | private: 23 | std::unique_ptr initializer_; 24 | std::unique_ptr imu_processor_; 25 | std::unique_ptr gps_processor_; 26 | 27 | bool initialized_; 28 | Eigen::Vector3d init_lla_; // The initial reference gps point. 29 | State state_; 30 | }; 31 | 32 | } // namespace ImuGpsLocalization -------------------------------------------------------------------------------- /imu_gps_localization/imu_gps_localizer/include/imu_gps_localizer/imu_processor.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "imu_gps_localizer/base_type.h" 4 | 5 | namespace ImuGpsLocalization { 6 | 7 | class ImuProcessor{ 8 | public: 9 | ImuProcessor(const double acc_noise, const double gyro_noise, 10 | const double acc_bias_noise, const double gyro_bias_noise, 11 | const Eigen::Vector3d& gravity); 12 | 13 | void Predict(const ImuDataPtr last_imu, const ImuDataPtr cur_imu, State* state, double gps_timestamp); 14 | 15 | private: 16 | const double acc_noise_; 17 | const double gyro_noise_; 18 | const double acc_bias_noise_; 19 | const double gyro_bias_noise_; 20 | 21 | const Eigen::Vector3d gravity_; 22 | }; 23 | 24 | } // namespace ImuGpsLocalization -------------------------------------------------------------------------------- /imu_gps_localization/imu_gps_localizer/include/imu_gps_localizer/initializer.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include 4 | 5 | #include "imu_gps_localizer/base_type.h" 6 | 7 | namespace ImuGpsLocalization { 8 | 9 | constexpr int kImuDataBufferLength = 100; 10 | constexpr int kAccStdLimit = 3.; 11 | 12 | class Initializer { 13 | public: 14 | Initializer(const Eigen::Vector3d& init_I_p_Gps); 15 | 16 | void AddImuData(const ImuDataPtr imu_data_ptr); 17 | 18 | bool AddGpsPositionData(const GpsPositionDataPtr gps_data_ptr, State* state); 19 | 20 | private: 21 | bool ComputeG_R_IFromImuData(Eigen::Matrix3d* G_R_I); 22 | 23 | Eigen::Vector3d init_I_p_Gps_; 24 | std::deque imu_buffer_; 25 | }; 26 | 27 | } // namespace ImuGpsLocalization -------------------------------------------------------------------------------- /imu_gps_localization/imu_gps_localizer/third_party/GeographicLib/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project (GeographicLib) 2 | 3 | # Version information 4 | set (PROJECT_VERSION_MAJOR 1) 5 | set (PROJECT_VERSION_MINOR 49) 6 | set (PROJECT_VERSION_PATCH 0) 7 | set (PROJECT_VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}") 8 | if (PROJECT_VERSION_PATCH GREATER 0) 9 | set (PROJECT_VERSION "${PROJECT_VERSION}.${PROJECT_VERSION_PATCH}") 10 | endif () 11 | 12 | # The library version tracks the numbering given by libtool in the 13 | # autoconf set up. 14 | set (LIBVERSION_API 17) 15 | set (LIBVERSION_BUILD 17.1.2) 16 | string (TOLOWER ${PROJECT_NAME} PROJECT_NAME_LOWER) 17 | string (TOUPPER ${PROJECT_NAME} PROJECT_NAME_UPPER) 18 | 19 | cmake_minimum_required (VERSION 2.8.4) # This version was released 2011-02-16 20 | 21 | # (7) Set the default "real" precision. This should probably be left 22 | # at 2 (double). 23 | set (GEOGRAPHICLIB_PRECISION 2 CACHE STRING 24 | "Precision: 1 = float, 2 = double, 3 = extended, 4 = quadruple, 5 = variable") 25 | set_property (CACHE GEOGRAPHICLIB_PRECISION PROPERTY STRINGS 1 2 3 4 5) 26 | 27 | 28 | set (LIBNAME Geographic) 29 | 30 | include_directories( 31 | ./include/ 32 | ) 33 | 34 | add_library(libGeographiccc src/LocalCartesian.cpp 35 | src/Geocentric.cpp 36 | src/Math.cpp) -------------------------------------------------------------------------------- /imu_gps_localization/imu_gps_localizer/third_party/GeographicLib/include/Config.h: -------------------------------------------------------------------------------- 1 | // This will be overwritten by ./configure 2 | 3 | #define GEOGRAPHICLIB_VERSION_STRING "1.49" 4 | #define GEOGRAPHICLIB_VERSION_MAJOR 1 5 | #define GEOGRAPHICLIB_VERSION_MINOR 49 6 | #define GEOGRAPHICLIB_VERSION_PATCH 0 7 | 8 | // Undefine HAVE_LONG_DOUBLE if this type is unknown to the compiler 9 | #define GEOGRAPHICLIB_HAVE_LONG_DOUBLE 1 10 | 11 | // Define WORDS_BIGENDIAN to be 1 if your machine is big endian 12 | /* #undef WORDS_BIGENDIAN */ 13 | -------------------------------------------------------------------------------- /imu_gps_localization/ros_wrapper/launch/imu_gps_localization.launch: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 25 | 26 | 27 | -------------------------------------------------------------------------------- /imu_gps_localization/ros_wrapper/src/localization_node.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | 3 | #include 4 | #include 5 | #include 6 | #include 7 | 8 | #include "localization_wrapper.h" 9 | 10 | int main (int argc, char** argv) { 11 | // Set glog. 12 | FLAGS_colorlogtostderr = true; 13 | 14 | // Initialize ros. 15 | ros::init(argc, argv, "imu_gps_localization"); 16 | ros::NodeHandle nh; 17 | 18 | // Initialize localizer. 19 | LocalizationWrapper localizer(nh); 20 | 21 | ros::spin(); 22 | return 1; 23 | } -------------------------------------------------------------------------------- /results/TinyGrapeKit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/results/TinyGrapeKit.png -------------------------------------------------------------------------------- /results/imu_gps_encoder_msckf.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/results/imu_gps_encoder_msckf.png -------------------------------------------------------------------------------- /results/imu_gps_localization.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/zhouyong1234/Multi-Sensor-Fusion-Frameworks/7ea215acce74dca6258b5521b7fd8feaccb295a7/results/imu_gps_localization.png --------------------------------------------------------------------------------