All Projects → tcking → Giraffeplayer2

tcking / Giraffeplayer2

Licence: apache-2.0
out of the box android video player(support lazy load, ListView/RecyclerView and hight performance)

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to Giraffeplayer2

X1Player
iOS端封装的视频播放器.支持直播,录播视频的播放,支持常用的播放界面控制,类似于ijkplayer 优点是体积更小,使用快捷
Stars: ✭ 21 (-93.9%)
Mutual labels:  player, ffmpeg, video-player, ijkplayer
Fijkplayer
ijkplayer for flutter. ijkplayer 的 flutter 封装。 Flutter video/audio player. Flutter media player plugin for android/iOS based on ijkplayer. fijkplayer 是基于 ijkplayer 封装的 flutter 媒体播放器,开箱即用,无需编译 ijkplayer
Stars: ✭ 943 (+174.13%)
Mutual labels:  ffmpeg, player, video-player, ijkplayer
Dkvideoplayer
Android Video Player. 安卓视频播放器,封装MediaPlayer、ExoPlayer、IjkPlayer。模仿抖音并实现预加载,列表播放,悬浮播放,广告播放,弹幕
Stars: ✭ 3,796 (+1003.49%)
Mutual labels:  ffmpeg, player, video-player, ijkplayer
Playerbase
The basic library of Android player will process complex business components. The access is simple。Android播放器基础库,专注于播放视图组件的高复用性和组件间的低耦合,轻松处理复杂业务。
Stars: ✭ 2,814 (+718.02%)
Mutual labels:  player, ijkplayer, fullscreen
Videolistplayer
Play video in ListView or RecyclerView
Stars: ✭ 1,308 (+280.23%)
Mutual labels:  video-player, recyclerview, listview
Abmediaview
Media view which subclasses UIImageView, and can display & load images, videos, GIFs, and audio and from the web, and has functionality to minimize from fullscreen, as well as show GIF previews for videos.
Stars: ✭ 79 (-77.03%)
Mutual labels:  video-player, lazy-loading, fullscreen
Yuview
The Free and Open Source Cross Platform YUV Viewer with an advanced analytics toolset
Stars: ✭ 665 (+93.31%)
Mutual labels:  ffmpeg, player, video-player
Playerdemo
一个视频播放器,开源版 potplayer ,用于总结播放器开发技术。
Stars: ✭ 491 (+42.73%)
Mutual labels:  ffmpeg, player, video-player
KingPlayer
🎬 一个专注于 Android 视频播放器的基础库,无缝切换内核。(IjkPlayer、ExoPlayer、VlcPlayer、MediaPlayer)
Stars: ✭ 35 (-89.83%)
Mutual labels:  player, video-player, ijkplayer
Ijkplayer
Android/iOS video player based on FFmpeg n3.4, with MediaCodec, VideoToolbox support.
Stars: ✭ 29,752 (+8548.84%)
Mutual labels:  ffmpeg, player, ijkplayer
Gsyvideoplayer
视频播放器(IJKplayer、ExoPlayer、MediaPlayer),HTTPS,支持弹幕,外挂字幕,支持滤镜、水印、gif截图,片头广告、中间广告,多个同时播放,支持基本的拖动,声音、亮度调节,支持边播边缓存,支持视频自带rotation的旋转(90,270之类),重力旋转与手动旋转的同步支持,支持列表播放 ,列表全屏动画,视频加载速度,列表小窗口支持拖动,动画效果,调整比例,多分辨率切换,支持切换播放器,进度条小窗口预览,列表切换详情页面无缝播放,rtsp、concat、mpeg。
Stars: ✭ 16,948 (+4826.74%)
Mutual labels:  ffmpeg, player, ijkplayer
Flutter ijkplayer
ijkplayer for flutter
Stars: ✭ 703 (+104.36%)
Mutual labels:  ffmpeg, player, ijkplayer
Player
FFmpeg and SDL2 video player
Stars: ✭ 119 (-65.41%)
Mutual labels:  ffmpeg, player, video-player
Zftplayer
iOS平台下基于IJKplayer封装的视频播放器,主要适用于视频点播。针对视频格式,前后台切换,内存管理控件的层级分离做了相应优化
Stars: ✭ 273 (-20.64%)
Mutual labels:  ffmpeg, player, ijkplayer
recyclerview-list-drag-and-drop
No description or website provided.
Stars: ✭ 50 (-85.47%)
Mutual labels:  listview, recyclerview
react-recycled-scrolling
Simulate normal scrolling by using only fixed number of DOM elements for large lists of items with React Hooks
Stars: ✭ 26 (-92.44%)
Mutual labels:  listview, recyclerview
aplayer
ffplay友好版本. 对ffplay裁剪重构以适合初学者阅读、理解
Stars: ✭ 41 (-88.08%)
Mutual labels:  player, ffmpeg
adapster
Android library designed to enrich and make your RecyclerView adapters more SOLID
Stars: ✭ 17 (-95.06%)
Mutual labels:  listview, recyclerview
Sjfullscreenpopgesture
Fullscreen pop gesture. OC&Swift. It is very suitable for the application of the video player. Support `cocoapods`. 只需`pod`即可自带全屏返回手势. 支持pod. 支持OC&Swift.
Stars: ✭ 266 (-22.67%)
Mutual labels:  video-player, fullscreen
Hplayer
A multi-screen player using Qt + FFmpeg.
Stars: ✭ 330 (-4.07%)
Mutual labels:  ffmpeg, player

