Boost_PCL_UnrealThirdPartyPlugin icon indicating copy to clipboard operation
Boost_PCL_UnrealThirdPartyPlugin copied to clipboard

Plugin not compiling (forward declaring of ****** is not permitted) [WITH SOLUTION]

Open DarioMazzanti opened this issue 5 years ago • 1 comments

Hi!

First of all, thanks for the plugin: I wanted to try it so I started by compiling it in UE 4.19 using Visual Studio 2017 15.9.7. Unfortunately, that resulted in a lot of errors regarding boost and forward declaration.

Following the suggestion found at this link I managed to compile the plugin: https://stackoverflow.com/questions/51863797/new-vs-c-update-is-making-boost-forward-declared-code-un-compilable-what-can

The fix/workaround was to add #pragma warning(disable : 4643) before including boost headers in the PointCloudRenderer.cpp file, like so:

[...]
THIRD_PARTY_INCLUDES_START
#pragma warning( disable : 4643 )  // <----this line
#include <pcl/io/pcd_io.h>
#include <pcl/point_types.h>
#include <boost/shared_ptr.hpp>
THIRD_PARTY_INCLUDES_END
[...]

I think this should be repeated wherever including boost/pcl headers - maybe I will find out more while developing with boost/pcl in Unreal in the next future.

Thanks again for the plugin! : )

DarioMazzanti avatar Jun 21 '19 15:06 DarioMazzanti

I did not have the error but thanks for your solution!

ValentinKraft avatar Jul 03 '19 13:07 ValentinKraft