zoukankan      html  css  js  c++  java
  • 在线转flv+flash在线录制视频

    需要用到的组件
    ASPExec
    mencoder
    ffmpeg.exe

    第一步骤: 在线转换

    Set Executor = Server.CreateObject("ASPExec.Execute")
    Executor.Application = "cmd /c mencoder E:\qiancheng\upload\"&request.QueryString("keys")&" -o E:\qiancheng\shipin\record\streams\_definst_\record\"&lid&"\"&keys&".flv -of lavf -oac mp3lame -lameopts abr:br=56 -ovc lavc -lavfopts i_certify_that_my_video_stream_does_not_use_b_frames -lavcopts vcodec=flv:vbitrate=200:mbd=2:mv0:v4mv:last_pred=3:dia=3:cmp=3:vb_strategy=1 -vf scale=330:-3 -ofps 12 -srate 22050"
    Executor.Parameters = ""
    strResult = Executor.ExecuteDosApp

    asp执行 .bat文件

    第二步骤: 通过ffmpeg生成所略图+fso 删除源件

    Server.ScriptTimeout=0
    flvname=keys
    streamPath="../shipin/record/streams/_definst_/record/"&lid&"/"&flvname&".flv"
    imgW ="120"
    imgY = "90"
    imgQuality = "100"
    ss="3"
    newName = "../upload/"&flvname&".jpg"
    str="e:\qiancheng\webadmin\ffmpeg.exe"
    str=str+" -i "&server.mappath(streamPath)&" -ss 3 -vframes 1 -r 1 -ac 1 -ab 2 -s 120*90 -f image2 "&server.mappath(newName)&""
    Set shellffmpeg=server.CreateObject("ffmpeg.shellffmpeg")
    aa=shellffmpeg.shellffmpeg1(str)
    Set shellffmpeg = Nothing
    '删除上传的文件
    tupianid="../upload/"&request.QueryString("keys")
    set   fso=server.CreateObject("scripting.filesystemobject")   
    if fso.FileExists(Server.MapPath(tupianid))   then   
    fso.deletefile(server.MapPath(tupianid))   
    end if   
    set fso=nothing
  • 相关阅读:
    十:audio 音频
    八: 操作提示(wxml 即将废弃)
    九: 操作提示(js版本)
    七: 表单标签(3)
    四: 基本标签
    五: 表单标签(1)
    六: 表单标签(2)
    webservice和wcf和web.api简单介绍
    Qt 中事件与处理
    Qt 事件过滤器
  • 原文地址:https://www.cnblogs.com/MaxIE/p/618692.html
Copyright © 2011-2022 走看看