OpenCV-Plugin icon indicating copy to clipboard operation
OpenCV-Plugin copied to clipboard

Unable to compile in 4.16.2

Open speedpacer opened this issue 7 years ago • 6 comments

Thanks for posting this and writing the tutorials. I'm trying to do something similar with other third party libraries and this has helped a lot. I did run into an issue though. It looks like they've changed the module constructors to accept the argument ReadOnlyTargetRules instead of TargetInfo. I was unable to compile until I made the change in MyProject.Build.cs from this :

public bool LoadMyModule(TargetInfo Target)

to this: public bool LoadMyModule(ReadOnlyTargetRules Target)

Still not sure if everything is working correctly but it compiles now.

speedpacer avatar Jul 20 '17 10:07 speedpacer

I think I was unable to compile for another reason, but this change did resolve a compiler warning.

speedpacer avatar Jul 25 '17 14:07 speedpacer

First of all thank you for the plugin, but now I face some bad situation, I now use the UE4 version is 4.192, I put the inside of the plug-in (Binaries, Plugins, ThirdParty) the three root folder copy to my UE4 project, but later UE4 error, error prompt content as follows: (Running C: / Program Files/Epic19 / Engine/Games/UE_4 Binaries/DotNET/UnrealBuildTool. Exe - projectfiles - project = "D: / UnrealProjects/TestOpenCV TestOpenCV uproject" - game - rocket - the progress Alias modules, targets and source code for project... While the compiling D: \ UnrealProjects \ TestOpenCV/Intermediate/Build/BuildRules \ TestOpenCVModuleRules DLL: ERROR: d:\UnrealProjects, TestOpenCV, Plugins, OpenCV\OpenCV, OpenCV\ opencv. build.cs (16,9) : ERROR CS1729:?UnrealBuildTool. ModuleRules?????????????A?0?????????????Ĺ??캯?? ERROR: d:\UnrealProjects, TestOpenCV, Plugins, OpenCV\OpenCV, OpenCV\ opencv. build.cs (29,83) : ERROR CS0122:?UnrealBuildTool. BuildConfiguration???????ɷ??ʣ???Ϊ???ܱ????????????? ERROR: UnrealBuildTool Exception: Unable to compile source files.)

SIwaxinGe avatar May 31 '18 02:05 SIwaxinGe

Also prompted in vs2017 is the opencv.build.cs script error message :(the severity code indicates that the project file line is not allowed to display status Error d: UnrealProjects, TestOpenCV, Plugins, OpenCV, Source\OpenCV, opencv. build.cs (29,83) : error CS0122:"UnrealBuildTool. BuildConfiguration" inaccessible because it protected level limit TestOpenCV D: \ UnrealProjects \ TestOpenCV \ Intermediate \ ProjectFiles \ UnrealBuildTool 1 I hope you can help me. Thank you very much

SIwaxinGe avatar May 31 '18 02:05 SIwaxinGe

Unable to compile in 4.20,the file opencv. build.cs have too much error

WoodyChina1989 avatar Oct 06 '18 14:10 WoodyChina1989

it's a plugin for UE4 below version 4.16. when you use the higher version, you should do some modification to pluginname.build.cs https://answers.unrealengine.com/questions/764146/view.html hope this can help you.

linjiangwei avatar Dec 04 '18 07:12 linjiangwei

I modified the build script to work on the latest unreal 4.21, hope it helps someone :) https://gist.github.com/PreyK/b56f310b225f2308398706b158913b45

PreyK avatar Mar 05 '19 10:03 PreyK