Node-Webkit:如何播放AVI视频? [英] Node-Webkit: How to play AVI videos?

查看:369
本文介绍了Node-Webkit:如何播放AVI视频?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试制作一个简单的node-webkit应用程序,该应用程序可让您播放.avi视频(在Windows和Mac上均可使用).有没有办法用node-webkit做到这一点?

I am trying to make a simple node-webkit app that lets you play .avi videos (which should work both on windows and mac). Is there a way to do this with node-webkit?

推荐答案

使用Node-Webkit不太可能做到这一点.特别是由于官方Webkit不支持AVI.最好的选择是使用libav(avplay)之类的外部应用程序,或者使用node来提供一个网页,该网页具有一个能够播放内容的播放器,并且只允许用户浏览器完成工作. (使用Flash可能仍然是最好的方法, video.js 是一个不错的选择)

It is unlikely you will be able to just do this with Node-Webkit. Especially since the official webkit does not support AVI. Your best bet is to use an external application like libav (avplay) or use node to serve a webpage that has a player capable of playing the content and just let the users browser do the work. (Flash is likely still the best way to go, video.js is a good choice)

另一种选择是将视频转换为支持的格式之一.我会推荐mp4. (这里再次提供了libav(avconv)派上用场.)仍然假设Node-Webkit已实现了对HTML5的完全支持. (我不确定他们完成了什么,但我猜想它是否支持了video元素)

The alternative is to convert the video to one of the supported formats. I would recommend mp4. (Once again libav (avconv) comes in handy here.) This still assumes that Node-Webkit has implemented full HTML5 support. (I am not sure what they have completed but I am guessing it supports the video element)

这篇关于Node-Webkit:如何播放AVI视频?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