UE4.21+VS2017配置OpenCV-Plugin

2021-11-10 15:10:05 浏览数 (1)

1.在建立c 文件后导入插件 https://github.com/Brandon-Wilson/OpenCV-Plugin,记得导入Binaries和ThirdParty文件; 2.修改opencv.build.cs文件如下:

代码语言:javascript复制
using UnrealBuildTool;
using System.IO;

public class OpenCV : ModuleRules
{
    private string ThirdPartyPath
    {
        get { return Path.GetFullPath(Path.Combine(ModuleDirectory, "../../../../ThirdParty/")); }
    }

    public OpenCV(ReadOnlyTargetRules Target) : base(Target)
    {
        //20191015 BY:Ning 
        PrivatePCHHeaderFile = "Private/OpenCVPrivatePCH.h";

        // Startard Module Dependencies
        PublicDependencyModuleNames.AddRange(new string[] { "Core", "RHI", "RenderCore" });
        PrivateDependencyModuleNames.AddRange(new string[] { "CoreUObject", "Engine", "Slate", "SlateCore" });

        // Start OpenCV linking here!
        bool isLibrarySupported = false;

        // Creat

0 人点赞