Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

How do I get the bone transforms of a particular Montage frame or time?

Hello, I would like to get the bone locations and rotations of a specific time within a montage, without having my skeleton actually be on that frame/time when animating. I would like this so I can sweep a component alongside the path of the bone with substeps between the frames in case of low framerate, in order to combat the collision inconsistencies that would arise from such a low framerate.

I at first attempted to use the function Montage->GetAnimationPose, as I figured it would do exactly what I want, however, that function is virtual and not actually implemented for montages, and as such calling it would do nothing but cause the engine to crash. Therefore, it is not an option.

Is there an easy way to do such a thing?

EDIT: So I figured out I can pull out something out of the montage called an FAnimTrack using the GetAnimationData function, which does provide a similar function to get a pose at a certain time, presumably for a particular animation slot within the montage. This would actually well enough, but calling that function leads to external linker errors which I have no idea how to fix, and there doesn't seem to be anything online about them, so that kind of sucks. Does anyone have any ideas?

EDIT 2: I assume that solution is a lead balloon as well either way, because upon attempting to copy-paste the function to get around the linker error, the function will more or less just crash anyway, because it requires the Pose and Curve parameter inputs to be initialized first, and I can't seem to find the info I'd need for this readily available through the skeletal mesh or its anim instance.

Perhaps I'm overthinking this. Could there mayhaps be a method to immediately pose a skeletal mesh component using a montage frame without having to wait a frame for blending etc. ? This way, I could spawn a new skeletal mesh component, pose it to the frame I want and get its bone transforms. Any ideas?

Maybe I have to get the pose and curve structs from some function I haven't found yet? Surely it can't be impossible to get an arbritrary frame/pose from within a montage, can it?

Product Version: UE 4.16
more ▼

asked Jun 02 '17 at 09:41 PM in C++ Programming

avatar image

1 1 2

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question