吸血莱恩1电影的videooptions咋么选

吸血莱恩2无法运行,电脑高手请进_百度知道&Requirements
User level
Intermediate
参考知识库
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
访问:563次
排名:千里之外Adding options to video.js - Stack Overflow
to customize your list.
Announcing Stack Overflow Documentation
We started with Q&A. Technical documentation is next, and we need your help.
Whether you're a beginner or an experienced developer, you can contribute.
I'd like to be able to configure controlsBelow and controlsHiding (always show controls below), but the only way I found to be able to do that is with VideoJS.setupAllWhenReady() (which appears to be a previous version of VJS), not with videojs() as the current docs (v4.12, at the time of this post) say to use. Nothing in the doc's option page mentions either of these options, so perhaps it's not supported anymore?
var setup = {
"techOrder" : ['html5', 'flash'],
"controls": true,
"preload": "auto",
"children": {
"controlBar": {
"children": {
"volumeMenuButton": true,
"muteToggle": false,
"volumeControl": false // displays volume control bar atop button
var player = videojs('player', setup, function(){
var myPlayer =
myPlayer.play();
&link href="//vjs.zencdn.net/4.12/video-js.css" rel="stylesheet"/&
&script src="//vjs.zencdn.net/4.12/video.js"&&/script&
&div class="video-js-box"&
&video id="player" class="video-js vjs-default-skin vjs-big-play-centered vjs-block-error" width="640" height="264" controls preload poster="http://video-/oceans-clip.png"&
&source src="http://video-/oceans-clip.mp4" type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"' /&
&source src="http://video-/oceans-clip.webm" type='video/ codecs="vp8, vorbis"' /&
&source src="http://video-/oceans-clip.ogv" type='video/ codecs="theora, vorbis"' /&
&!-- Flash Fallback. Use any flash video player here. Make sure to keep the vjs-flash-fallback class. --&
&object class="vjs-flash-fallback" width="640" height="264" type="application/x-shockwave-flash"
data="http://releases.flowplayer.org/swf/flowplayer-3.2.1.swf"&
¶m name="movie" value="http://releases.flowplayer.org/swf/flowplayer-3.2.1.swf" /&
¶m name="allowfullscreen" value="true" /&
¶m name="flashvars" value='config={"playlist":["http://video-/oceans-clip.png", {"url": "http://video-/oceans-clip.mp4","autoPlay":false,"autoBuffering":true}]}' /&
¶m name="bgcolor" value="#f30000"&
¶m name="wmode" value="opaque"&
&!-- Image Fallback. Typically the same as the poster image. --&
&img src="http://video-/oceans-clip.png" width="640" height="264" alt="Poster Image"
title="No video playback capabilities." /&
1,12411217
After pretty thoroughly reading through the code, I don't see either of these options being available as I feared (I was just hoping someone might know something I didn't). I had already set the control bar to always display (don't fade out after a brief period of user inactivity, as is the default behavior) and to display below the video rather than on top of it via CSS, but in fullscreen mode the control bar would slip beneath the browser's viewport (eek). I ended up adding a :not() selector to keep the default behavior in fullscreen mode. That'll work for me.
var setup = {
"techOrder" : ['html5', 'flash'],
"controls": true,
"preload": "auto",
"children": {
"controlBar": {
"children": {
"volumeMenuButton": true,
"muteToggle": false,
"volumeControl": false // displays volume control bar atop button
var player = videojs('player', setup, function(){
var myPlayer =
myPlayer.play();
/* force control bar to display at all times if not in fullscreen mode */
.vjs-default-skin:not(.vjs-fullscreen).vjs-has-started .vjs-control-bar {
display: block !
visibility: visible !
opacity: 1 !
/* move under video if not in fullscreen (else it will disappear below the browser viewport */
.vjs-default-skin:not(.vjs-fullscreen) .vjs-control-bar {
bottom: -30
&link href="//vjs.zencdn.net/4.12/video-js.css" rel="stylesheet"/&
&script src="//vjs.zencdn.net/4.12/video.js"&&/script&
&div class="video-js-box"&
&video id="player" class="video-js vjs-default-skin vjs-big-play-centered vjs-block-error" width="640" height="264" controls preload poster="http://video-/oceans-clip.png"&
&source src="http://video-/oceans-clip.mp4" type='video/mp4; codecs="avc1.42E01E, mp4a.40.2"' /&
&source src="http://video-/oceans-clip.webm" type='video/ codecs="vp8, vorbis"' /&
&source src="http://video-/oceans-clip.ogv" type='video/ codecs="theora, vorbis"' /&
&!-- Flash Fallback. Use any flash video player here. Make sure to keep the vjs-flash-fallback class. --&
&object class="vjs-flash-fallback" width="640" height="264" type="application/x-shockwave-flash"
data="http://releases.flowplayer.org/swf/flowplayer-3.2.1.swf"&
¶m name="movie" value="http://releases.flowplayer.org/swf/flowplayer-3.2.1.swf" /&
¶m name="allowfullscreen" value="true" /&
¶m name="flashvars" value='config={"playlist":["http://video-/oceans-clip.png", {"url": "http://video-/oceans-clip.mp4","autoPlay":false,"autoBuffering":true}]}' /&
¶m name="bgcolor" value="#f30000"&
¶m name="wmode" value="opaque"&
&!-- Image Fallback. Typically the same as the poster image. --&
&img src="http://video-/oceans-clip.png" width="640" height="264" alt="Poster Image"
title="No video playback capabilities." /&
1,12411217
Your Answer
Sign up or
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Post as a guest
By posting your answer, you agree to the
Not the answer you're looking for?
Browse other questions tagged
Stack Overflow works best with JavaScript enabled

参考资料

 

随机推荐