文档介绍:Android弹幕实现:基于B站弹幕开源系统(1)Android弹幕实现:基于B站弹幕开源系统(1)如今的视频播放,流行在视频上飘弹幕。这里面做的相对比较成熟、稳定、使用量较多的弹幕系统,当推B站的弹幕系统,B站的弹幕系统已经作为开源项目在github上,其项目地址:https:///Bilibili/DanmakuFlameMaster 以B站开源的弹幕项目为基础,现给出一个简单的例子,实现发送简单的文本弹幕。第一步,:[plain] viewplain copyrepositories {          jcenter()  }      dependencies {        compile ':DanmakuFlameMaster:'      compile ':ndkbitmap-armv7a:'    }  第二步,写一个布局文件,引入B站的弹幕view:[html] viewplain copy<?xml version="" encoding="utf-8"?>  <LinearLayout xmlns:android="http://schemas./apk/res/android"      android:layout_width="match_parent"      android:layout_height="match_parent"      android:orientation="vertical">        <Button          android:id="@+id/show"          android:layout_width="wrap_content"          android:layout_height="wrap_content"          android:text="显示弹幕" />        <Button          android:id="@+id/hide"          android:layout_width="wrap_content"          android:layout_height="wrap_content"          android:text="隐藏弹幕" />        <Button          android:id="@+id/sendText"          android:layout_width="wrap_content"          android:layout_height="wrap_content"          android:text="发送文本弹幕" />        <Button          android:id="@+id/pause"          android:layout_width="wrap_content"          android:layout_height="wrap_content"          android:text="暂停弹幕" />        <Button          android:id="@+id/resume"          android:layout_width="wrap_content"          android:layout_height="wrap_content"          android:text="重启弹幕" />        <          android:id="@+id/danmakuView"          android:layout_width="match_parent"          android:layout_height="match_parent" />    </LinearLayout>  第三步,写上层Java代码(该处java代码改造自B站弹幕github上的demo代码):[java] viewplain copypackage ;    import ;  import ;  import ;  import ;  import androi