===== Using the Swabian Instruments TimeTagger library in C++ =====

The examples in this directory demonstrate how to make use of the TimeTagger
C++ library.

==== CMake (Windows/Linux) ====

The TimeTagger library can be easily integrated into a CMake-built project
using the standard procedure:
  find_package(TimeTagger)
  target_link_libraries(YourProject PRIVATE TimeTagger)

Steps required to build the examples:

1. $ cmake -S <examples_src> -B <build_dir>

In this line, replace <examples_src> with the path to this directory (by
default "/usr/share/timetagger/examples/cpp" and "C:\Program Files\Swabian Instruments\Time Tagger\examples\cpp" for Linux and Windows, respectively) and <build_dir> with a
(possibly not yet existing) directory of your choice in which the executables
will be located.

2. $ cmake --build <build_dir>

==== Visual Studio (Windows) ====

Compiler Requirements
* Microsoft Visual C++ (MSVC), Intel C++ Compiler (ICC) or Clang

We provide the import library (.lib) and the shared library (.dll) for two C++ ABIs.
Please link your application statically to the import library.
* TimeTagger.lib / TimeTagger.dll for MultiThreadedDLL /MD (Microsoft Runtime Library)
* TimeTaggerD.lib / TimeTaggerD.dll for MultiThreadedDebugDLL /MDd (Microsoft Runtime Library)

Both libraries require that the final application is linked to at least version v143 of the Visual Studio platform toolset (default in Visual Studio 2022).

The following include path must be added:
* $(TIMETAGGER_INSTALL_PATH)\driver\include

and the for 64 bit the following library path:
* $(TIMETAGGER_INSTALL_PATH)\driver\include\x64

An example project for Microsoft Visual Studio can be found in the folder of the Readme:
* Quickstart.vcxproj
