PDA

View Full Version : Insert advertisement in a flash player while the video is buffering


sukhmaniaps
08-18-2007, 11:52 AM
Hi!,
I have a web site with videos and they will be streamed thru a flash player. Now my requirement is basically a skin with the following feature..

A JPEG Advertisement is displayed while the video connects and buffers. Once the video is ready, the JPEG is removed and the video plays. At the completion of the video, the JPEG is replaced. I shall be using a banner ad management software so as to make a geo targeting ad..

Well my requirement is that I need to have static advertisement displayed while the video connects and buffers. JPEG is removed and the video plays. At the completion of the video, the JPEG is replaced.

Can anyone help me as to how it is done OR give me script for the same.

Can this be included in my existing flash player skin OR do I have to develop a new skin.

Please feel free to contact me on my email.. [email protected]
regards,
Ajeet

sukhmaniaps
08-18-2007, 11:56 AM
Hi!,
I have a web site with videos and they will be streamed thru a flash player. Now my requirement is basically a skin with the following feature..

A JPEG Advertisement is displayed while the video connects and buffers. Once the video is ready, the JPEG is removed and the video plays. At the completion of the video, the JPEG is replaced. I shall be using a banner ad management software so as to make a geo targeting ad..

Well my requirement is that I need to have static advertisement displayed while the video connects and buffers. JPEG is removed and the video plays. At the completion of the video, the JPEG is replaced.

Can anyone help me as to how it is done OR give me script for the same.

Please feel free to contact me on my email.. [email protected]
regards,
Ajeet

stompwampa
08-18-2007, 10:03 PM
you could essentially just write a conditional statement that says if your stream video is loading, then display jpg into imageLoader if stream video loading is complete, load stream video into imageLoader.
I'm not really sure how all the code would look...but thats about how you could do it.

flexy
08-19-2007, 10:08 AM
I see you have also posted this on the AS3 board. Are you trying to do this in Flash or Flex, as you haven't stated this.

panel
08-19-2007, 05:09 PM
You just have to listen for two events playing and buffering. I can write code but first tell me are you using FLVPlayback Component or .Net stream class to play video?

backslash007
09-17-2007, 02:58 PM
hi!

i have the exact same problem! also looking for a possibility to display a jpg (or video) while the video is buffering... do you have any suggestions? i'm using FLVPlayback Component

thanks a lot!

panel
09-17-2007, 08:12 PM
hi!

i have the exact same problem! also looking for a possibility to display a jpg (or video) while the video is buffering... do you have any suggestions? i'm using FLVPlayback Component

thanks a lot!


import fl.video.VideoEvent ;

FLVPlayback.addEventListener(VideoEvent.BUFFERING_ STATE_ENTERED, onBufferingStateEntered)

function onBufferingStateEntered(evt:VideoEvent):void
{
//show image
}


to hide image listen for PLAYING_STATE_ENTERED.
Chech help about FLVPlyback documentation
F1 -> Actionscript 3.0 components -? all clases -> FLVPlayback