View Single Post
Old 23rd March 2018, 17:48   #15  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Demo of bar location on 2nd image from above post (original video clip is 404), can right clip Save Image As for source image.

Code:
Imagesource("CMAD_zpsae30b66c.jpg",end=0)
ConvertToYv24()
BANDS=6 PIX=48  # 6 Bands, each of 48 pixels
W=Width H=Height
n=0 # current_frame not available outside of runtime.
Bingo   = RT_YInRangeLocate(n=n,x=W-(PIX/2),y=0,w=1,h=H-(BANDS*PIX),lo=80,hi=255,baffle=24)
(Bingo) ? Overlay(Last.BlankClip(Width=4,height=YIRL_H,color=$FF0000),x=W-(PIX/2)-2,y=YIRL_Y) : NOP
Return ConvertToRGB24


EDIT: YIRL_H and YIRL_Y are variables set by RT_YInRangeLocate.

EDIT: I'm only interested in spatial alignment horizontal/vertical, not zoom/rotatation (which sounds way too complicated for my little brain).

EDIT:
Here a genuine pair of Row=False [Horizontal] Zebra bar sets for two misaligned frames.

And after alignment (not perfect, yet, below only for primary rapid approximation [4 zebra bands for each frame, probably 1 {YIR} would be better])

Above, only left alignment seems ok, right align a bit off [needs a few pixels cropped off RHS of bottom frame, and stretched a few pixels].
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 26th March 2019 at 23:54.
StainlessS is offline   Reply With Quote