How do I get skin weights in 4.25?

Previously you could get skin weights with:

    const bool bExtraBoneInfluencesT = false;
    TSkinWeightInfo<bExtraBoneInfluencesT>* W = SkinWeights.GetSkinWeightPtr<bExtraBoneInfluencesT>(i);

It appears that they want you to use FSkinWeightInfo W = SkinWeights.GetSkinWeights();
which gives me a linker error.

Any ideas?

Same here, I get a linker error:

error LNK2019: unresolved external symbol "public: struct FSkinWeightInfo __cdecl FSkinWeightVertexBuffer::GetVertexSkinWeights(unsigned int)const " (?GetVertexSkinWeights@FSkinWeightVertexBuffer@@QEBA?AUFSkinWeightInfo@@I@Z)

before Unreal 4.25, adding

“RHI”, “RenderCore”, // for VertexBuffer

in PrivateDependencyModuleNames in Target.cs, was enough. I tried to add a couple of other modules by guessing but no success.

If you look at SkinWeightVertexBuffer.h you can see that the class isn’t exported, only some selected functions are and that’s not one of them.

You’ll have to compile the engine from source with that changed.

Do you have any idea why this decision was made? I’m currently developing a plugin and would like to avoid forcing the users to rebuild the source. Is there any other solution? Is this going to be forever?


No idea on all fronts I’m afraid - but the best you can do is submit a Pull Request to the engine’s Github with those functions exposed and see if Epic integrates it, but if they don’t the only option after that is a source code modification.

That’s unfortunate. I was getting close to slicing up skeletal meshes.

Can you please give an example of what an exported function looks like? I’ve looked through SkinWeightVertexBuffer.h but I don’t see any difference between exported and non exported functions ):

Pretty sure it’s anything with ENGINE_API in front of it.