I'm using ffmpeg library to draw text on video in specific time and i'm success to do that Now i need to move the text from position to another and i can't do that so can any one suggest me how to do that
i'm using this command to move text from top to down but i can't determine the x and Y to move from the x,y to specific x,y
ffmpeg -i VideoInput.mp4 -vf "drawtext=enable='between(t,12,14)':fontfile=myfont.otf:text='Test test':x=(w-text_w)/2:y=w/50\*mod(t\,2):fontsize=65" -acodec copy outputVideo.mp4
Use
where
x1
andy1
are initial co-ordinates;x2
andy2
are final co-ordinates;t1
andt2
are start and end times; in your given command,12
and14
.These above need to be replaced with their values in the command.
To give a 1 second stay at the end,
Here
t2
includes the stay, so movement from 12 to 14 + 1 second hold. Thet2
in enable is changed as well.