国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁(yè) > 學(xué)院 > 開發(fā)設(shè)計(jì) > 正文

FFMPEG命令參數(shù)

2019-11-09 15:51:59
字體:
供稿:網(wǎng)友

命令解析

進(jìn)入bin目錄,輸入ffmpeg -help可以查看相關(guān)命令參數(shù),如下:

Getting help: -h -- PRint basic options -h long -- print more options -h full -- print all options (including all format and codec specific options, very long) -h type=name -- print all options for the named decoder/encoder/demuxer/muxer/filter See man ffmpeg for detailed description of the options.Print help / information / capabilities:顯示許可證,執(zhí)照,版本信息-L show license -h topic show help -? topic show help-help topic show help--help topic show help-version show version顯示配置命令參數(shù)-buildconf show build configuration顯示可用的格式(編碼,協(xié)議相關(guān)的)-formats show available formats-devices show available devices顯示支持的編解碼格式-codecs show available codecs-decoders show available decoders-encoders show available encoders顯示支持的bit流過濾協(xié)議-bsfs show available bit stream filters顯示支持的協(xié)議-protocols show available protocols-filters show available filters顯示支持的像素格式(rgb,yuv,nv...)-pix_fmts show available pixel formats顯示standard聲道布局-layouts show standard channel layouts顯示音頻采樣的格式(8位,16,32位...)-sample_fmts show available audio sample formats-colors show available color names-sources device list sources of the input device-sinks device list sinks of the output device硬件加速方法-hwaccels show available HW acceleration methodsGlobal options (affect whole program instead of just one file:日志相關(guān)-loglevel loglevel set logging level-v loglevel set logging level-report generate a report設(shè)置緩沖區(qū)-max_alloc bytes set maximum size of a single allocated block覆蓋輸出文件-y overwrite output files-n never overwrite output files-ignore_unknown Ignore unknown stream types-stats print progress report during encoding-max_error_rate ratio of errors (0.0: no errors, 1.0: 100% error maximum error rate-bits_per_raw_sample number set the number of bits per raw sample-vol volume change audio volume (256=normal)Per-file main options:強(qiáng)制采用格式fmt-f fmt force format 編解碼名稱-c codec codec name-codec codec codec name-pre preset preset name設(shè)置outfile metadata from infile-map_metadata outfile[,metadata]:infile[,metadata] set metadata information of outfile from infile設(shè)置紀(jì)錄時(shí)間-t duration record or transcode "duration" seconds of audio/video-to time_stop record or transcode stop time-fs limit_size set the limit file size in bytes-ss time_off set the start time offset-sSEOf time_off set the start time offset relative to EOF-seek_timestamp enable/disable seeking by timestamp with -ss-timestamp time set the recording timestamp ('now' to set the current time)-metadata string=string add metadata-program title=string:st=number... add program with specified streams-target type specify target file type ("vcd", "svcd", "dvd", "dv" or "dv50" with optional prefixes "pal-", "ntsc-" or "film-")-apad audio pad-frames number set the number of frames to output-filter filter_graph set stream filtergraph-filter_script filename read stream filtergraph description from a file-reinit_filter reinit filtergraph on input parameter changes-discard discard-disposition disposition視頻參數(shù)Video options:設(shè)置視頻幀的數(shù)量-vframes number set the number of video frames to output設(shè)置幀率-r rate set frame rate (Hz value, fraction or abbreviation)設(shè)置幀的大小(格式為寬X高,如1080X720)-s size set frame size (WxH or abbreviation)設(shè)置橫縱比-aspect aspect set aspect ratio (4:3, 16:9 or 1.3333, 1.7777)設(shè)置的文件比特?cái)?shù)量-bits_per_raw_sample number set the number of bits per raw sample不做視頻記錄-vn disable video強(qiáng)制使用codec編解碼方式-vcodec codec force video codec ('copy' to copy stream)-timecode hh:mm:ss[:;.]ff set initial TimeCode value.處理的遍數(shù)-pass n select the pass number (1 to 3)音視頻碼率-vf filter_graph set video filters-ab bitrate audio bitrate (please use -b:a)-b bitrate video bitrate (please use -b:v)-dn disable data音頻參數(shù)Audio options:設(shè)置音頻幀的數(shù)量-aframes number set the number of audio frames to output設(shè)置音頻的質(zhì)量-aq quality set audio quality (codec-specific)設(shè)置音頻的采樣率-ar rate set audio sampling rate (in Hz)設(shè)置音頻的通道-ac channels set number of audio channels不做音頻記錄-an disable audio強(qiáng)制使用編碼-acodec codec force audio codec ('copy' to copy stream)設(shè)置音頻音量-vol volume change audio volume (256=normal)-af filter_graph set audio filtersSubtitle options:-s size set frame size (WxH or abbreviation)-sn disable subtitle-scodec codec force subtitle codec ('copy' to copy stream)-stag fourcc/tag force subtitle tag/fourcc-fix_sub_duration fix subtitles duration-canvas_size size set canvas size (WxH or abbreviation)-spre preset set the subtitle options to the indicated preset

命令使用

常用參數(shù)如下:

主要參數(shù): -i 設(shè)定輸入流 -f 設(shè)定輸出格式 -ss 開始時(shí)間 視頻參數(shù): -b 設(shè)定視頻流量,默認(rèn)為200Kbit/s -r 設(shè)定幀速率,默認(rèn)為25 -s 設(shè)定畫面的寬與高 -aspect 設(shè)定畫面的比例 -vn 不處理視頻 -vcodec 設(shè)定視頻編解碼器,未設(shè)定時(shí)則使用與輸入流相同的編解碼器 音頻參數(shù): -ar 設(shè)定采樣率 -ac 設(shè)定聲音的Channel數(shù) -acodec 設(shè)定聲音編解碼器,未設(shè)定時(shí)則使用與輸入流相同的編解碼器 -an 不處理音頻

1.分離視頻音頻流

ffmpeg -i test.mp4 -an -vcodec copy videoffmpeg -i test.mp4 -vn -acodec copy audeo

2.合并音視頻流

ffmpeg -i video -i audio -vcodec copy -acodec copy video.mp4

3.視頻轉(zhuǎn)碼

ffmpeg –i test.mp4 –vcodec h264 –s 352*278 –an –f m4v test.264
發(fā)表評(píng)論 共有條評(píng)論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 阜康市| 东阿县| 贺兰县| 察哈| 咸宁市| 重庆市| 四子王旗| 道孚县| 嘉禾县| 梅州市| 岳池县| 霞浦县| 仪征市| 固始县| 莱西市| 汉中市| 江门市| 塘沽区| 那曲县| 霞浦县| 太康县| 达尔| 星座| 朝阳市| 桐梓县| 贵港市| 楚雄市| 和田县| 永靖县| 慈溪市| 都江堰市| 霍州市| 宁陵县| 蒲城县| 大化| 阳泉市| 互助| 满洲里市| 新昌县| 宁河县| 陕西省|