【问题标题】:FFMPEG: How to move the video without stretching it?FFMPEG:如何在不拉伸的情况下移动视频?
【发布时间】:2019-02-05 00:38:41
【问题描述】:

拜托,我需要以下帮助...

我想移动视频(纵向类型),但不拉伸它... 使用 FFMPEG 创建 16:9 视频... 我有以下示例...

ffmpeg -i video.mpg -filter:v "crop=in_w-100:in_h-100:0:(in_h-out_h)/2 +((in_h-out_h)/2)*sin(t)" -y out.mp4

【问题讨论】:

    标签: scroll ffmpeg crop


    【解决方案1】:

    哇,我不知道我在想什么...... 答案很简单,指明输出视频的HxW ...

    ffmpeg -i video.mpg -filter:v "crop=<strong>1280:720</strong>:0:(in_h-out_h)/2 +((in_h-out_h)/2)*sin(t)" -y out.mp4

    但是:如果我想创建 640x360 视频,如何调整背景视频的大小?

    我尝试包含“缩放”并进行一些测试,但我仍然无法制作背景视频,也无法缩放到 640x360。 ffmpeg -i test.mp4 -filter:v "crop=640:360:0:(in_h-out_h)/2 +((in_h-out_h)/2)*sin(t),scale=640:360" out.mp4.

    视频输出:https://youtu.be/TCOLbbereQU

    【讨论】:

    • 之后添加比例过滤器,scale=640:360
    • 嗨@Gyan,我该如何设置比例?谢谢!
    猜你喜欢
    • 1970-01-01
    • 2013-07-18
    • 2023-03-07
    • 2021-03-04
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-01-27
    • 1970-01-01
    相关资源
    最近更新 更多