GithubHelp home page GithubHelp logo

zyxyuanxiao / html_player_server Goto Github PK

View Code? Open in Web Editor NEW

This project forked from xiao-si-qi/html_player_server

0.0 1.0 0.0 17.82 MB

基于Flask和flv.js的HTML5视频播放器服务器

Python 0.80% JavaScript 96.05% HTML 1.75% CSS 1.40%

html_player_server's Introduction

基于Flask和flv.js的HTML5视频播放器 - Simple Player

搭建家庭媒体服务器,让接入家庭网络的手机和电脑能通过网页在线观看服务器内的视频和图片内容。

目前可支持的视频格式:WEBM,MP4, OGG,FLV,MKV

网页使用响应式设计,同时适配手机和电脑端。

HTML5播放器使用 DPlayer。 DPlayer项目地址 FLV 视频解码使用flv.js。由 bilibili 网站开源。HTML5 原生仅支持播放 mp4/webm 格式,flv.js 实现了在 HTML5 上播放 FLV 格式视频。 flv.js项目地址

依赖:

  • python3
  • Flask

将图片文件和视频文件放到 static/file/ 里,然后运行服务器,用浏览器访问服务器即可观看视频和图片。 当然,也可以通过映射的方式,把文件夹映射到 static/file/ 里。

  • Windows 平台的服务器可以通过mklink命令把存放视频文件的文件夹映射到static/file/目录里
  • Linux 平台的服务器可以通过ln命令建立软连接把存放视频文件的文件夹映射到static/file/目录里

配置好python的运行环境后,执行:

python play.py

默认为127.0.0.1:8000,修改host和port需要参考Flask

移动端 AOSP 和 PC 端 chrome 观看视频运行良好。

运行效果截图: 1.png 2.png

html_player_server's People

Contributors

xiao-si-qi avatar chaikau avatar

Watchers

James Cloos avatar

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.