This one
It’s expected to return the frame number of the next/previous frame marker found, but it always returns 0 or 1 depending on the “forward” condition.
Seems like a bug. (UE 5.1)
Anyone has made it work?
This one
It’s expected to return the frame number of the next/previous frame marker found, but it always returns 0 or 1 depending on the “forward” condition.
Seems like a bug. (UE 5.1)
Anyone has made it work?
This finds the next marked frame from the In Frame Number Value that you give it. Have you tried giving it something other than 0?
Of course. I’m giving frame number values in the middle of a sequence plenty of markers Actually, i’m feeding the InFrameNumber value with a Sequence player->GetCurrent Time.
Does it work for you?
Edit: I’ve made some captures. I may be doing something wrong (usually)
This function (with a coouple of PrintString nodes to confirm I’m injecting valid values, and what the node returns).
Returns this
In this sequence
(No big deal, there’s an easy workaround: I’ve added a “Current marker” variable track to the sequence and manually set each point (seen in the image). With that variable and the “Get Marked Frames” node I’ve coded my own “Find Next” and “Find previous” functions.)
For anyone still running into this like me.
Functions like FindNextMarkedFrame
, FindMarkedFrameByLabel
and FindMarkedFrameByFrameNumber
return the index of the marked frame.
Get the full array using GetMarkedFrames
and use the index to get the marked frame object.
(Don’t forget to check for -1, which I didn’t do in this image)
Now you just have to figure out the frame number values.
The values from MarkedFrame -> Frame Number
seem to be multiplied by tickrate and are much higher than sequence frame values.
If you use FindNextMarkedFrame
you won’t get the expected output until you use CurrentFrame * multiplier
as the input.
Based on Find Marked Frame by Frame Number doesn't seem to work properly - #4 by Moeren588, this multiplier is (1/fps)*tickrate
.
For my project at 50fps, this resulted in 480.
An example of how you could calculate this multiplier in a blueprint:
BlueprintUE link for copying nodes:
(using Unreal 5.2.1)
@Dev_HNK , thank you so much for your research and explanation. This absolutely 100% needs to be added to Unreal’s documentation at the very least. A better solution would be for these FindFrame() functions to accept “frameNumber” variables from the SequencePlayer and auto-convert them inside those functions. Nevertheless, we’re grateful you discovering some kind of a solution.
Unreal really needs to step up their technical debt improvements and documentation.
In our testing (using UE 5.3), if the input frameNumber is greater than the frameNumber of the last Marked Frame (using the conversion method you’ve referenced), which means that there are no more Markers, then the FindNextMarkedFrame simply returns the last index in the array.
Example: we provide an “inFrameNumber” value of “3 971 200”. The Marked Frames Array has 3 elements and the last one (index: 2) has a Frame Number value of “3 936 800”. As you can see the Return Value is 2 (meaning, index: 2).