How to get absolute actor velocity (cine camera actor)?

Hey. How to get velocity of camera animated in sequencer? I used “get all actors of class with tag” and then “get velocty” but issue with this workflow is that it doesnt account for parents. I wanted to use “get world location” and then with delay node calculate difference but I dont know how to use this delay node with “get world location”. When printing init pos and previous pos are the same, animation is working, cuz value itself is changing, seems like this delay step is not working properly

Hi there @Edziu_Listonosz,

What is the context here? What do you need the velocity for? There is a Get Velocity node that automatically does the calculations for you.

If you give me more information, I can help you set up the effect you’re trying to achieve.

Hey, thanks for the answer! I should mention that this isn’t for a game—I’m a Houdini/Python guy with very basic knowledge of Blueprints in Unreal. I just wanted to create a quick tool for our artist, who is working on cameras for a cinematic.
Ideally, the tool would display the velocity in the editor, not in-game, but that’s definitely beyond my current understanding of Unreal.
The issue with the “Get Velocity” node is parenting. The camera’s transform is often nested under multiple parents or cranes, and the “Get Velocity” node only seems to read the local transform.

Ahh okay- I see! Yeah, let me help you set that up!

Event ticks don’t really work in editor, so the best way to display this will probably be through an editor utility widget. And it looks like the provided velocity calculations don’t work outside of gameplay, so we’ll have to manually calculate it.



You might have to fix my velocity calculation here- not entirely sure I got it correct.

But this code compares the camera’s location at the last frame vs the current one, then multiplies it by 30 (assuming 30fps) to get the velocity in seconds. Instead of the “Get Actor of Class”, you can use your tag.

Let me know if that helps!

Oh great, that definitely helps! I understand the logic, and reading it from the Sequencer is perfect. I didn’t know about those functions.

The only problem I have is when the camera is spawnable.
Do you have any idea why this Actor selection doesn’t work when the camera is spawnable?
Is there an alternative way to do it?

With my previous approach—getting an array of actors with a tag—it still doesn’t work for a spawnable camera.

EDIT: Ou, and when using crane rig it doesnt work. When parenting to null its fine but with crane unfortunately its not

Just heads up…

Tick Event fires every frame.

Your delay is 500ms which is the equivalent of 30 frames/ticks at 60FPS.
So How does an event that is supposed to execute once every single tick pause execution of code for 30 ticks?

It won’t. The delay in most cases will be ignored as with executing any code behind it. If there is execution it will be corrupt. The very next frame will execute tick which calls the delay node thus overwriting the previous delay.

1 Like

Yeah, that would check out. This logic creates the association when the widget is created, so if the camera does not exist yet, the association will fail.

This should fix the issue:

I moved the logic to find the camera and sequence to the first tick when the active sequence is playing, to guarantee it exists when setting the association.

Be warned, the Get All Actors With Tag is a very expensive function. Given its use here, I would say keep it for ease of use for your artists, but just know that it may cause a slight lag on your first played frame if there are a lot of actors in your scene, as this node has to filter through all actors in the level and check for this tag. The reason I suggest you keep it is because the alternative is having your artist manually select the camera to track, which I would not recommend.

That’s very helpful, thank you. Regarding this crane, my current workaround is to duplicate the camera and bake its transforms. It’s not perfect, but it works for our use case for now.

However, I have a bigger problem—maybe you know the answer. When I nest sequences like this, it doesn’t work properly. It works fine for the first camera, but when I add more than one shot, the view starts jumping and switching unexpectedly. This blueprint is breaking timeline scrubbing.

Do you have any idea why this might be happening? It seems like it’s having trouble getting the active sequence.


I’m printing the camera name, and the current camera is being detected properly

EDIT: Okay, displaying the current level sequence reveals the root of the problem, I think. It shows the master sequence instead of the subsequence. Do you have any idea how to change this behavior so it shows the current subsequence?
EDIT2:Hmm, I found ‘Get Focused Level Sequence’, and now the current level sequence is being detected properly. However, when changing frames, the viewport still jumps and doesn’t display the speed correctly. If you’re interested, I’m including a link to a simple project I’ve made to demonstrate this behavior.

Okay, I downloaded your project and I’m seeing the issue. Now solving it… having some issues there.

For the issue with the crane, yeah realistically I think you found the best solution. The camera is a component on the crane blueprint, and the blueprints can only track the actor transformation between ticks.

As for the root sequence issue, I looked forever and found nothing. It seems like the Shots are a different asset type that serve as a container for the actual sequences, and there is nothing exposed to Python/Blueprints that lets you find these. It seems that even by force-setting the level sequence association, it is still not able to find the camera.

Sorry I couldn’t be more help. It seems like the Sequencer tooling is unfortunately still very limited. I’ll let you know if I come across anything else.

1 Like

Hi again @Edziu_Listonosz,

Actually, try this:

This will give you results that are less smooth but I think the trade off is worth it. This calculates the velocity completely outside of sequencer, decoupling it from any of the sequencer track nonsense.

The other benefit of this method is that since it tracks components, you can now track the location of the camera component on your crane without having to use your workaround. You can just grab the camera component directly from your tagged actor. Also, now this can be done on text changed again so you don’t have to worry about the lag.

1 Like

Hey, thank you! It looks like my initial approach, but I didn’t know how to read from the past. I tried using a delay and subtracting positions, but Rev0verDrive mentioned earlier it was something different. Now I see I should use delta time, thanks! What do you mean with last sentence about being done on text change and lag? Im gettin all actors of class on text change event, not event tick

1 Like