Unrecognized Type 'IBody'

I have been attempting to export the Kinect Face Basics-D2D code into an Unreal Project. However, upon building the code Visual Studio fails to build, stating “error code: OtherCompilationError (5)”. Analysing the output log indicates that this is due to an unrecognized type “IBody” in the given “Kinect.h” file; namely, on the following line:

virtual void UpdateBodyData(IBody** ppBodies);

Said line has the following error: “Unrecognized type ‘IBody’ - type must be a UCLASS, USTRUCT or UENUM”

I attempted to change the declaration of IBody in “Kinect.h” to a USTRUCT by modifying the declaration:

IBody: public IUnknown

     //member declaration after this - UNMODIFIED FROM KINECT.H

However, this still results in the same error. Has anyone experienced this or a similar error before, or would anyone be able to shed any light on this problem?

Reflection system only supports types in UE4 modules, so you can’t use external types in arguments of UFUNCTION() not to mention reflection system does not support pointer to pointer types (double *). If you want to use IBody you need to remove UFUNCTION() and make nonreflected function.

If you want use IBody in reflected function argument you need to make wrapping UE4 type and convert to it.

Thank you for your prompt answer. One last question; what do you mean by “wrapping UE4 type”? Apologies if this is a relatively foolish question, I am new to Unreal.

Convert it unsupported type in to supported type by reflection system. Make struct FKinectBody which you can use with USTRUCT and copy varables from IBody in to it.