Flash翻轉式影片播放器
這是一個結合Tweener和影片的範例,主要的目的是利用Flash載入外部視訊來播放,順帶利用ActionScript來做畫面的翻轉,翻轉後可以詳細介紹該影片的資訊,或是版權宣告等,先看看範例頁面,檔案下載,要製作這樣的動畫,首先要先準備一段影片檔,我的範例中所準備的是利用數位相機拍攝出來的影片,再利用Adobe Media Encoder轉換成大小為640×360,F4V格式的影片,再利用Flash內建的組件FLVPlayback來播放。
資料夾檔案結構如下:
- Caurina是Tweener Class大家可以到Tweener的官網下載,前述文章有連結。
- 3dflip.fla、3dflip.html、3dflip.swf是Flash的原始檔、網頁檔以及播放檔。
- Shengxing為本範例所使用到的影片檔。
- SkinUnderPlaySeekMute為播放器的面板檔。
而在下圖是在Flash中的結構:
- container是包含播放器、解說文字的影片片段,該元件包含FLVPlayback播放器組件(Video)和解說文字(Text)兩個圖層。
- FLVPlayback是Flash內建的影片播放器組件。
- loading影片載入時會出現的文字。
- spin影片右上角旋轉的按鈕。
- text包含有介紹文字的影片片段,文字中亦製作有超連結(維基百科)。
- vid如果有自己的影片想要更換,請進入名為Vid的影片片段中利用屬性面板修改。
本範例所包含的ActionScript都在場景中的第一個影格,程式碼如下:
import caurina.transitions.*; import fl.video.*; con.visible = false; var flv:FLVPlayback = con.vid.flvp; flv.addEventListener(VideoEvent.PLAYING_STATE_ENTERED, onStart); function onStart(e:Event):void { con.visible = true; loading.visible = false; } con.vid.spin.addEventListener(MouseEvent.CLICK, cl); con.tclip.spin.addEventListener(MouseEvent.CLICK, cl); var isTurning:Boolean = false; function cl(e:Event):void { if(!isTurning) { Tweener.addTween(con, {rotationY:con.rotationY+180,time:1, onComplete:function(){isTurning=false;}}); isTurning = true; } } addEventListener(Event.ENTER_FRAME, loop); function loop(e:Event):void { if(con.rotationY > 90 && con.rotationY < 270) con.addChild(con.tclip); else con.addChild(con.vid); if(con.rotationY >= 360) con.rotationY = 0; }
This is a topic that’s near to my heart… Take care! Exactly where can I find the contact details for questions?
Kasino di Jakarta memiliki berbagai pilihan permainan http://slot88.company/# Slot klasik tetap menjadi favorit banyak orang
See What The Glass Doctor Tricks The Celebs Are Using The glass Doctor
http://garuda888.top/# Slot klasik tetap menjadi favorit banyak orang
https://ok-sochi.ru – Официальный сайт производителя кухонь.
What’s up to every one, the contents present at this web site are actually amazing for people experience, well, keep up the good
work fellows. https://Utahsyardsale.com/author/trentrausch/
http://bonaslot.site/# Mesin slot menawarkan berbagai tema menarik
Keseruan bermain slot selalu menggoda para pemain: BonaSlot – bonaslot
Slot dengan fitur interaktif semakin banyak tersedia: garuda888.top – garuda888
п»їKasino di Indonesia sangat populer di kalangan wisatawan https://slot88.company/# Slot memberikan kesempatan untuk menang besar
Spot on with this write-up, I absolutely think this web site needs a lot more attention. I’ll probably be returning to read through more, thanks for the info!
лучшие фильмы 2025 подборка hdrezka сериалы драмы на телефоне
Kasino memastikan keamanan para pemain dengan baik https://slot88.company/# Mesin slot menawarkan pengalaman bermain yang cepat
http://garuda888.top/# Pemain harus memahami aturan masing-masing mesin
Greetings! Very helpful advice in this particular article! It is the little changes that produce the greatest changes. Many thanks for sharing!
akun demo slot slot demo gratis Banyak kasino memiliki program loyalitas untuk pemain
Excellent site you have got here.. It’s difficult to find high-quality writing
like yours these days. I seriously appreciate individuals like you!
Take care!! http://Drsarapharmd.com/__media__/js/netsoltrademark.php?d=blog-Kr.Dreamhanks.com%2Fquestion%2Fservices-de-gestion-immobiliere-a-laval-optimisez-la-gestion-de-vos-proprietes-22%2F
Great blog! Do you have any suggestions for aspiring writers?
I’m planning to start my own website soon but I’m a little lost on everything.
Would you advise starting with a free platform like WordPress or go for a paid option? There are so many choices
out there that I’m completely overwhelmed .. Any recommendations?
Bless you!
Feel free to visit my web page :: หวยลาวซุปเปอร์ ล่าสุด
купить диплом о высшем образовании ссср
купить аттестат об окончании 9 классов
кухни на заказ – Широкий выбор кухонь на заказ с гарантией качества.
Have you ever thought about writing an ebook or guest authoring
on other blogs? I have a blog based upon on the same subjects you discuss and
would love to have you share some stories/information. I know my visitors
would appreciate your work. If you are even remotely interested, feel free to shoot me an email. http://Ptxperts.com/question/re-max-crystal-a-sainte-therese-votre-partenaire-de-confiance-pour-limmobilier/
Kasino menawarkan pengalaman bermain yang seru: slot demo – demo slot pg
https://symbol-icons.com/selling-hookahs-shisha-and-accessories-ways-to-increase-sales.html
This is a really good tip especially to those new to the blogosphere. Brief but very accurate info… Thank you for sharing this one. A must read post.
slot88.company slot 88 Slot menjadi bagian penting dari industri kasino
http://bonaslot.site/# Slot dengan grafis 3D sangat mengesankan
Slot menawarkan berbagai jenis permainan bonus http://bonaslot.site/# Kasino menawarkan pengalaman bermain yang seru
http://slotdemo.auction/# Pemain sering berbagi tips untuk menang
кухни от производителя – Кухни напрямую от производителя без переплат.