Slow motion effect problem

Hi, I’m going to make a slow motion filter but without the blur mode I designed the filter so that from the moment you tap the screen for one second the frames start to freeze and 26 frames are made, then to play the 26 frames in 3 second I connected them frame by frame to the picker option and started playing them with animation and transition, but the problem was that the moment the frames were played, they were out of the frozen state, so I had to create one rectangle for each frame. I made 26 rectangles and started to make them visible and invisible with the same picker option. In such a case, the effect worked very slowly when working due to the large number of rectangles, can any one help me?

I did a lot of research to solve this problem I only found a project called frame cache from Josh but I do not have this project and I can not use it,
slow (246.0 KB)

This is my project file

Usually things will get slow if you have a lot of rects. You can do it with just one rect if you change the option picker to use textures instead of the numbers. Then you can get rid of all of that “equals” logic after that step.

Yes, I did, but the problem with this is that when you hit the screen, the frames come out of freeze and slow motion does not work.

In fact, after one second that 26 frames are extracted, the frames come out of the freezing state exactly when they are played.

You will run out of frames to play eventually. Are you trying to make it go in slow motion forever? A boomerang effect could work, but you would need to do a recording phase and then a playback phase that would loop back and forth.

I think Dennis Rossiev made a slowmo effect that could be good reference for you. His technique was to make it go in slow motion for a while and then speed up afterwards to catch up to the current time.

I’m familiar with their effect, I’m going to make an effect similar to it, but not exactly like it, with differences that can turn it into a functional effect, their effect does not lose any frame, and that’s great. . But to create a similar effect, the first challenge is to get the frozen frames at the specified moment, then the challenge of syncing them, my problem right now is in the first challenge, which is to temporarily save the frames. The only project presented in this field is the frame cache project A project that I do not have and therefore can not study

The frame cache essentially does what you are doing with the multiple delay frames, but it only uses a single texture to store all of the information. It’s not going to solve the problem of getting the frames at a specific time and storing them for later. It stores them on each frame tick, by default - there’s no logic built in there for saving recordings.

But I do think you can take a similar approach and use an index variable to determine if a delay frame should write the current camera texture. This approach is different from what you have with the waterfall/chain of delay frames. You can simply control the writeIndex int to save the frame sequence. Then you can do something similar using a readIndex int to play the sequence back

FWIW I needed to use a little bit of script to get a proper frame tick pulse, using, but even that can be inaccurate on slower devices.

Oh, never mind what I said about the waterfall. You are already doing something similar to what I am suggesting, but hard-coded delay values will be unreliable. You will end up with skipped frames if you do that.

Check out the signal - TimeModule

1 Like

Oh! Or you can simply use the delay value patch and add one to it each time!

Because this effect is so important to me, I did a lot of research on it, and studying the frame cache project can help a lot. And finally, there may be an effect from these studies that at the moment may seem impossible. I hope to be able to achieve this project and achieve it with the study, perseverance and help of friends like you. I try to read your orders carefully and work on them

Using another technique, I was able to keep the frames in a 6x6 texture similar to the frame cache project. Of course, this amount can be changed, for example, it can be converted to 8 * 8 texture Now how do I separate any of these frames from this texture? And whether their quality will decrease after separation?

New technique move an area for take the delay shot like a movie film and use one delay frame

To get a single frame out of that grid, you can define an index, so if you send it a 0, you get the most recent frame. The math for that kind of depends on how you are writing to the texture but in general you will need to do some operations to determine parameters for a texture transform.

The offsets will be something like x = index % numberOfFramesWide and y = Math.floor(index/numberOfFramesWide) and the scale will simply be the frame grid dimensions.

You will have problems with maintaining quality over time with this technique, but it can mostly be mitigated by setting the data type to half float. Also, make sure your render pass size matches the grid dimensions, or you will lose quality if it’s less than that.

Thanks for your help Unfortunately I do not know how to write a script But after a whole search, I was able to separate the desired frame from that texture, but unfortunately I encountered the same problem that I was thinking. The same problem of quality decline While in the size of render pass and frame delay, the number 6 * 6 has been replaced and the data type is on half float.

It might be an issue with your device. Not all devices support half float.