FLV播放,全屏流畅吗?

发布于 2024-09-05 04:51:25 字数 226 浏览 4 评论 0原文

我正在考虑在项目中使用和自定义 FLVPlayback。如何解决这个问题很清楚,但我注意到一件烦人的事情。当进入全屏时,Flash 播放器首先进入全屏,然后以其原始大小短暂显示 FLVPlayback 组件,然后跳转到全屏显示视频本身。

我在 YouTube 上注意到这并没有发生。我怎样才能避免这种“闪烁”并使视频像 YouTube 上的视频那样全屏显示?

非常感谢您的任何提示!

马塞尔

Im looking into using and customizing FLVPlayback in a project. How to go about this is clear, but I noticed 1 anoying thing. When going fullscreen, first Flash player goes fullscreen and then briefly shows the FLVPlayback component in its original size, before jumping to show the video itself fullscreen.

I noticed on Youtube this doesnt happen. How can I escape this 'flicker' and have the video go fullscreen as the videos do on youtube?

Thanks a lot for any tips!

Marcel

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

梦与时光遇 2024-09-12 04:51:25

一般来说,FLVPlayback 以及 Flash 内置的大多数组件都是垃圾。使用 NetConnection 和 NetStream 类构建自己的 flv 播放器会更好。一旦构建好并足够通用以编辑控制视觉效果,您就拥有了适合您所有项目的防弹 flv 播放器。

http://actionscriptexamples.com/2008/02/26/loading-flv-files-in-actionscript-30-using-the-netconnection-and-netstream-classes/

in general FLVPlayback along with most of the components built into flash are junk. You are much better off building your own flv player using the NetConnection and NetStream class. Build it once well and generic enough to edit the control visuals and you have yourself a bullet proof flv player for all your projects.

http://actionscriptexamples.com/2008/02/26/loading-flv-files-in-actionscript-30-using-the-netconnection-and-netstream-classes/

迷离° 2024-09-12 04:51:25

只是说我在工作中多次使用 FLVPlayback,并且肯定它有问题,但我从未见过这个问题。你绝对可以修复它。你怎么全屏?我最近正在做这样的事情...

import flash.display.*;
import flash.events.*;
import fl.video.*;
import flash.geom.Rectangle;

.
.
.

myFLVPlayback.fullScreenTakeOver = false;
mc.stage.fullScreenSourceRect = new Rectangle(0,0,480,360);
myFullScreenButton.addEventListener(MouseEvent.CLICK, onFullScreenButtonClicked);

private function onFullScreenButtonClicked(e:MouseEvent):void {
  mc.stage.displayState = StageDisplayState.FULLSCREEN;
}

(尽管我很欣赏您可能在 FLVPlayback 皮肤中使用全屏按钮,所以这可能不完美)

注意:我只是敲敲代码,所以它可能不完美/完全的。希望您会发现它很有用。

++ 我会确保你也设置了 flvplayback 的大小和比例,例如 myflvplayback.setSize(w,h)

++ myflvplayback.scaleMode = VideoScaleMode.NO_SCALE;

Just to say I've used FLVPlayback on jobs many times, and sure it's buggy, but I've never seen this problem. You can definitely fix it. How are you going fullscreen? I've recently being doing something like this...

import flash.display.*;
import flash.events.*;
import fl.video.*;
import flash.geom.Rectangle;

.
.
.

myFLVPlayback.fullScreenTakeOver = false;
mc.stage.fullScreenSourceRect = new Rectangle(0,0,480,360);
myFullScreenButton.addEventListener(MouseEvent.CLICK, onFullScreenButtonClicked);

private function onFullScreenButtonClicked(e:MouseEvent):void {
  mc.stage.displayState = StageDisplayState.FULLSCREEN;
}

(though i appreciate you might be using the fullscreen button in an FLVPlayback skin, so this might not be perfect)

NOTE: I just hammered that code in so it might not be perfect/complete. Hopefully you'll find it useful.

++ i'd make sure you set the size and scale of your flvplayback too, e.g. myflvplayback.setSize(w,h)

++ how about myflvplayback.scaleMode = VideoScaleMode.NO_SCALE;

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文