The SEA(Stream Encoder for Android) publish live stream to SRS over HTTP-FLV.
The latest dev apk http://ossrs.net/apks/sea.latest.apk, or scan the below code:
The step to use the SEA:
- [Optional] Make sure your android is 4.1+, see Requirements
- [Optional] Check your MediaCodec info, see MediaCodec
- [Required] Download the SEA apk.
- [Required] Push to ossrs.net
http://ossrs.net:8936/live/sea.flv
, or read Stream Caster. - [Required] Play the RTMP stream
- [Required] Play the FLV stream
- [Required] Play the HLS stream, or scan the below code:
Remark: Change the url if use your server, for instance:
Publish: http://yourserver:8936/live/sea.flv
RTMP URL: rtmp://yourserver:1935/live/sea
FLV URL: http://yourserver:8080/live/sea.flv
HLS URL: http://yourserver:8080/live/sea.m3u8
For more information about config of SRS, read StreamCaster.
- Only java files, without any native code.
- Realtime live streaming, similar to RTMP.
- Stable for POST HTTP FLV stream to SRS.
- Hardware encoding with low cpu usage.
Android SDK level 16+, Android 4.1, the JELLY_BEAN
The following android device is test ok, others should be ok.
Company | Band | Android | Codec |
---|---|---|---|
Huawei | AscendG7 | 4.4 | qcom |
Huawei | Honor6 | 4.4 | - |
Huawei | Mate7 | 4.4 | - |
mi.com | MI3 | 4.4 | nvidia |
魅族 | mx4 pro | 4.4.4 | exynos(三星) |
三星Media | Galaxy Tab S T700 | 5.0.2 | exynos(三星) |
酷派 | 大神F2-8297 | 4.4.2 | MTK(联发科) |
小米 | mi-4c | 5.1.1 | qcom |
Please report your device if srs-sea is ok for your phone.
To show your android media codec info, download the app, or scan the below code:
About more information please read more.
The workflow of the android publisher is:
- Setup the Camera preview, callback with the YUV(YV12) image frame.
- Setup the MediaCodec and MediaFormat, encode the YUV to h.264/avc in annexb.
- Remux the annexb to flv stream.
- HTTP POST the flv stream to SRS.
For more information, read the blog.
The latency is same to RTMP, 0.8s in lan and 3-5s in wan.
CPU 13% for publishing live to SRS over HTTP FLV, bitrate is 800kbps, fps is 25 and gop is 10s.
CPU 6% for publishing live to SRS over HTTP FLV, bitrate is 125kbps, fps is 15 and gop is 5s.
Projects from SRS-ORG:
- SRS: https://github.com/ossrs/srs
- SRS-BLE(pc encoder): https://github.com/ossrs/srs-ble
- SRS-SEA(android encoder): https://github.com/ossrs/srs-sea
- SRS-SPA(player): https://github.com/ossrs/srs-spa
- SRS-DOCKER: https://github.com/ossrs/srs-docker
Others:
- YASEA(SEA over RTMP): https://github.com/begeekmyfriend/yasea
Winlin 2015.5