UE4.27 Runtime USD Import

When you try to load usd in runtime with log enabled, there will be a error log :

*LogUsd: Error: The USD SDK is disabled because the executable is not forcing the ansi C allocator (you need to set ‘FORCE_ANSI_ALLOCATOR=1’ as a global definition on your project .Target.cs file). Read the comments at the end of UnrealUSDWrapper.Build.cs for more details.

Accordding to the error log, I add

BuildEnvironment =
TargetBuildEnvironment.Unique;
GlobalDefinitions.Add(“FORCE_ANSI_ALLOCATOR=1”);

Then, you should download your unreal engine from github.com and compile it by your own if you installed 4.27 from epic launcher, otherwise, you will meet another package error.

I gave up in this step because I decieded to switch to DatasmithRuntime to import scene in runtime for vray materials support.

Hope that helps.

1 Like