-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
29 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,29 @@ | ||
# ComposeVideoPlayer | ||
一个视频播放器,使用Jetpack Compose对于Exoplayer进行的封装 | ||
# Compose Video Player | ||
|
||
一个视频播放器,使用Jetpack Compose基于Exoplayer进行的封装 | ||
|
||
## 简单使用 | ||
|
||
```kotlin | ||
val playerState = rememberVideoPlayerState() | ||
|
||
VideoPlayer( | ||
url = "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4", | ||
playerState = playerState, | ||
) { | ||
VideoPlayerControl( | ||
state = playerState, | ||
title = "Elephant Dream", | ||
) | ||
} | ||
``` | ||
|
||
更详细的使用参考[VideoPlayScreen](app/src/main/java/com/example/composevideoplayer/VideoPlayScreen.kt) | ||
|
||
## 应用截图 | ||
|
||
![player](Screenshots/player.jpg) | ||
|
||
## 参考开源 | ||
|
||
本项目是在[compose-video-player](https://github.com/imherrera/compose-video-player)的基础上进行开发的 |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.