Code Monkey home page Code Monkey logo

player's Introduction

Player

功能:

1、投屏到电视盒子、智能电视(同一wifi下)

2、截图 (不支持硬解)

3、录屏(支持hls(m3u8)、rtsp格式的直播视频录制)

4、视频直播相关功能(调音量、亮度、半屏全屏、锁定屏幕)

5、多种直播源格式的支持(m3u8\rtsp)

截图

PS

1、屏幕录制是参考 简书 ijkplayer开启rtsp,并且支持录制和截图功能 来做的, 当时评论里面留了言,然后很多人找我,问我问题,c++我底层的东西我也不是太懂,就是照着作者的代码,自己重新编译了一下so库。 然后写到了自己的项目里。由于很多人问问题,打算,直接把自己做的项目 写成demo然后分享出来给大家

评论: 首先感谢楼主分享思路和代码,很棒。 原文有些代码 遗漏了,自己手动跑了一遍,这里再分享一下commit(https://github.com/fly7632785/ijkplayer/commit/fdd7c3347bbfafb3bae7b36add2d768e0beafe1b),方便大家自行在自己的项目上进行修改(分支上可以合并也可以手动改)。 还有几个注意的地方: 1、只有视频直播才可以录制,点播不行 2、最好视频开始播放才能录制,需要判断一下 3、注意只有软解才能录制,一般默认是硬解,需要改一下(硬解也可以播放 但是有时候会莫名其妙出错 还没有还清楚为什么)

2、报错,有很多时候录屏出来报错了,什么都没有,原因有很多:

  • 这里测试了下m3u8的直播源可以录制的,rtsp的源也是可以录制,但是有些比如摄像头采集的可能不行

  • 有些源的dts不是自增长的,有些源的地址本身是过期的地址,虽然能播,但是录制会失败

: Application provided invalid, non monotonically increasing dts to muxer in stream 0: 3031200 >= 0
: Error muxing packet
  • 有些源的音视频格式不是兼容mp4的,比如有些源的音频是pcm_alaw(视频采集),就不能直接写到mp4的文件里面,可以改后缀为.mov
Could not find tag for codec pcm_alaw in stream #0, codec not currently supported in container MP4

  • 硬解也可以播放 但是有时候会莫名其妙出错 还没有还清楚为什么(可能跟源有关系)

player's People

Contributors

fly7632785 avatar

Stargazers

 avatar Alan1314 avatar  avatar ChenJie avatar  avatar  avatar  avatar Agruuu avatar  avatar  avatar @nymo avatar Benlzy avatar feifei avatar  avatar Snoppy avatar  avatar  avatar  avatar tongzhengtong avatar UaoanLao avatar yeqinfu avatar Adam Wu avatar alex avatar harukong avatar Endless avatar 飞鱼 avatar  avatar Coderoyal avatar Afzal Khan avatar  avatar

Watchers

James Cloos avatar  avatar harukong avatar

player's Issues

软解情况下截图不成功

点击截图会直接崩溃,请问怎么回事呢?已经设为软解了
D/IJKMEDIA: =============>start snapshot
2019-12-23 15:03:48.824 23110-23110/com.jafir.player D/IJKMEDIA: =============>1280 X 720 === 0

--------- beginning of crash

2019-12-23 15:03:48.825 23110-23110/com.jafir.player A/libc: Fatal signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 0x0 in tid 23110 (om.jafir.player), pid 23110 (om.jafir.player)

不支持https 协议?

感谢 需要录屏的功能 但播放https的视频提示错误:https protocol not found, recompile FFmpeg with openssl, gnutls or securetransport enabled. 是ffmpeg 没有编译进去?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.