External Play Button Controlling Flv In Mediaplayback Component
Hi all,
Can someone pleeez help me.
I am trying to use a flv in the mediaplayback component and control it with a button, just like YouTube. Where it disappears once it is clicked and changes the play button on the mediaplayer as if it was clicked as well. I cannot use the components as I am limited to using Flash 7.
I am also wanting the first image to be the frame 10 seonds into the flv onload.
Any help or ideas would be great.
Thanks
thepopguy
Edited: 08/31/2007 at 09:09:16 AM by thepopguy
Adobe > ActionScript 1 and 2
Posted on: 08/31/2007 08:10:38 AM
View Complete Forum Thread with Replies
Sponsored Links:
How To Play Embedded Audio File With Mediaplayback Component
Hi,
Is there anyway to play an audio file that is embedded in the swf that I am creating using the mediaPlayBack component. The reason I want to use the mediaPlayBack component is because it has the timer/progress bar showing how much of the file has already played. Currently im using this to play the audio file.
play.onRelease = function () {
s = new Sound();
s.attachSound("audio"); //in the green, put the sound linkage id
s.start(0,1);
}
stop.onRelease = function () {
s.stop();
}
But I dont know how to expanded upon his to include a timer/progress bar. Im not very good with actionscript. I can't seem to find any tutorials that show how to create a timer/progress bar for any audio that uses "attachSound". If someone can help me out with this I would really appreicate it.
Thank you,
View Replies !
View Related
MediaPlayBack Component, Forward Button Grayed Out
I am using the mediaplayback component and it plays the FLV fine when I test it. It allows me to pause and play and rewind to the first frame, but the fast forward button to go to the end of the flv is grayed out. I don't know why? Also I am loading a swf to play as a preloader when the flv is done loading. What functions do I use to code this. thanks!
View Replies !
View Related
Please Help, Controlling An External Flv (not Component)
Below is the code for loading in my flv within its own swf (other). The swf is loaded from another swf (main) through a loader. What I need to do now is to stop, pause and or seek the flv inside (other), from the (main) swf. Or... I need to navigate back to the (main) swf from inside the (other) swf... I am goin crazy with this, and I hope it is a simple procedure, so please throw me a bone...
//(other)loads the flv
var vid:Video;
var nc:NetConnection;
var ns:NetStream;
var vidURL:String = "architechture.flv";
nc = new NetConnection();
nc.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
nc.addEventListener(SecurityErrorEvent.SECURITY_ER ROR, securityErrorHandler);
nc.connect(null);
function netStatusHandler(event:NetStatusEvent):void {
switch (event.info.code) {
case "NetConnection.Connect.Success" :
playVideo();
break;
case "NetStream.Play.StreamNotFound" :
trace("Unable to load video.");
break;
}
}
function playVideo():void {
ns = new NetStream(nc);
ns.addEventListener(NetStatusEvent.NET_STATUS, netStatusHandler);
ns.addEventListener(AsyncErrorEvent.ASYNC_ERROR, asyncErrorHandler);
vid = new Video(480, 360);
vid.x = 348;
vid.y = 119;
vid.attachNetStream(ns);
ns.play(vidURL);
addChild(vid);
}
function securityErrorHandler(event:SecurityErrorEvent):voi d {
trace("securityErrorHandler: " + event);
}
function asyncErrorHandler(event:AsyncErrorEvent):void {
// ignore AsyncErrorEvent events.
}
btnBack.addEventListener(MouseEvent.CLICK, skipp);
function skipp(event:MouseEvent):void {
removeChild(vid);
ns.pause();
ns.seek(0);
if (this.parent != null) {
this.parent.removeChild(this);
gotoAndPlay("skip");
}
}
//(main)loads in the swf containing the flv
var ArchLoader:Loader = new Loader();
ArchLoader.load(new URLRequest("arch_const.swf"));
addChild(ArchLoader);
//(other) removes the sound and flv
btnBack.addEventListener(MouseEvent.CLICK, skipp);
function skipp(event:MouseEvent):void {
removeChild(vid);
ns.pause();
ns.seek(0);
if (this.parent != null) {
this.parent.removeChild(this);
this.parent.parent.parent.gotoAndPlay("skip");
}
}
I have tried localConnection (never used it) as well, but maybe my syntax is incorrect...
Any help is greatly appreciated...
Thanks
View Replies !
View Related
Controlling External Set Of Movies With Play Pause And Skip Buttons
hi all,
Been looking for some tutorials on how to get this done but cannot find any. After I build this out I want to post up in the tutorials section.
Ok I was wondering if someone could help me on this small problem I am having. I have a total of 4 flash movies. The first movie will house all my navigation as shown below:
[Movie 2] [Movie 3] [Movie 4] [Pause] [Play ] [Skip to Next Movie]
The simple part of course are the first 3 buttons basically just loadmovie statements.
Now the next 3 buttons are the part I cannot quite figure out. The logic from what I have been reading is basically is the create a variable on the mainstage that updates itself each time a new movie is playing. This way you can tell the movie "pause" or "play" because it has a name.
Any actionscripters want to lend a hand on this? I have included the files all setup just need to few lines of scripting. I want to also post this as a tutorial since I cannot locate any tutorials with this sort of logic.
thanks in advance!
View Replies !
View Related
Why Isn't The Play Button Controlling Sound?
I am working on a gallery / mp3 player. There are thumbnail photos that I am using to control which sound file is loaded and playing. However the play button doesn't work, even after clicking on the thumbnails. The function bigPicPosition is controlling what sound is playing.
I apologize for the sloop that is my code, but I've stopped and restarted writing this many times. All code is run from the main timeline.
Attach Code
this.pauseBTN.visible = false;
var thumbsArray:Array = [thumbs_mc.thb1_btn,thumbs_mc.thb2_btn,thumbs_mc.thb3_btn,thumbs_mc.thb4_btn,thumbs_mc.thb5_btn,thumbs_mc.thb6_btn,thumbs_mc.thb7_btn,thumbs_mc.thb8_btn,thumbs_mc.thb9_btn];
// Which Interview should we listen to?
var interviewArray:Array = ["sound1.mp3","sound2.mp3","sound3.mp3","sound4.mp3","sound5.mp3","sound6.mp3","sound7.mp3","sound8.mp3","sound9.mp3"];
var interviewLengthArray:Array = [200385,200385,200385,200385,200385,200385,200385,200385,200385];
var arrayNumber:Number = 0;
var currentInterview:String = interviewArray[arrayNumber];
var currentLength:Number = interviewLengthArray[arrayNumber];
var interviewURL:URLRequest = new URLRequest(currentInterview);
var sound:Sound = new Sound();
//Controlling the Sound
var channel:SoundChannel;
var resumeTime:Number = 0;
var playingSound:Boolean = false;
addEvents();
function addEvents():void {
for (var i:Number = 0; i < 9; i++) {
thumbsArray[i].addEventListener(MouseEvent.CLICK, picSong);
}
}
function picSong(event:MouseEvent):void
{
for (var i:Number = 0; i < 9; i++)
{
if (event.target == thumbsArray[i])
{
arrayNumber = i;
}
}
if (playingSound)
{
channel.stop();
channel = null;
sound = null;
}
var currentInterview:String = interviewArray[arrayNumber];
var currentLength:Number = interviewLengthArray[arrayNumber];
var interviewURL:URLRequest = new URLRequest(currentInterview);
var sound:Sound = new Sound();
sound.load(interviewURL);
channel = sound.play(resumeTime);
playingSound = true;
this.playBTN.visible = false;
this.pauseBTN.visible = true;
playBTN.removeEventListener(MouseEvent.CLICK, playInterview);
pauseBTN.addEventListener(MouseEvent.CLICK, pauseInterview);
}
//Seekbar timer
this.seekBar_mc.greenScrubber_mc.width = 0;
this.seekBar_mc.playHead_mc.buttonMode = true;
var seekbarTimer:Timer = new Timer (100);
seekbarTimer.addEventListener(TimerEvent.TIMER, updateSeekbar);
function updateSeekbar(event:TimerEvent):void {
this.seekBar_mc.greenScrubber_mc.width = sound.bytesLoaded / sound.bytesTotal * this.seekBar_mc.greyScrubber_mc.width;
if (playingSound && !dragging) {
this.seekBar_mc.playHead_mc.x = channel.position / currentLength * this.seekBar_mc.greyScrubber_mc.width;
} else if (!playingSound && !dragging) {
this.seekBar_mc.playHead_mc.x = resumeTime / currentLength * this.seekBar_mc.greyScrubber_mc.width;
}
}
//Play Stop Pause
playBTN.addEventListener(MouseEvent.CLICK, playInterview);
function playInterview(event:MouseEvent):void {
trace("WHY??????");
if (!playingSound) {
channel = sound.play(resumeTime);
//seekbarTimer.start();
playingSound = true;
this.playBTN.visible = false;
this.pauseBTN.visible = true;
playBTN.removeEventListener(MouseEvent.CLICK, playInterview);
pauseBTN.addEventListener(MouseEvent.CLICK, pauseInterview);
}
}
pauseBTN.addEventListener(MouseEvent.CLICK, pauseInterview);
function pauseInterview(event:MouseEvent):void {
if (playingSound) {
resumeTime = channel.position;
channel.stop();
playingSound = false;
this.playBTN.visible = true;
this.pauseBTN.visible = false;
playBTN.addEventListener(MouseEvent.CLICK, playInterview);
pauseBTN.removeEventListener(MouseEvent.CLICK, pauseInterview);
trace(resumeTime);
}
}
stopBTN.addEventListener(MouseEvent.CLICK, stopInterview);
function stopInterview(event:MouseEvent):void {
if (playingSound) {
channel.stop();
playingSound = false;
this.pauseBTN.visible = false;
this.playBTN.visible = true;
playBTN.addEventListener(MouseEvent.CLICK, playInterview);
pauseBTN.removeEventListener(MouseEvent.CLICK, pauseInterview);
}
resumeTime = 0;
}
Edited: 09/14/2008 at 06:51:48 PM by ebinion
View Replies !
View Related
[F8] Play/Pause MediaPlayback
OK. I have a MediaPlayback file off the scene (out of site for user) that plays a song automatically. On frame 1 I have a button to pause the sounds:
on(release){
this.soundtrack.pause(this.soundtrack)
gotoAndStop(2);
}
Frame 2 has a button to start the music again:
on(release){
this.soundtrack.play(this.soundtrack)
gotoAndStop(1);
}
However, it doesn't play from where the song was paused. It skips to the end of the song...
Is there a way to make it play from the same point at which is was paused?
many thanks
View Replies !
View Related
MediaPlayback Component
I'm using the mediaplayback component to play a FLV file and can't seem to get it to work within the SWF I'm working on???....I've made a test SWF and can get the FLV to play but then in my final SWF....no good....seems as though the FLV isn't associated with the mediaplayback component....I have the FLV in the same directory as my SWF as in the test....and all I see is a wht box with the word "player" in it when I test the SWF....I have the mediaplayback component in a MC which is within another MC that slides into view....ANY SUGGESTIONS????
MANY THANKS!!!!!!!!!!!!!
View Replies !
View Related
MediaPlayback Component
Hey,
I'm using Flash MX 2004 Professional. I am trying to change the appearance of the mediaplayback component. I read that you have to change the component in the component.fla file. I did this but when I try to launch the component inspector I get the following message :
"There was an error opening the custom UI for this component"
Does anyone know what could be causing this?
Thanks,
L
View Replies !
View Related
MediaPlayBack - Component
hello,
when the movie is loaded it starts play.
what i want is that it starts only when i push the play button.
I need to change something, but i dont know where.
can you help me please.
thanks in advance.
View Replies !
View Related
MediaPlayback Component
Hi
I am using MediaPlayback component to play audio and video files, these files are listed in a DataGrid.
I want the MediaPlayback to play next song automatically when one is complete, How can i do this ?
Thanks
View Replies !
View Related
MediaPlayBack Component
Good morning, I would like to know it anyone know how to modify the "MediaPlayback" component, I dont know how to personnalize it...
I have been looking on others website and could not find anything... Is it possible to change the skin? if yes HOW!!.. Thank you very much for the help.
View Replies !
View Related
MediaPlayback Component
Hi,
I am trying to implement the MediaPlayback component. I have dragged an instance of it to the stage and named it. I have set the path to a relative .flv file on my local machine. I have set all the parameters according to the instructions.
When I run my swf, I see the player component (no video plays) with the word "Player" on it. How do I get my flv video to run?
View Replies !
View Related
MediaPlayBack Component
Good morning, I would like to know it anyone know how to modify the "MediaPlayback" component, I dont know how to personnalize it...
I have been looking on others website and could not find anything... Is it possible to change the skin? if yes HOW!!.. Thank you very much for the help.
View Replies !
View Related
XML + MediaPlayback Component Help.
ok... so I've got an idea of how I want this to work.
this isn't REAL code... its just an example explaining how I think it would work... now could someone just help me make this idea come to life?
Idea for code:
Code:
counter = component.currentTimeVariable;
totaltime = component.endTimeVariable;
if (counter == totaltime) {
then goto.nextSong;
}
basically what I want to do... is once a song completes on the media component using a listbox... and a XML file... I want it to jump to the next song after the current song is complete.
so what would I write for this to work?
REAL CODE I have so far:
Code:
// Playlist Code
var list:XML = new XML();
list.ignoreWhite = true;
list.onLoad = function() {
var mp3s:Array = this.firstChild.childNodes;
for (i=0; i<mp3s.length; i++) {
mp3Playlist.addItem(mp3s[i].attributes.desc, mp3s[i].attributes.url);
}
// play first song
thePlayer.setMedia(mp3Playlist.getItemAt(0).data);
thePlayer.play();
mp3Playlist.selectedIndex = 0;
};
// if you select a song
// change whats playing
var mp3List:Object = new Object();
mp3List.change = function() {
thePlayer.setMedia(mp3Playlist.selectedItem.data);
thePlayer.play();
};
// Add Listener to Listbox.
mp3Playlist.addEventListener("change", mp3List);
// Load XML
list.load("playlist.xml");
//List Style Sheet
mp3Playlist.setStyle("selectionColor", 0xF7F7F7);
mp3Playlist.setStyle("backgroundColor", 0xFFFFFF);
mp3Playlist.setStyle("rollOverColor", 0xF7F7F7);
mp3Playlist.setStyle("color", 0x000000);
mp3Playlist.setStyle("textRollOverColor", 0x000000);
mp3Playlist.setStyle("textSelectedColor", 0x000000);
mp3Playlist.setStyle("borderColor", 0xFFFFFF);
thanks,
Aaron
View Replies !
View Related
XML Help With The MediaPlayback Component
Hi, I've been trying to build an XML mp3 player with the MediaPlayback component and a List Component.
How would I go about making the MediaPlayback component connect with the listbox and change songs onClick of the listBox?
heres what I've got so far.
thePlayer is the instance name of the MediaPlayback component.
mp3Playlist is the instanace name of the Listbox component.
here's my code so far...
Code:
// Playlist Code
var list:XML = new XML();
list.ignoreWhite = true;
list.onLoad = function() {
var mp3s:Array = this.firstChild.childNodes;
for (i=0; i<mp3s.length; i++) {
mp3Playlist.addItem(mp3s[i].attributes.desc, mp3s[i].attributes.url);
}
thePlayer.contentPath(mp3Playlist.getItemAt(0).data);
thePlayer.play();
mp3Playlist.selectedIndex = 0;
};
var mp3List:Object = new Object();
mp3List.change = function() {
ns.play(mp3Playlist.getItemAt(mp3Playlist.selectedIndex).data);
};
mp3Playlist.addEventListener("change", mp3List);
list.load("playlist.xml");
mp3Playlist.setStyle("selectionColor", 0xF7F7F7);
mp3Playlist.setStyle("backgroundColor", 0xFFFFFF);
mp3Playlist.setStyle("rollOverColor", 0xF7F7F7);
mp3Playlist.setStyle("color", 0x000000);
mp3Playlist.setStyle("textRollOverColor", 0x000000);
mp3Playlist.setStyle("textSelectedColor", 0x000000);
mp3Playlist.setStyle("borderColor", 0xFFFFFF);
thanks,
Aaron
View Replies !
View Related
Controlling Label On Button-component
I have a Button-component with CS3-default skin and label set. When I disable the button (with AS) the labeltext becomes outgreyed. I don't want that! I disable the button because I want it unclickable. Anyone knows how to controll the labeltext in disabled mode OR have another way to make the button unclickable?
View Replies !
View Related
MediaPlayback Pause/Play Problem
I'm using the MediaPlayback component with MP3s. When I click the play/pause it seems to kill the buttons I use to select the track. Everything works as I want it to, until I click play/pause then the onRelease doesn't even trace. Any ideas?
View Replies !
View Related
MediaPlayback Component Problem
Hi,
I've created a MediaPlayback component and, using setMedia, I've got it to play an mp3. Everything works fine - volume, scrub bar, etc.
On complete, I load in the next mp3. This also works fine. However, the playback controls are now dead. The playhead remains at the end of the progress bar. Dragging the playhead back just causes the mp3 to restart no matter where I stop.
I tried using the "stop" command instead of loading the next mp3 and this did reset the playhead, however, when I try loading the next mp3 again it doesn't reset anymore.
Here's my code. Am I doing something stupid?
-----------------------------------------------------
stop();
import mx.controls.MediaPlayback;
createClassObject(MediaPlayback, "myMedia", 5);
myMedia.setMedia("1.mp3","MP3");
myMedia.play(0);
var myListener = new Object();
myListener.complete = function(eventObject) {
myMedia.setMedia("2.mp3");
myMedia.play(0);
};
myMedia.addEventListener("complete", myListener);
--------------------------------------------------------
Thanks!
Chris
View Replies !
View Related
MediaPlayback Component Not Working For Me
Hi,
I'm trying to use the MediaPlayback Component
to link a Flash .flv video file
so that it plays in a certain area of my stage.
I believe I am doing everything I'm supposed to
according to the Help doc
and the outline and controller show up
(though not the same size as I want my video to load)
but not my video.
If it's relevant,
the .flv file is located in a subdirectory
of the directory in which the .swf and .fla files are located
so the URL I have is:
movies/silicon.flv
silicon.flv is the video I''m trying to link.
Any insight on this?
Thanks so much!
View Replies !
View Related
MediaPlayback Component Autoplay
Hi,
I am using this component. When the video reaches the end the player pauses.
No Problem.
When the next video is loaded the play head remains in the paused position.
I am loading each video via a button. The component inspector is set to automatically play.
Any ideas would be great
Thanks
Code:
button1.onRelease = function ()
{
video.setMedia("http://www.ponyack.com/gorelic/video/christopher.flv", "FLV");}
View Replies !
View Related
MediaPlayBack Component Issues
I've posted this question to several lists without a response. I'm going to post them here but I also want to see any other issues people are having with this component.
The way I'm using the component is to instantiate it at runtime using createClassObject(). Once I have a handle to the object I set some properties such as stream name/path.
ISSUES:
1. After the FLV starts playing, if I hit the rewind button, the play/pause button and the rewind/forward buttons jump up about 3 pixels and stay there.
2. I'm trying to get some data (preferred height and width) out of the FLV before I start streaming it, I do this by playing it invisibly for a couple of seconds and then going back and playing it from the beginning after retrieving the data. Is there a better way to get at this information?
3. Is there a way to set a buffer time with this component?
4. If I open the player locally and switch the stream (using setMedia()) from a FLV on FCS to a local FLV, the component breaks and doesn't play anything. But going from a local FLV to an FLV on FCS works just fine.
Any feedback is much appreciated.
Thanks,
BFL
View Replies !
View Related
Waiting If MediaPlayBack Component Is Done
I have begun to use the MediaPlayBack component to load and control an external FLV file in my scene. The only problem that I have is that I need the ability to have Actionscript check if the FLV file being used is done or not. I have noticed that there is a
ActionScript Code:
media.complete
command but I haven't had any luck getting it to work right.
If I use the following code, I cannot get Flash Actionscript to wait on the current frame until the MediaPlayBack component video is finished.
ActionScript Code:
while (myVar.complete == false){ stop(); }-- or --while(myVar.playheadTime <= myVar.totalTime){stop();}
Any thoughts? Suggestions or Ideas?
View Replies !
View Related
Skinning Mediaplayback Component
i have searched a ton for this before resorting to posting the question on here
what little things i have found did not help
are there any free flv components out there that are easily skinnable?
or is there a good tutorial on skinning the mediaplayback component?
View Replies !
View Related
MediaPlayback Component Issues...
I have a problem with my mediaPlayback component. It isn't loading the external .flv file on my pc. I'm trying to test it locally before I can put it up on the web.
Right now, it will not play, the player doesn't even seem to be functioning properly. It will just display the word "player" and that's it. It won't do anything at all.
When I create a new fla and just place the mediaplayback component on the stage by itself, it'll load up the video no problem. But I can't understand why it'll load in the new swf, but not in my current one! It's placed on the stage, on a stopped frame! What's going on!?
Here's the text from the debug menu when I open up the Objects List:
Code:
Level #0: Frame=68
Shape:
Edit Text: Target="_level0.instance25" Variable= Visible=true Text = Layout By: SiLeNtCovenant"
Shape:
Shape:
Shape:
Shape:
Movie Clip: Frame=1 Target="_level0.instance26"
Shape:
Movie Clip: Frame=1 Target="_level0.instance27"
Shape:
Edit Text: Target="_level0.instance27.scroller" Variable= Visible=true Text = <TEXTFORMAT LEADING="2"><P ALIGN="LEFT"><FONT FACE="Verdana" SIZE="10" COLOR="#0
00000"><B>Back to School!</B></FONT></P></TEXTFORMAT><TEXTFORMAT LEADING="2"><P
ALIGN="LEFT"><FONT FACE="Verdana" SIZE="10" COLOR="#000000"><I>2005.08.01</I></F
ONT></P></TEXTFORMAT><TEXTFORMAT LEADING="2"><P ALIGN="LEFT"><FONT FACE="Verdana
" SIZE="10" COLOR="#000000">Pearl City High School is now officially back in ses
sion as of today.</FONT></P></TEXTFORMAT><TEXTFORMAT LEADING="2"><P ALIGN="LEFT"
><FONT FACE="Verdana" SIZE="10" COLOR="#000000"></FONT></P></TEXTFORMAT><TEXTFOR
MAT LEADING="2"><P ALIGN="LEFT"><FONT FACE="Verdana" SIZE="10" COLOR="#000000"><
B>Mom's Birthday!</B></FONT></P></TEXTFORMAT><TEXTFORMAT LEADING="2"><P ALI
GN="LEFT"><FONT FACE="Verdana" SIZE="10" COLOR="#000000"><I>2005.07.31</I></FONT
></P></TEXTFORMAT><TEXTFORMAT LEADING="2"><P ALIGN="LEFT"><FONT FACE="Verdana" S
IZE="10" COLOR="#000000">Today is Mom's birthday and sadly, it didn't
go as well as it should have...</FONT></P></TEXTFORMAT>"
Movie Clip: Frame=1 Target="_level0.instance27.instance28"
Movie Clip: Frame=1 Target="_level0.instance27.instance28.boundingBox_mc"
Shape:
Shape:
Shape:
Movie Clip: Frame=1 Target="_level0.mediaPlayer"
Movie Clip: Frame=1 Target="_level0.mediaPlayer._chrome"
Movie Clip: Frame=1 Target="_level0.mediaPlayer._chrome._chromeEdge"
Shape:
Movie Clip: Frame=1 Target="_level0.mediaPlayer._chrome._chromeFill"
Shape:
Movie Clip: Frame=1 Target="_level0.mediaPlayer._chrome._chromeHilite"
Shape:
Movie Clip: Frame=1 Target="_level0.mediaPlayer._chrome._toggleNE" Label="small"
Movie Clip: Frame=1 Target="_level0.mediaPlayer._chrome._toggleNE._maximize" Label="_up"
Shape:
Shape:
Movie Clip: Frame=1 Target="_level0.mediaPlayer._deadPreview"
Shape:
Shape:
Edit Text: Target="_level0.mediaPlayer._deadPreview.instance29" Variable= Visible=true Text = Player
"
Button: Target="_level0.instance30"
Shape:
Button: Target="_level0.instance31"
Shape:
Button: Target="_level0.instance32"
Shape:
Button: Target="_level0.instance33"
Shape:
Note the _deadPreview after mediaPlayer? What does this mean? How do I stop this?
View Replies !
View Related
MediaPlayback Component And Preloader?
I can get both working seperately, but not together. I'm using the MediaPlayback component in Flash MX 2004 with a percentage preloader (actionscript below).
onClipEvent (enterFrame) {
var bytes = _root.getBytesTotal();
var bytes_loaded = _root.getBytesLoaded();
var percentageLoaded = bytes_loaded/bytes;
var myText = Math.round(percentageLoaded*100);
if (bytes_loaded == bytes) {
_root.gotoAndPlay(2);
this.kirupatxt = "movie loaded";
} else {
_root.gotoAndStop(1);
this.kirupatxt = "loading (" + myText + "%)";
}
}
How do I get the preloader to work with Flash Video (.flv)?
Thanks
View Replies !
View Related
Waiting If MediaPlayBack Component Is Done
I have begun to use the MediaPlayBack component to load and control an external FLV file in my scene. The only problem that I have is that I need the ability to have Actionscript check if the FLV file being used is done or not. I have noticed that there is a
ActionScript Code:
media.complete
command but I haven't had any luck getting it to work right.
If I use the following code, I cannot get Flash Actionscript to wait on the current frame until the MediaPlayBack component video is finished.
ActionScript Code:
while (myVar.complete == false){ stop(); }-- or --while(myVar.playheadTime <= myVar.totalTime){stop();}
Any thoughts? Suggestions or Ideas?
View Replies !
View Related
Skinning Mediaplayback Component
i have searched a ton for this before resorting to posting the question on here
what little things i have found did not help
are there any free flv components out there that are easily skinnable?
or is there a good tutorial on skinning the mediaplayback component?
View Replies !
View Related
Using Mediaplayback Component In Submovie
Hi, I've got a media playback component in an external swf which im loading into my main movie using loadmovie. When it gets to the playback though it freezes the movie and comes up with an error "A script in the movie caused an error click yes to terminate the script" and it won't get past that.
I'm really stuck for ideas and it's holding up my entire project, thanks for your help.
View Replies !
View Related
MediaPlayback Component And Preloader?
I can get both working seperately, but not together. I'm using the MediaPlayback component in Flash MX 2004 with a percentage preloader (actionscript below).
onClipEvent (enterFrame) {
var bytes = _root.getBytesTotal();
var bytes_loaded = _root.getBytesLoaded();
var percentageLoaded = bytes_loaded/bytes;
var myText = Math.round(percentageLoaded*100);
if (bytes_loaded == bytes) {
_root.gotoAndPlay(2);
this.kirupatxt = "movie loaded";
} else {
_root.gotoAndStop(1);
this.kirupatxt = "loading (" + myText + "%)";
}
}
How do I get the preloader to work with Flash Video (.flv)?
Thanks
View Replies !
View Related
Scripting MediaPlayback Component
How can you control the MediaPlayback component through actionscript, I want to set the contentPath then have the video play.
I thought something like this would work:
mediaPlaybackInstance.contentPath="movie.flv";
mediaPlaybackInstance.play();
View Replies !
View Related
MediaPlayback Component Question
is it possible to use the mediaplayback component as a full blown winamp style mp3 player ? i can get it to play one tune. but, i want to have a playlist and also have the id3 tag info incorporated into it. any help is appreciated. thanks in advance !!
View Replies !
View Related
Sizing The MediaPlayBack-component...
i'm streaming some .flv's and they are recorded i 4:3 format, so thay have these dimensions:
width: 456
lenght: 342
my question is:
if i want this film to be showed in exactly this format, which size will i have to use for the mediaplayback-component?
1) i want the controler to be shown in the bottom,
2) i'm using the
_root.instancename.setSize(xxx ,xxx);
to determine the size of the component,
3)and i don't want the component to be shown (very much) at the right and left of the flv...
hope you understand what i mean
thankx in advance
felisan
View Replies !
View Related
MediaPlayback Component Issues...
I have a problem with my mediaPlayback component. It isn't loading the external .flv file on my pc. I'm trying to test it locally before I can put it up on the web.
Right now, it will not play, the player doesn't even seem to be functioning properly. It will just display the word "player" and that's it. It won't do anything at all.
When I create a new fla and just place the mediaplayback component on the stage by itself, it'll load up the video no problem. But I can't understand why it'll load in the new swf, but not in my current one! It's placed on the stage, on a stopped frame! What's going on!?
View Replies !
View Related
Play/Stop Integrated Button For Controlling Movie...
Hi there,
I have a movie that I wish to control with a single button. Initially the button graphic is a "play triangle" (like on a stereo), which sits in the corner happily as the movie plays.
What I want it to do is when the user clicks on the button, the movie stops, and the button changes to a "pause button". Then when the user clicks on that button, the movie starts up again, and the button changes back to the "play triangle".
I am still new to Flash, so please be gentle.
Thanks,
Tatlar
View Replies !
View Related
Controlling Check Box From Radio Button Component
I have a radio button that when clicked, needs to set a checkbox to true.
Here is my code:
radiofax.setChangeHandler("myRadio");
function myRadio(component) {
if (_root.generate.radiofax.getLabel() == "Fax") {
_root.generate.fax.setValue(true);
}
}
radiofax is the radio button component and faxcheck is the fax checkbox.
Generate is my movie clip that the components resides in.
View Replies !
View Related
MediaPlayback Component Compatible With Win98?
I made a CD with videos that i am going to burn for my whole school
Anyways, today i was showing a few teachers the program (its a published exe file that runs fullscreen) and i was suprised when one computer didnt play the videos.
I had one imbedded video which played fine, but the mediaPlayback components didnt work. (The component just stayed white, play wouldnt do anything, you try to drag the slider and time turns to NN:NN:NN:NN)
Anyways the same cd worked on everyone else's computers. They all have the same network software, but is this mediaPlayback thing because of Winodws 98 or just a specific setting on the schools computers... i dont know any non-school win 98 computers to test it on.
View Replies !
View Related
Dynamic Playlist Using MediaPlayBack Component
I need to know if there is any way to make a dynamic database-driven playlist for an mp3 streamer.
I have Studio MX 2004 with Flash Professional, so I already am familiar with the built-in MediaPlayBack component...but does anyone know the code of how it would be done to control the .contentPath property to link to a database and call new tracks based on administrator input/setup? Other methods/suggestions for accomplishing the same thing are welcome.
Thanks in advance.
-Brian-
View Replies !
View Related
MediaPlayback Component.. Background Colour
Anyone know a way to change th background colour of the MediaPlayback component, I cant find information on it anywhere which makes sense. Its not in the sample theme like the other components and im not using that horrible halo thing.
Any ideas, some cunning actionscript out there to do it?
Thanks
View Replies !
View Related
Actionscript To Customize MediaPlayback Component
I've used this to get rid of the gradient background...didn't work:
myMedia.backgroundStyle = "none";
I've also tried this and didn't work:
mymediainst._chrome._toggleNE.unloadMovie();
What can I do to just alter the MediaPlayback background to just a solid black? Would I put it into the frame or the actual component?
View Replies !
View Related
Xml Tree Component & MediaPlayBack Comp
hello .
i have started a simple media component . so here it is ..
this i have on the Stage a
//
mediaPlayback component
tree component
//
i am using this code
Code:
//my Tree setstyle
tree_comp.setStyle("themeColor", "haloOrange");
//load the XML source
tree_compDataProvider = new XML();
tree_compDataProvider.ignoreWhite = true;
tree_compDataProvider.load("tree_source.xml");
tree_compDataProvider.onLoad = function(success) {
if (success) {
tree_comp.dataProvider = tree_compDataProvider;
} else {
trace("unable to load/parse tree_source.xml");
}
};
// add the event listeners
tree_comp.addEventListener("nodeOpen", myTreeListener);
tree_comp.addEventListener("nodeClose", myTreeListener);
tree_comp.addEventListener("change", myTreeListener);
var treeListener:Object = new Object();
myTreeListener.change = function(evt:Object) {
mp3MediaPlayer.contentPath = evt.target.selectedNode.attributes.data;
mp3MediaPlayer.play(this.selectedNode);
};
tree_comp.addEventListener("change", myTreeListener);
and here i cannot get the mp3 to play when selected from the tree component
any help ---?
Code:
//XML sample code ...
<?xml version="1.0" encoding="iso-8859-1"?>
<node label="Quick navigation to Artists" value="1">
<node label="Jonas">
<node label="funky.mp3" data="http://www.mySite.com/funky.mp3" />
thanks for any input on this 1 . im stuck at the moment .
cheers T
View Replies !
View Related
MediaPlayBack Component Repeats At Start
I have Googled far and wide and cant find an answer for this simple problem...Why does the Flash mediaPlayBack component repeat the first fraction of a second when it starts to play an MP3? I have tried adjusting everything available with its properties but nothing works. And it only does it the very 1st time for each MP3, right after using the setMedia(link) fxn.
Even shutting off the autoplay, and giving it a stop command will just prolong the bug, because as soon as I give it a delayed command to play...the glitch happens. I can t find anyway around it.
Anyone?
View Replies !
View Related
Mediaplayback Component Stops Streaming
Hi!
I have a mediaplayback component on my stage that loads some flv's and mp3's from an xml doc. It seems to work fine.
link: http://bomusik.dk/homepage/index.php?mod=/mediaplayer/
If I drag the playhead button to the end of the streaming indicator before the stream has finished loading then the stream stops completely. And on top of that I cant get it to stream again before I clear my cache. Its a problem in both IE and firefox. Though it seems to be harder to make it stop in IE.
View Replies !
View Related
MediaPlayBack Component Audio Speed
If, i've following the basic instructions for using the mediaPlayBack component:
drag to stage, set to MP3, target a *.mp3 and publish.
fla, swf and mp3 are all i the same folder.
Works fine expect teh mp3 is being played back liek a chipmonk - doubel / maybe treble speed etc.
why? i can't find a setting to control this?
help, Rich
Ps. Win XP Pro SP1, Flash Pro 8
View Replies !
View Related
MediaPlayback Component Intermittent Stuttering
I'm creating a very simple .mp3 player in Flash 8. When the user selects one of four audio files, I set the contentPath of the component instance to the .mp3's filepath. There's also a button that plays/pauses the .mp3 using the myInstance.play() and myInstance.pause() commands. For the most part, it works fine.
However, sometimes when the user pauses the .mp3, then selects a different .mp3, the audio begins to stutter repeatedly; it plays a very short (less than one second) snippet of the audio, then keeps repeating this snippet.
Anyone ever encountered this? Thanks!
View Replies !
View Related
Can I Use MediaPlayback Component And Set A Buffer Time?
I am using the mediaPlayback component to play external .flv files. First problem I had was that they were stopping intermittently when loaded to the server.. so I read up on the netStream class and attached this basic code...
var netConn:NetConnection = new NetConnection();
netConn.connect(null);
var netStream:NetStream = new NetStream(netConn);
//my_video is the name of the component instance on the stage
my_video.attachVideo(netStream);
netStream.setBufferTime(20);
netStream.play("introDemo.flv");
Now.. the audio plays but no video plays and the controls on the component do not work now... ie.. can't pause it. or adjust the volume.
__________________
View Replies !
View Related
[mx2004] Non-terminating MP3 Dl's With MediaPlayback Component
Hi
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.
I've basically given up on using the component to deliver MP3s, so any advice at all will be appreciated.
Thanks
View Replies !
View Related
|