Public Function Convert_Media(FileName, _ffmpegpath, InputPath , OutputPath, Width, Height, Video_Bitrate, FrameRate, Audio_Bitrate, Audio_SamplingRate, deinterlace)
Description:
Convert_Media() function is used to encode video from any format to flv format. This function accepts all possible video parameters including , width, height, audio bitrate, video bitrate, frame rate, audio sampling rate etc. By using this function you can easily control the quality and size of video. Greater will be the quality of video, greater will be the size and will take more bandwidth and time while loading on browser.
Parameter Detail:
-
String FileName : Name of source video e.g 'sample.mov'
- String _ffmpegpath: path of ffmpeg.exe, need to be properly configure, view sample code section to learn more about how to be setup _ffmpegpath variable.
- String InputPath: path of source video directory.
- String OutputPath: path of destination video directory, where encoded video will save.
- Integer Width: width of video, must be multiple of 2. e.g 389 is invalid as it is not multiple of two.
- Integer Height: heigh of video, must be multiple of 2.
- Integer Video_Bitrate: Set video bitrate, read more...
- Float FrameRate: Set Framerate of output video, read more...
- Integer Audio_Bitrate: Set Audio Bitrate, read more...
- Integer Audio_SamplingRate: Set Audio Sampling Rate, read more...
- Boolean deinterlace: whether generated video should be deinterlace or not.
Returns:
- String: Generated Video Name
- or
- Error Codes - See Detail