ActionScript 3.0 :: Flv Length/creating A Seek Bar?
May 15, 2010
I'm using the following code to load a flv:
var connection:NetConnection = new NetConnection();var stream:NetStream;var videoMain = new Video(600,340);var metaObj:Object = new Object();
function onMetaData(data:Object):void{}
[Code].....
I can create play/pause funtionality just fine with stream.play(); and stream.pause();, but I also want to have a seek bar for the user to scrub. I'm just starting this, and I think I can do it once I figure out how to call the flv total length and link it to a custom seek bar movieclip. So is there a way to call on the total length of a flv file?
such as:
var videoLength:uint = videoMain.length;
View 1 Replies
Similar Posts:
Mar 9, 2011
Let's say I have array foo and a positive integer y, where foo.length > y.I want to remove elements from foo so that foo.length becomes y (or very close to it).Also, I need to preserve the first and last element of foo. The indices of the removed elements must be spaced apart as equally as possible. Foo can be sliced, or it can be used to create a new array.
Example: if foo = [a,b,c,d,e,f,g,1,2,3,4,5] and y = 6, then trimmedfoo could be [a,c,e,g,2,4,5] or maybe [a,c,e,2,4,5], but not [a,c,e,g,2,4] because the last element of foo is missing.
View 4 Replies
Dec 22, 2011
how to do this
function foo(x:*, ...args):* {
}
function bar(x:*, ...args):* {[code].....
how to expand args ? when I call bar(1,2,3), I wish it call foo(1,2,3), but it call foo(1,[2,3])
View 2 Replies
Apr 19, 2011
Is there any way to determine if a (anonymous) function has defined the ...(rest) parameter in ActionScript 3? I know there's the function.length property, but it only counts the explicitly defined arguments.
View 2 Replies
Dec 16, 2004
I am trying to get the length of arrays within an array, here is my example (MX 2004):
[Code]...
I get an output of of 3. the number of variables within the first array, this is not what I had expedted.
View 2 Replies
Feb 5, 2010
do anyone know how to script the dynamic text length to the amount of text in the text file instead of manually drag it to the length?
Code:
myLoadVars_lv = new LoadVars();
myLoadVars_lv.onLoad = function(success) {
[code].....
View 0 Replies
Aug 13, 2011
I am trying to use the class Sound of actionscript.My code is really basic :
var snd:Sound = new Sound();
snd.load(new URLRequest("mysound.mp3"));
trace( new String(snd.length));
snd.play();
The audio is playing very well but in my trace, I get 0 instead of the length in milliseconds of the Sound.
View 1 Replies
Nov 16, 2009
Is it possible to use Flowplayer (flowplayer.org) and the seek() function with an FLV file?
View 3 Replies
Jun 1, 2010
I have created a flash movie in AS3, I wanted to have a seek bar [or a Back and Forward button] to move my movie forward/backward.
View 1 Replies
Aug 4, 2008
I am working on a music player where the music list is loaded using xml. I am using sound object and the streaming property is set to 'true'. Now I want to calculate sound.duration, but I don't get the actual value when it is streaming, probably because the entire file is not downloaded at once because of streaming, and it is returning the duration of the portion of the file downloaded. So I am unable to develop a seek bar which shows the current position of the music.
I even tried to get the file duration using ID3 tag but the TIME property does not seem to work either.
Another options could be using php to get the duration of the mp3 file and generate an xml file which specifies the duration of the file.
View 9 Replies
Oct 24, 2008
if Flash can listen for a click/drag on the seek bar playhead from the FLV player controls? I'm attempting to perform an action when a user drags the playhead through the video.
View 2 Replies
Sep 24, 2009
I built an MP3 player a couple years back in AS2. I have tried various tutorials and can't seem to implement a basic seek bar. I am hoping for something with a draggable scrubber bar.I have attached the .as file, and stripped out all my failed seek bar code. It's currently published to work with Flash Player 8, and works fine - except for no seek bar.
View 2 Replies
Sep 29, 2011
iam using media display for display video , and media controller for controlling flv video, i want the seek bar to be clickable ,i made the clicking,but how to make the video to jump to the clicked time line. iam editing the mediacontroller.fla in .../en/components/ and coverting it into swc and using it
on(release)
{
var mcli = _parent._tray._xmouse;
[code].....
View 1 Replies
Oct 29, 2009
I'm building an flv player using the cs4/as3 video playback component as a basis with custom buttons on the interface. I'm trying to figure out how to do rewind or fastfoward using a button instead of a scrub bar. I've seen plenty of tutorials on how to develop a scrub bar but I can't figure out a way to apply the theory to a button you hold down and it fast forwards/rewinds until you mouse off.
Obviously a mouse_down event only fires one signal and causes a jump effect if you click repeatedly, so is there a way of firing multiple events whilst holding down the mouse button?
Code:
flvPlaybackComponentname.seek(flvPlaybackComponentname.playheadTime + fastForwardSeekAmount);
to achieve the skip through the video, but this only happens as I said with multiple clicks.
View 4 Replies
Oct 27, 2008
I'm not able to create a working seek bar (or progress bar or timeline bar) to give the viewer complete control for where they want to play an animation. The animation is a .fla file, which moves frame-by-frame with motion tweens). There are 4446 total frames (at 12 fps), so I'd like the viewer to be able to skip ahead or back as they desire. The instructions I've found so far all have to do with FLV files instead of FLA.I've tried the following Actionscript, but I get errors(which are also listed below). As the seek bar object, I'm using the UIScrollBar (with a horizontal direction).[code]I'm more than willing to try a different Actionscript.
View 4 Replies
Apr 6, 2009
When working with MOV files using the h.264 codec and AAC sound I am unable to get netStream.seek to work correctly. No matter what argument I pass to netStream.seek it will always seek to 0. I have this problem on both a legacy as2 and a newer as3 video player I have built. Regular flvs work perfectly on both players.
View 1 Replies
Sep 22, 2009
I have child movie in a project that contains a FLV Playback instance with an associated Seek Bar component. The child movie fades in and fades out when a button is pressed. When a the child movie fades-out, the handle of the seek bar is retained. If I watch the movie multiple times, multiple seek bar handles remain behind.
[URL]
Click the "View Entry Footage" button and then click the "Return to Map" button.
View 2 Replies
Aug 2, 2010
Do you know why the VideoDisplay.seek() would always go to the same frame at 1 second, no matter whether it is asked to seek forward or backward? This happens to some MP4 and other others. Is there some functions or variables I need to set?The MP4s that don't work with VideoDisplay.seek(), can be seeked using Quicktime.
View 5 Replies
Mar 26, 2011
I know seeking to a cue point is known to be inaccurate at times so I'm wondering if the accuracy of seeking to time and secs better. So far I've seen no true difference.
View 12 Replies
May 30, 2011
Currently i am working with the dvr functionality here i need to set the seek bar for the video. This could be used to seek the video to the particular position. I don't know how to set the maximum time on the seek bar dynamically (Since its DVR maximum time will be increase if publishing video is continues) .I think through the metadata we can get the total time of video Tell me how to call the metadata externally .
View 5 Replies
Jul 18, 2011
My FLV is paused and I do a seek to FLVPlayback.playheadTime-1. This i.e. equals to 22-1=21. It works, but than VideoEvent.PAUSED_STATE_ENTERED is called and my trace shows playheadTime = 22 and nothing changed. If I seek to playheadTime+1. This i.e. equals to 22+1=23 my onPaused trace shows playheadTime = 24 and my FLV advanced 2 sec. not 1. So there is always 1 sec. added to playheadTime and its cut to absolut .000 numbers.
It seems like FLVPlayback alligns my seek into blocks of 2 seconds. But I need to position more accurately and jump in half seconds even.
[Code].....
View 6 Replies
Jul 15, 2010
I have 2 identical ASP.NET applications, one running on Windows Server 2003 with IIS6 and another running on Windows Server 2008 with IIS7.
The one on IIS6 runs perfectly, but on IIS7 I'm unable to seek while playing my video. They are both using the exact same HTTP-handler for streaming.
I'm using the JW player for Flash (v. 5.2) and Sorenson Squeeze 6 for converting the videos from .mpg to flv. The FLV stream-handler is very (but not completely) similar to the one on this site
The one on IIS6: demo.orbicon.dk/wgv
The one on IIS7: kloakkort.nk-forsyning.dk/webgrafvideo/?filename=15050
View 1 Replies
Aug 3, 2009
i am working in Flash AS2. still now i want one flv video play back with seek bar control animation script (not a Flvplayback component).
View 0 Replies
Nov 19, 2010
Does anyone know of any tutorials that explain how to make a seek bar with a handle that will be linked to the main timeline, so that when you move the handle the animation will move too, e.g. if you drag the handle to the centre of the bar then it will skip to the middle of the animation?
I currently have a handle that move on the x axis with in a set boundary, but not sure how to link it to the main timeline.
View 0 Replies
Dec 17, 2010
I'm using the FLVPlayback component and using ClearExternalAll as my skin. I noticed that the SeekBarHandle does not move while the video is playing. I can drag the handle to go to different parts of the video, but it does not move by itself as the video plays. All other buttons work fine. I've already tried setting the total FLV video length in the parameters, but that didn't work. How to make the slider move as the video plays. Is there any other skin i can download from ??
I am using
import mx.video.*;
if(movB == 1){
vidPlayer1.load("images/01.flv");
vidPlayer1.isLive = true;
vidPlayer1.totalTime = 165;
}else if(movB == 2){
[Code] .....
View 1 Replies
Jun 21, 2011
I'm trying to build a circular player. I've done it with a mask but the seek bar is missing. I couldn't find a circle one. The seeking is not necessary. I want to at least show how much played of how much.
View 0 Replies
May 22, 2009
Now i am doing a FLV Player. But how to make a seek bar for that.?
View 5 Replies
Apr 23, 2008
I want to make seek bar in my MP3 Player.
View 1 Replies
Mar 21, 2009
So I have a flash file I'm working on. I have an FLVPlayback Component inside a movie clip called mcVideo. I have that clip set up with a MainVideo class which sets the player and all the controls.
Everything works except that I do not receive a seekbar handle, ever. I get a seekbar that shows the loading progress, but the handle never appears. Whether I create an instance of the seekbar in the AS3 class or if I drag an instance of it onto the stage of mcVideo. The loading progress always shows, but never the actual handle.
View 1 Replies
May 11, 2009
I'm looking for a tutorial on the interwebs to create a scrubber for the length of a movie clip.For example:If a movieclip is 300 frames long, the beginning of the scrubber would be Frame 1 and the end would be Frame 300 with Frames 2-299 in the middle.I'd like the user to be able to scroll through the movie much like a Quicktime VR
View 2 Replies