AS2 :: Setting PlayheadTime Of MediaPlayback Component

Nov 8, 2010

I'm building a custom Audio Player. The whole thing drives a MediaPlayback component. I have a scrubber set up that moves with the progress of the song. I want to be able to click and scrub with it though. Currently I have it set to set the playheadTime equal to the percent distance the slider is dragged to times the totalTime of the playback component. After the release of the slider I trace out the playheadTime and it seems to be fine, but I can't get it to resume playing at all. Here's the code in the controller:

var totalDistance = bar_mc._width - slider_mc._width;
var wasPlaying = false;
this.onEnterFrame = function(){

[Code]....

View 1 Replies


Similar Posts:


ActionScript 3.0 :: Can't Get Accurate PlayheadTime In Flvplayback Component

Mar 3, 2011

I use flvplayback to play a 20 seconds flv video, but I can't get accurate playheadTime no matter how to set the attributes.

Here is my as3 codes.

import mx.video.*;my_FLVPlybk.playheadUpdateInterval=10;//my_FLVPlybk.seekBarInterval=100;//FLVPlayback.seekBarScrubTolerance=100;function the_play(eventObject:Object){ ta.text = my_FLVPlybk.playheadTime; // ta is a textarea.}function the_end(eventObject:Object){ ta.text = "video over";}my_FLVPlybk.addEventListener("playheadUpdate", the_play);my_FLVPlybk.addEventListener("complete", the_end);

I drag seekbar to between 0 and 8 seconds, it always obliges to 8.333 .

View 1 Replies

Professional :: Switching Between FLVPlayback Component At Their PlayheadTime

Mar 16, 2012

I am currently on a project (AS3), where I have 2 frames, with videos (using the FLVPlayback component). and I want to switch from one video to the next video, however the catch is when i switch to the next video I want the new video to play at the previous video time. example: Video 1 plays, 10 sec later, you click a button to go and see the next video (in another frame) and that new Video starts 10 sec into it.

[Code]...

View 15 Replies

ActionScript 2.0 :: Use The MediaPlayback Component With An External .flv?

Jun 9, 2004

I'm trying to use the MediaPlayback component with an external .flv The video shows fine, but for some reason the progressbar isn't working.

View 1 Replies

ActionScript 2.0 :: Non Terminating MP3 Download With MediaPlayback Component

Sep 10, 2005

Whenever an MP3 is initiated to stream (well, progressively download really) with the mediaPlayback component, it will contue to dl to the cache until done or the browser is refreshed. The occurs even when the component has been unloaded from an empty movieclip. This is an issue when folks browse alot of MP3s on the site, because even though it's inaudible, suddenly there are many files simultaneously dl'ing to their cache. Cant find a stop stream type of command in the media class, which I think is the only class for the media components. If I were doing real streaming with the Comm Server for example, I could use stopStream.

View 1 Replies

ActionScript 2.0 :: Mediaplayback Component, Control Bar Arrow Pointer Doesn't Move As Media Plays

Jul 4, 2011

Ive used mediaplayback component on a webpage and it works fine except the playhead pointy thing doesnt move as the video plays. Isnt it supposed to do that ? It just stays at the start while the video is actually playing.If i drag the pointer to a different part of the streaming bar then it does what its supposed to do but that doesnt look right.

View 2 Replies

ActionScript 1/2 :: Mediaplayback Component Set "Preview" Image?

Dec 22, 2009

I've searched high and low and haven't been able to figure out a way to set a preview image for video I'm loading in using the mediaPlayback component. Using Flash CS4, AS2.

View 1 Replies

ActionScript 3.0 :: Textfield Holding PlayheadTime?

Feb 1, 2010

I've created a textfield which I want to hold the time that is left of a flv being played. I also created a timer which will see to it that it gets updated.

Here is the code:
"import flash.utils.Timer;
import flash.events.TimerEvent;
var myTimer:Timer = new Timer(1000);
myTimer.addEventListener(TimerEvent.TIMER,updateCo untdown);

[Code]...

However, when i try to compile i get this error message: "1067: Implicit coercion of a value of type Number to an unrelated type String.

View 1 Replies

ActionScript 2.0 :: Setting A Component Variable

Mar 23, 2009

How do I set/access the "Text File" variable as shown in the two pictures. _root and _global don't work.I also tried to access it from _root.CrosswordPuzzle.cp_words_textfile.I don't get components.

View 1 Replies

ActionScript 3.0 :: Setting Parameters Of A Component?

Mar 12, 2009

I'm trying to dynamically set some parameters of a component using AS3. The component has a parameter named "imagePath". I want to set this to a variable named "pathVar" This is where i'm at.

Code:
var pathVar
pathVar="images/folder1"
imagePath=pathVar

This clearly isn't working.

View 1 Replies

ActionScript 3.0 :: Custom Component Inspector Not Setting?

Apr 21, 2009

i never use compenents, and was recently asked to build one. Ha. Anyway, i have a working class that does all i expect, however, when transforming the class to a component, i am having trouble getting the inspector to actually 'set' the variables. below is a very general idea of what i am doing. All the variables show in the spector, but only the default values are working at runtime.

[Code]...

View 2 Replies

AS3 :: Setting Scroll Position For ScrollPane Component?

May 19, 2009

I ve got a series of frames, each with its own instance of a scrollPane called actionText. When navigating from frame to frame I want the vertical scroll position of actionText to reset to 0.For some reason these separate instances of the component are inheriting scroll positions from one another,for example,if I scroll to 50% in one frame, jump to a new frame with a new instance of actionText, that new instance starts at 50%, not 0.

I should be able to set the scroll position by actionText.vPostion = 0 but I get Position is an undefined property of the object actionText .Roll over either the star one or star twotabs and select any action item, scroll the text down (actually a pdf converted to swf), then navigate to another action item and the new scrollPane does not default to 0. Only stars one and two are coded.[url]......

View 3 Replies

Flex :: Setting Variables During Component Initialization

Oct 25, 2010

I am loading a component which makes a HTTPService call to get data that will then be used to set certain variables in the component. I make the HTTPService call in an init() function (for the initialization event) and then set the variables according to the data received in the HTTPService result handler. However, the variables are still null at both the initialize stage and at the creationComplete stage. If I try and read the variables in a creationComp() function (for the creationComplete event), those variables are still null. Is this correct?

I guess I don't understand the flex initialization cycle very well. When are those variables actually set and available to be used? I need to manipulate those variables automatically after the component loads. Is there an event that comes after creationComplete that is appropriate or some other way to approach this? I am using Flex 3.

View 2 Replies

ActionScript 2.0 :: Setting Property Of Duplicated Component?

Aug 31, 2004

ive got a radiobutton component on my stage named radio1. I need to duplicate it and then change a few properties, but i cant seem to get the path/naming right. This is my code:

Code:
i=2;
radio1.duplicateMovieClip("radio"+i, radio1.getNextHighestDepth(), {_x:20, _y:20});
_root["radio"+i].setLabel("test");
i++

if i use a constant name instead of "radio"+i it works but the ["radio"+i] seems to be the problem, could someone help me with this? (using flash mx)

View 7 Replies

Professional :: Setting A Poster Frame In The Flv Playback Component?

Jul 19, 2010

I just spent 2 hours scouring the web for the answer. All I'm seeing is a whole lot of "how do you do it" and a lot of "do a google search for it'. I found a tutorial for CS4 that looked promising yet when I tried it in CS5 the damned Preview attribute (or whatever) just sits there looking at me. You're supposed to be able to click on it and choose a frame. I click and double click and nothing happens.

View 3 Replies

Flex :: Setting Content Area In Custom Component?

Dec 11, 2009

I am trying to define the content area of a custom component that extends mx:VBox. The component has predefined headers and footers (visual children) and I want to set the area in the middle for adding children to the component. The component will be used like this:

<custom_component>
<mx:button/>
</custom_component>

How would I set this content area?

View 3 Replies

Actionscript 3 :: Flex: Setting A Style That Is Not Supported By A Component

Sep 2, 2010

I am wondering if flex enforce style settings and throws compilation errors if a style that is applid to a component that is not supported by it. Has any one tried it before ?

View 1 Replies

Actionscript 3 :: Setting Source Of An Image Component Not Working?

Dec 10, 2011

I'm pulling in a xml-file with just one result in it. One of the nodes is picture, which contains a link to a picture. This is the xml-file:

<artist>
<id>502</id>
<name>Bad Religion</name>

[Code]....

I've tested the url, and it's correct. This is how I try to bind the url to the image instance (artistPic), but it's not working. Displaying the artist name does work.

var artist:XMLList = new XMLList(event.result);
artistPic.source = artist.picture;
lblArtistName.text = artist.name;

View 1 Replies

ActionScript 3.0 :: Setting Listener To Respond To FLV Component On Resize

Jan 11, 2010

I am trying to set a listener so that I can respond to an flvComponent when it resizes etc. I am not uses any home made classes. I have stripped the code right down to this, and it still wont work! Have dragged a flvcomponent onto the stage and given it the instance name myVideo.

ActionScript Code:
stop();
myVideo.addEventListener(AutoLayoutEvent.AUTO_LAYOUT, fred);
function fred(e:AutoLayoutEvent){
trace ("hi from fred");
}

when I test I get "type was not found or is not a compile time constant:AutoLayoutEvent". I can do all sorts of processes like changing flv being played, moving it around etc.

View 2 Replies

ActionScript 2.0 :: FLVPlayback - Setting Path In Component Parameters

Oct 4, 2011

I have a video which has an flvplayback inside. I have been using it for others flv. But with these 3 flv, when I set the path in the component parameters, flash shuts down. I have used aftereffects, media encoder to convert them from mov and avi to flv.

View 0 Replies

ActionScript 2.0 :: DataGrid Component - Setting Stage Width?

Feb 29, 2008

How to get my data grid working so that it is set the stage.width - 250; therefore it would scale with the window when minimized.

View 3 Replies

Flex :: Setting Up Content Children For Custom Mxml Component

Dec 9, 2009

I am trying to develop a custom component to act as a divider.

[Code]....

I would like to use this component to assign objects like this:

[Code]...

Unfortunately, this does not work. I get a compiler error saying: In initializer for 'left': multiple initializer values for target type mx.containers.Canvas.

View 1 Replies

Actionscript 3 :: Setting A Default Skin For A Custom Component In Flex 4?

Aug 18, 2010

How do you set the default value of skinClass for a custom component in Flex? I've extended the DropDownList with my custom component, but I would like to specify a default skin to go with it instead of always setting the skinClass value for each instance.

View 1 Replies

Flex :: Setting Font Size Of Header Of TitleWindow Component?

Mar 7, 2011

How can I set font size of title property (header) in TitleWindow component? If I use fontSize property, it sets the font size for all components in TitleWindow, which is not what I want. I only want to set it for the title. I'm using Flex 3.

View 1 Replies

ActionScript 2.0 :: Setting Component Properties Of Dynamically Created Movieclip?

Mar 2, 2008

I created a movie clip symbol with a user interface in it, using the standard components. It contains various components that I draged on the stage. I named the instances (e.g titleLabel). Then I created an ActionScript class for that user interface. Under the linkage properties of the symbol I specified that class. In the class itself, i declared the attribute "var titleLabel:Label". I thought this would be the same instance from the symbol? But: Trying to set the text of the Label AFTER the movie was dynamically added to the parent does not work. I cannot access any properties.

Here is the example:

My Class for the user interface:

Code:
import mx.controls.*;
class Information extends MovieClip {
var titleLabel:Label; //this is the same instance name as in the symbol

[Code].....

View 1 Replies

ActionScript 3.0 :: Flash - Setting The Color Of The Text Of A TextInput Component

Oct 22, 2010

I'm having trouble setting the color of the text of a TextInput component. I know there is a TextField within it, I'm trying several methods, but none works:

[Code]...

View 1 Replies

IDE :: CS4 Loop In Mediaplayback?

May 30, 2011

i'am doin a presentation and i put music bg in a mediaplayback component, but i need it in a loop.

View 1 Replies

Mxml - Mx:MediaPlayback Flex Tag?

Oct 22, 2009

I'm trying to compile gui/flex/songs.mxml in the fourth edition of Bruce Eckel's Thinking in Java book and am getting a compilation error with Flex 3.4.

Here is a simplified version of the example that gives the same error:

[Code]...

View 1 Replies

Flex :: Setting Skin Class On A Host Component But It Is Giving Null Point Exception?

Apr 19, 2011

ADOBE SYSTEMS INCORPORATED Copyright 2008 Adobe Systems Incorporated All Rights Reserved. NOTICE: Adobe permits you to use, modify, and distribute this file in accordance with the terms of the license agreement accompanying it.

[Code]...

View 1 Replies

Calling From XML Playlist And Playing MP3 With MediaPlayBack

Jan 15, 2010

I've got a problem to play MP3 with MediaPlayBack, calling from a XML playlist. The playlist seems to work but not the MediaPlayBack which doesn't load the MP3...

Here is my XML code named mp3list.xml
<?xml version="1.0" encoding="utf-8"?>
<musiques>
<musique url="musique/01.mp3" desc="titre 1" />
<musique url="musique/02.mp3" desc="titre 2" />
<musique url="musique/03.mp3" desc="titre 3" />
[Code] .....

View 4 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved