Log in

View Full Version : Super(), Analyze(), and SmoothFps() details


markfilipak
27th September 2021, 19:38
Forgive me please if there's a detailed guide I've not found.

First, a metaquestion: Is this the place for on-the-edge development?

To the developers (or anyone who cares to burrow through and really understand the source code):

__________
__ | __ 5|
__ | |__ 4| |
__ | __ | 3| | Regarding block images:
__ | __ 2|| | Assume block 0 (in frame 'N') & block 5 (in frame 'N+1') form a search-found block pair in a 24fps source.
___|______ 1| |__________| Blocks 1..4 are to be inserted for make a 120fps target.
| 0| __| Are 1..4 copies of 0, or do the block images warp: 0 > 1 > 2 > 3 > 4 > 5?
| | __| If they warp, are the inserted blocks always interpolated between 0 & 5 by proportional parts as shown to the left, or
| | __| are they incrementally interpolated as shown below?
| | __|
|__________| __________ __________ __________ __________
| 5| | 5| | 5| __ | __ 5|
| | | | __ |__ | ___|___|__ 4| |
| | __ __ | | ___|______ | 3| | | 3| |
__ __ | | ___|______ 2|| | | 2|| | | | |
___|______ 1| |__________| | 1| |__________| | ||__________| | |_______|
| 0| | | | | | | __|
| | | | | | __| |__________|
| | | | __| |__________|
| | __| |__________| __________
|__________| __ __ | 10|
__ __ | 9|| |
__ __ | 8| | |
__ __ | 7| | |
__________ | 6| |__________|
__ | __ 5| |__ __| Regarding interpolated block positions:
__ | |__ 4| | |__ __| Are interpolated blocks positioned linearly as shown to the left, or
__ | __ | 3| | |__ __| are they spline positioned based on 'ballistics' as shown below?
__ | __ 2|| ||__ __|
___|______ 1| |__________| __________
| 0| __| __ __ | 10|
| | __| __ __ | 9| | |
| | __| __ |__ 8| | |
| | __| __ | __ 7| | |
|__________| _____|____ 6| |__________|
__ | __ 5| |__ __|
__ | __ 4| | |__ __|
__ | __ 3| ||__ __|
__| __ 2| | | __|
__|_______ 1| |__________|
| 0| __|
| | __|
| | __|
| |__|
|__________|

Is this important?
For frustrating, trial-&-error diddling of Super(), Analyze(), and SmoothFps()? Probably not.
For intellengently interpreting experimental results visually? I think so.

StainlessS
28th September 2021, 12:31
See all of this thread:- https://forum.doom9.org/showthread.php?t=175373
this one too:- https://forum.doom9.org/showthread.php?p=1789723#post1789723
(also take a peek at all links in both threads)

50%
|
<--------->
| |
v v
G1 G2 G3 B4 G5 G6
n n+1 n+2

delta=2
Frame n synth frame created using bidirectional vectors between n and n+delta(2),
however, frame requiring fixing is n+1 (B4, 50% between n and n+2) and so requires shift over. Frames are synthesised
from point of view of the synth frames not the bad frame.
Synth frame to fix B4 @ 50% is generated still at frame n (reqires shift forward 1 frame replacing n+1)


33% 66%
| |
<--------------->
| |
v v
G1 G2 G3 B4 B5 G6 G7
n n+1 n+2 n+3

delta=3
Synth frame to fix B4 (@ 33% of the way between n and n+3) is generated still at frame n (reqires shift forward 1 frames replacing n+1)
Synth frame to fix B5 (@ 66% of the way between n and n+3) is generated still at frame n (reqires shift forward 2 frames replacing n+2)
The 'between' percentage does NOT need to be directionally worked out by the user, it is looked after by MVTools
and governed again by isb, percentage is relative the synth frame n->n+delta.


EDIT:
also

n n+delta
| |
<---- BV Vectors used for eg MDegrain, vectors stored @ frame where arrowhead points (ie n).
FV ----> Pixels moved from frame at back end of arrow (n+/- delta), along vector to synth frame where arrowhead points.
|
n-delta


n n+delta
| |
<---- BV Vectors used for eg MFlowInter, Uses the next one along forward vector so that vectors used are from
| | either side of the frame that will be synthesized (reason, only part of the vector distances are
FVI ----> used, based on Time arg).
n n+delta
For MFlowInter, the created vectors are exactly the same as for eg MDegrain, its just that it uses the
next forward vector so that backward and forward vectors straddle the predicted frame, MFlowInter
just uses the vectors in a slightly different way to MDegrain.
The synthesized frame lies logically somewhere between n and n + delta (based on Time arg), and is
physically created at frame n, and so needs to be relocated to the required bad frame position in clip.

zorr
28th September 2021, 20:30
See all of this thread:- https://forum.doom9.org/showthread.php?t=175373


Ah, my first thread. Brings back memories... *snif*

StainlessS
29th September 2021, 01:48
Nah, a horrible nightmare... *snort*

markfilipak
29th September 2021, 06:17
See all of this thread:- https://forum.doom9.org/showthread.php?t=175373
this one too:- https://forum.doom9.org/showthread.php?p=1789723#post1789723
(also take a peek at all links in both threads) ...

I didn't understand any of that stuff. Sorry. 'B', 'G' ? I couldn't tell which frames are original and which are interpolated -- too cryptic.

StainlessS
29th September 2021, 12:41
I'm terrible at explaining things, now Zorr, he's the man that can :)

gispos
29th September 2021, 17:47
I'm terrible at explaining things, ...
I have to agree with you, if I understand it to 80%, after your explanations I only understand 50% :D

You have written so many useful Avishynth functions I do not always understand completely (or my English is too bad).:)
Seriously, sometimes I read and read and then I'm puzzling what the thing can do.:D

StainlessS
29th September 2021, 18:00
Well maybe Zorr could explain them too, then.
[ Anything that needs explanation PM Zorr about it, he's always happy to help :) ]

EDIT:
If they warp, are the inserted blocks always interpolated between 0 & 5 by proportional parts ...
Yes.

Are interpolated blocks positioned linearly ...
Yes.

Blocks are moved along the vectors proportional to the required time, if they dont match well in both directions [fwd/bkwrd] then some blurring will result.
EDIT: Ballistics, change in velocity (acceleration), change in acceleration (jerk), are not considered [linear only, I think].

zorr
30th September 2021, 20:00
[ Anything that needs explanation PM Zorr about it, he's always happy to help :) ]

Yes, and if you want to ask about your local bus time tables, the latest mens swimsuit fashion trends or just some chitchat about the nature of reality PM StainlessS about it, he's always happy to talk about those. :D

StainlessS
30th September 2021, 20:16
OK, you win, I'm sorry.

zorr
30th September 2021, 22:26
OK, you win, I'm sorry.

Nah, no harm done. I do like to help people but most of my time these days is devoted to a completely new project (yes, AviSynth / VapourSynth related).

StainlessS
30th September 2021, 22:31
Evil, pure evil!

ChaosKing
30th September 2021, 22:39
Nah, no harm done. I do like to help people but most of my time these days is devoted to a completely new project (yes, AviSynth / VapourSynth related).

Do I smell Zopti2? :D

kedautinh12
1st October 2021, 00:09
Do I smell Zopti2? :D

I think that DeltaRestore plugin :D