Trying to add a DrawFrustumComponent to a custom actor, I get the following error during linking:
error LNK2019: unresolved external symbol "public: static class UClass * __cdecl UDrawFrustumComponent::GetPrivateStaticClass(wchar_t const *)" (?GetPrivateStaticClass@UDrawFrustumComponent@@SAPEAVUClass@@PEB_W@Z) referenced in function "public: class UDrawFrustumComponent * __cdecl FPostConstructInitializeProperties::CreateDefaultSubobject(class UObject *,class FName,bool,bool)const " (??$CreateDefaultSubobject@VUDrawFrustumComponent@@V1@@FPostConstructInitializeProperties@@QEBAPEAVUDrawFrustumComponent@@PEAVUObject@@VFName@@_N2@Z)
It seems it has something to do with the creation of the component as the error goes away if I remove the following line:
DrawNearDOF = PCIP.CreateDefaultSubobject(this,FName("Near DOF"));
#No it’s not in Beta6
I just checked and no it did not make it into Beta6
Thanks for the report! Just wanted to let you know that I’ve found the issue and fixed it internally. In the meantime, the DrawDebugFrustum workaround seems like a reasonable approach.
Hi Jeff, did this make it to beta 6?
Nope, Beta6 was deep in the pipe when this fix went in, sorry. The next release should have it.
I dont think you can do anything about this in current rocket version based on this part:
UDrawFrustumComponent::GetPrivateStaticClass(wchar_t const *)
you have to wait for Epic to expose this to Rocket Users so compiler finds the class
You know you can draw a debug view frustrum right?
you could probably get a workaround for your current goal that way
ENGINE_API void DrawDebugFrustum(const UWorld* InWorld, const FMatrix& FrustumToWorld, FColor const& Color, bool bPersistentLines = false, float LifeTime=-1.f, uint8 DepthPriority = 0);
PS: in case you get hungry:
ENGINE_API void DrawDebug2DDonut(const UWorld* InWorld, const FMatrix& TransformMatrix, float InnerRadius, float OuterRadius, int32 Segments, const FColor& Color, bool bPersistentLines = false, float LifeTime=-1.f, uint8 DepthPriority = 0);