I’m trying to include the OpenGLDrv module into a plugin as I need to access its classes directly.
I’ve tried adding it to my build script
namespace UnrealBuildTool.Rules
{
public class Example: ModuleRules
{
public ExamplePlugin(TargetInfo Target)
{
AddThirdPartyPrivateStaticDependencies(Target, "Example");
PublicDependencyModuleNames.AddRange(
new string[]
{
"Core",
"CoreUObject",
"Engine",
"RHI",
"RenderCore",
"OpenGLDrv",
// ... add other public dependencies that you statically link with here ...
}
);
}
}
}
Then I add OpenGLWindows.h to my includes using with “Private/Windows/OpenGLWindows.h”. Which give me the error
Error 1 error C1083: Cannot open include file: ‘GL/glcorearb.h’: No such file or directory …Engine\Source\Runtime\OpenGLDrv\Private\Windows\OpenGLWindows.h 15 1 UE4
These are the includes in OpenGLWindows.h
#include "Windows/MinWindows.h"
#include "AllowWindowsPlatformTypes.h"
#include <GL/glcorearb.h>
#include <GL/glext.h>
#include <GL/wglext.h>
#include "HideWindowsPlatformTypes.h"