'Unresolved external symbol' calling a static function from a plugin

anonymous_user_c3e69a5a
Mon, 21 Jan 2019 12:27:56 +0000
Plugins

Hi,

I have a plugin (from Stereolabs to access a stereocamera in unreal) and another one to access the PointCloudLibrary (pcl).

In an Actor class in my game I want to access a static method I wrote in the Stereolabs plugin:
static ESlRetrieveResult GetPointCloudAtRoi(FBox2D ROI, pcl::PointCloud<pcl::PointXYZRGBNormal>::Ptr & PointcloudOut, float MinConfidence = 0, float MaxConfidence = 100);

I cannot make this a UFunction, because the Pointcloud Pointer is not known by unreal. But as it is a public static method I should be able to access it like this:

bool AZedPointcloudFactory::GetPointcloudFromZED(FBox2D ROI)
{
	ESlRetrieveResult result = UZEDFunctionLibrary::GetPointCloudAtRoi(ROI, Pointcloud, MinConfidence, MaxConfidence);
	return result == ESlRetrieveResult::RR_RetrieveValid;
}

But when I try to compile, i get this error:

unresolved external symbol “__declspec(dllimport) public: static enum ESlRetrieveResult __cdecl UZEDFunctionLibrary::GetPointCloudAtRoi(struct FBox2D,class boost::shared_ptr > &,float,float)” …

I did include the Plugin Modules in my Game.Build.cs and when I call another static Method (being a UFunction this time) from the UZEDFunctionLibrary, everything is fine.

Do you know if this is because one is a UFunction and the other one isnt? Or what else could case this issue?
Thanks for any help!

4 posts - 3 participants