how to use LibE57 in a project

869 Views Asked by At

first of all I am a beginner with c++, my question is how to use e57 library ( that I got from the official Website ), I have tried almost every tutorial, and I have got different problems, i have tried to install boost, Xerces Eigen ... and Im confused because i dont know how to build them, what changes I must do in my Path variable ..., I really need some help, I will appreciate any kind of help and advice,

my OS : Windows 10

E57 library : C:\dev\E57RefImpl-1.1.312
contains :

bin

built

CHANGES.TXT

E57RefImpl-doc-0.2.60

E57RefImplConfig.cmake

include

lib

README.TXT

..................

Directory of C:\dev\xerces-c-3.1.1-x86_64-windows-vc-10.0

bin

doc

include

INSTALL

lib

LICENSE

NOTICE

README

samples

1

There are 1 best solutions below

0
On

Nowadays you can use vcpkg to install e57 library.

First of all, download vcpkg on your computer by executing in the command line:

git clone https://github.com/Microsoft/vcpkg.git
cd vcpkg
.\bootstrap-vcpkg.bat

Then integrate vcpkg in Visual Studio to get access to the packages without writing full directory paths, specifying .lib files to the linker and copying necessary dynamic libraries in the output folder of the project. This is the only step that requires admin rights:

vcpkg integrate install

Then install the library itself:

vcpkg install libe57format

This step includes building of the library and its dependencies, and it may take about 1-2 minutes on a modern PC.

After that, you can open Visual Studio and start writing your code that uses the library:

#include <E57Format/E57SimpleReader.h>

int main() {
  e57::Reader eReader( "file.e57" );
  ...
}