Log in

View Full Version : Shift a plane


Cary Knoop
23rd July 2020, 23:03
How do I shift a plane both horizontally and vertically in Vapoursynth?

poisondeathray
23rd July 2020, 23:11
Were you referring to "Y, U, V " planes or similar ?

One way is to Crop, then AddBorders .


Actually, I think source crops are built into the internal Resize. Yes they are


src_left, src_top, src_width, src_height:

Used to select the source region of the input to use. Can also be used to shift the image. Defaults to the whole image.

Cary Knoop
23rd July 2020, 23:25
Were you referring to "Y, U, V " planes or similar ?
Yes.

Actually, I think source crops are built into the internal Resize. Yes they are
Got it, thanks!

I suppose sub-pixel shifts are not supported in Vapoursynth?
I could always do a point resize up, then shift and then point resize back down.

poisondeathray
23rd July 2020, 23:26
I suppose sub-pixel shifts are not supported in Vapoursynth?

They are in avisynth, I would imaging they are in the Resize too

Cary Knoop
24th July 2020, 00:10
They are in avisynth, I would imaging they are in the Resize too
Yes, it looks like the function is taking floats.

StainlessS
24th July 2020, 00:20
Maybe see avisynth thread here (Move/shift frames without crop ):- http://forum.doom9.org/showthread.php?p=1718440&highlight=ShiftClip#post1718440

EDIT: And here:- http://forum.doom9.org/showthread.php?p=1518480#post1518480

feisty2
24th July 2020, 19:18
Yes.


Got it, thanks!

I suppose sub-pixel shifts are not supported in Vapoursynth?


fmtc.resample has it, you can assign floating point values to sx and sy