GiraffePlayer2

Out of the box android video player base on ijkplayer 0.8.8 (for flutter please visit GPlayer)

this project is total refactor of GiraffePlayer to support in ListView/RecyclerView and improve the performance,all player tasks do in worker thread.

release history

download demo apk (~700kb)

features

  1. base on ijkplayer,support RTMP , HLS (http & https) , MP4,M4A etc.
  2. gestures for volume control
  3. gestures for brightness control
  4. gestures for forward or backward
  5. fullscreen by manual or sensor (with animation)
  6. try to replay when error(only for live video)
  7. specify video scale type
  8. support in ListView/RecyclerView (in Activity or Fragment)
  9. never block UI thread
  10. support select track
  11. support float window
  12. support lazy load (download player on demand,increase apk size only about 180K)
  13. easy to custom media controller (without change this project source code)

how to import library

   //step 1: add jcenter repositories in your root poject build file
   repositories {
       ...
       jcenter()
   }

   //step 2: add dependency,there are 3 type of aar,see the flow table
   api 'com.github.tcking:giraffeplayer2:0.1.25-lazyLoad'

aar type aar size decoders support abi
api 'com.github.tcking:giraffeplayer2:0.1.25' 2.2M common decoders default armeabi,can add manually
api 'com.github.tcking:giraffeplayer2:0.1.25-lazyLoad' 180K all decoders download player(so files) on demand by device abi
api 'com.github.tcking:giraffeplayer2:0.1.25-full' 5.4M all decoders default armeabi,can add manually

if you using compile 'com.github.tcking:giraffeplayer2:0.1.25' or compile 'com.github.tcking:giraffeplayer2:0.1.25-full' and want to support more ABI:

    //for common decoders
    api 'com.github.tcking:ijkplayer-arm64:0.8.8' //support arm64
    api 'com.github.tcking:ijkplayer-armv5:0.8.8' //support armv5
    api 'com.github.tcking:ijkplayer-x86:0.8.8' //support x86
    api 'com.github.tcking:ijkplayer-x86_64:0.8.8' //support x86_64

    //for all decoders
    api 'com.github.tcking:ijkplayer-arm64:0.8.8-full' //support arm64
    api 'com.github.tcking:ijkplayer-armv5:0.8.8-full' //support armv5
    api 'com.github.tcking:ijkplayer-x86:0.8.8-full' //support x86
    api 'com.github.tcking:ijkplayer-x86_64:0.8.8-full' //support x86_64

How to use (example code)

case 1: only want to play a video fullscreen

just call GiraffePlayer.play(getContext(), new VideoInfo("video url"));,all is done.

case 2: embed a player in a layout (ListView/RecyclerView)

step 1: add VideoView in your layout xml file

<tcking.github.com.giraffeplayer2.VideoView
    android:id="@+id/video_view"
    android:layout_width="match_parent"
    android:layout_height="match_parent"/>

step 2: get player and play

VideoView videoView = (VideoView) findViewById(R.id.video_view);
videoView.setVideoPath(videoUri).getPlayer().start();


player in ListView or RecyclerView example code

in ListView or RecyclerView,you need do one more thing: call videoView.setFingerprint(), the fingerprint is the key that player distinguish list items,you can using list position or list data's hashcode as fingerprint,eg:

public void onBindViewHolder(VideoItemHolder holder, int position) {
        VideoItem videoItem = data.get(position);
        holder.name.setText(videoItem.name);
        holder.url.setText(videoItem.uri);
        holder.videoView.setVideoPath(videoItem.uri).setFingerprint(position);// or using:setFingerprint(videoItem.hashCode())
    }

config player

all the configurations in VideoInfo,you can get VideoInfo and then set configurations,eg:

//standalone player
VideoInfo videoInfo = new VideoInfo("http://xxx.mp4")
                            .setTitle("test video") //config title
                            .setAspectRatio(aspectRatio) //aspectRatio
                            .setShowTopBar(true) //show mediacontroller top bar
                            .setPortraitWhenFullScreen(true);//portrait when full screen

GiraffePlayer.play(getContext(), videoInfo);

//in RecyclerView or embed player
public void onBindViewHolder(VideoItemHolder holder, int position) {
        VideoItem videoItem = data.get(position);
        holder.name.setText(videoItem.name);
        holder.url.setText(videoItem.uri);
        holder.videoView.getVideoInfo().setBgColor(Color.GRAY).setAspectRatio(VideoInfo.AR_MATCH_PARENT);//config player
        holder.videoView.setVideoPath(videoItem.uri).setFingerprint(position);
    }

Proguard Configurationr

-dontwarn tv.danmaku.ijk.media.player.**
-keep class tv.danmaku.ijk.media.player.** { *; }
-keep interface tv.danmaku.ijk.media.player.* { *; }

screenshot

lazy load

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].