for RTMP protocol playback. In addition the Flash Player is also a good choice to enter the address and stream name in the player:The playback effect is as follows, the computer desktop is truncated:To this, our entire crtmpserver source of the Windows platform of the compilation, Linux platform compilation, push stream, play even if complete. You can see that the compilation of Windows is more complex than Linux, in fact, a lot of open source software for Linux to be more friendly, including c
in the file system. A path consists of multiple directory name strings separated by "/", which are divided into absolute paths and relative paths. An absolute path is a method that starts from the root directory "/" to indicate the location of a file or directory in the system. For example, if an absolute path is used to represent the bin directory in the 4th-layer directory in the figure, it should be "/usr/local/bin ". The relative path is based on the current directory, indicating the locati
authentication before using it. In this android RTMP example, we will not only discuss RTMP live streams, but also m3u8 streams (HLS), RTSP streams, and MMS (Microsoft Media Stream ). First, let us reference the Vitamio library in our project.Follow these steps to reference the Vitamio library in Android Studio:
Download Vitamio bundle
Decompress the package and choose File> Import Module on Android Studio.
Specify the VitamioBundle path, select
instead of HTTP-based HLS protocol for transmission between server nodes and nodes, which can reduce the overall transmission latency. This is mainly for end users to use HLS for playback.
2. If the end user uses RTMP to play the video, try to transcode it at the stream receiving node near the streaming end. In this way, the transmitted video stream is smaller than the original video stream.
3. If necessar
, mpeg4, mpeg2video, pcm, and flv encoder support.
3.3 FFmpeg decoder support
The FFmpeg source code contains a lot of decoding support, which is mainly used for decoding input. It can also be understood as decompressing the compressed encoding. For decoding support, you can use. /configure-list-decoders command to view:
The decoders module supported by ffmpeg supports mpeg4, h264, h265 (HEVC), and mp3.
3.4 FFmpeg multiplexing (Muxing) Support
Exoplayer.
Exoplayer is a Google development team open-source Media Library, more than the Android framework native MediaPlayer has more advantages to support dynamic adaptive streaming HTTP (DASH) and smooth streaming, support advanced HLS features, support custom and expand your use Scenes, etc.
Crouton (not recommended)
Crouton is a display tool class that displays prompt information, which can be used instead
is more valuable.At present, in the image processing process, the most commonly used color picture format has RGB,HSV, YUV and HLS three kinds. The following is a grayscale implementation of the color images in these three formats respectively.1. RGB Space ImageA color map defined in RGB space whose color is determined by a combination of R, G, and b three components per pixel. The number of bits that each component occupies in memory determines the
function
Vitamio is a android and IOS platform for all-in-one multimedia development framework , full support hardware decoding and GPU rendering . With its simple and easy-to-use API interface, Vitamio has won the favor of many developers around the world. To date, more than 10,000 applications worldwide have been using Vitamio, covering more than 500 million users. Vitamio can play 720p even 1080P HD mkv,flv,mp4,mov,ts,rmvb such as common format video, also can cross platform support on
last recorded video is in one file, or you will generate a separate file for each recording. After using these two commands, the transcoding will also be performed at intervals of time, but the final output (overwrite) is in the same file. The advantage is that it can be almost "real-time" transcoding, the disadvantage is to repeatedly call FFmpeg, occupy the system resources.
3, it should be noted that the two methods of the last obtained transcoding files (the length) is the same.
4. Nginx.co
Hls,http live Streaming is an apple-defined protocol for real-time streaming, and HLS is based on the Http protocol, which mainly consists of two parts: the m3u8 profile and the TS media file.Because it is apple out of the video playback format, so the PC side in addition to safari other browsers basically do not support, Microsoft Edge launch on the support, is the specific support of each browserCan see A
(Ningyugang), is the author of the "Android Development Art Exploration" book, this is the author of the joint two developers screaming (time of the Sand) and song Siyu took a few months to study out of the APK dynamic loading framework, want to learn more about this framework can be seen in the author blog This article is described in detail
70.ExoPlayer
Exoplayer is a Google development team open-source Media Library, more than the Android framework native MediaPlayer has m
1.article------Thesis, this is an introduction to Apple's new technical paper HTTP Live streaming(HLs),http Live streaming(HLS ) is Apple Inc. (Apple Inc) The implementation of the HTTP-based streaming media transmission protocol, can achieve streaming media live and on-demand, mainly in the iOS system, for iOS devices (such as the iphone, IPad) to provide audio and video live and on-demand pr
the m3u8 stream (HLS), RTSP Stream, and MMS (Microsoft Media stream). First let's refer to the Vitamio library in our project.The steps for referencing the Vitamio library in Android Studio are as follows:Download Vitamio bundle Https://github.com/yixia/VitamioBundle Unzip and File->import Module on Android Studio To specify the Vitamiobundle path, select the Vitamio folder click Finish to add the dependent item (': Vitamio ') on the Build.gradle (M
software a color mode, in this mode, processing the image is more convenient, and, RGB stored images than CMYK images to small, can save memory and space.
CMYK mode is a pigment mode, so it belongs to the printing mode, but in essence, there is no difference with RGB mode, but the way of producing color is different. RGB is the additive blending mode, and CMYK is the subtraction process color mode. For example, the display uses RGB mode because the display is an electron beam that emits light
software a color mode, in this mode, processing the image is more convenient, and, RGB stored images than CMYK images to small, can save memory and space.
CMYK mode is a pigment mode, so it belongs to the printing mode, but in essence, there is no difference with RGB mode, but the way of producing color is different. RGB is the additive blending mode, and CMYK is the subtraction process color mode. For example, the display uses RGB mode because the display is an electron beam that emits light
When playing a video stream using HLS technology, you first convert the video to a TS slice and a m3u8 playlist, using FFmpeg to do the conversion (the low version ffmpeg does not support direct turning, and can now be converted to TS and m3u8-segmenter slices, The author uses ffmpeg version-2.1.2), usually using the following command:
Ffmpeg-i input.mp4-c:v libx264-c:a aac-strict-2-F HLS output.m3u8
Howeve
Search the keyword backwards from the cursor position love
Use n or n commands in normal mode to perform forward lookup or backward lookup next keyword
: Set IC ignores uppercase and lowercase commands, IC for ignore case abbreviation: The set is edge input edge shows the match result, is is the incsearch command abbreviation: Set HLS Highlight match results, HLS for highlight search abbreviation
You can p
image entered here must be out0001.png out0002.png ... out0010.png, must be starting from 1 and is a continuous number, or will not find the input picture error.
splitting video and generating m3u8 files
Ffmpeg-i input.mp4-c:v libx264-c:a aac-strict-2-F hls-hls_time 20-hls_list_size 0-hls_wrap 0 output.m3u8
Related parameter Description:
-I input video file
-c:v output video format
-c:a output audio format
-strict-
f
Slice generates m3u8 List command:
ffmpeg-i input.mp4-c:v libx264-c:a aac-strict-2-F HLS output.m3u8
The length of the default per piece (that is, a TS file) for this conversion command is the only last 5 piece of information that is saved by default in the 2s,m3u8 list file, that is, the player can only broadcast the last 5 TS video files in the pull stream.
This is definitely not what you want, so luckily, FFmpeg provides parameters to change these
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.