Using Ffmpeg.exe to convert an ASP function in FLV format to a call in ASP

Source: Internet
Author: User
Functions | conversions

The ASP code is as follows:

<%
Str= "D:\ffmpeg.exe"
' Video= ' D:\a.mov '
video= "D:\aaa.avi"
Simg= "D:\bbbbbb.jpg"
flv= "D:\3gp2.flv"
' Response.Write Video
Set WshShell = server. CreateObject ("Wscript.Shell")
Dim RANNUM1
Randomize
Rannum1=int (10*RND) +1
' str=str& "-i" &video& "-y-f image2-ss" &ranNum1& "-t 0.005-s 120x90" &simg
str=str& "I" &video& "-y-ab 56-ar 22050-b 500-r 15-s 320*240" &flv
' str=str& "-i" &video& "-ab 56-ar 22050-b 500-r 15-s 320x240" &flv
Isffmpeg = Wshshell.run (st*,1,**lse)
' ##################### #视频图片处理结束
If Isffmpeg = 0 Then
Response.Write str& "<br>"
End If
%>


FFmpeg parameter Description

Ffmpeg.exe-i F:\ The home of the Flash guest song. Mp3-ab 56-ar 22050-b 500-r 15-s 320x240
Ffmpeg-i F:\01.wmv-ab 56-ar 22050-b 500-r 15-s 320x240 f:\test.flv
Using the-SS parameter action (Time_off set the start time offset), you can start the transformation task from a specified point-in-time. Such as:
To transform the file format while grasping thumbnails:
Ffmpeg-i "Test.avi"-y-f image2-ss 8-t 0.001-s 350x240 ' test.jpg '
For an existing FLV capture diagram:
Ffmpeg-i "test.flv"-y-f image2-ss 8-t 0.001-s 350x240 ' test.jpg '
The time unit followed by the-SS is seconds
FFmpeg conversion Command
Ffmpeg-y-I test.mpeg-bitexact-vcodec h263-b 128-r 15-s 176x144-acodec aac-ac 2-ar 22500
-ab 24-f 3gp test.3gp
Or
Ffmpeg-y-I test.mpeg-ac 1-acodec amr_nb-ar 8000-s 176x144-b 128-r


FFmpeg parameter Setting explanation
-bitexact using standard bit rate
-vcodec xvid using XviD compression
-S 320x240 specified resolution
-R 29.97 Hardwood rate (can be changed to confirm non-standard frame rate will cause sound



Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.