Comunidad de diseño web y desarrollo en internet online

Ayuda con un video FLV

Citar            
MensajeEscrito el 15 Mar 2009 12:28 am
Hola realice una pelicula en la cual hay varios botones del menu, unos de ellos es VIDEOS, al precionarlo me trae ( lo importe) un video FLV en la cual arranca, y les hice unos botones, play,pausa,stop para que el navegador pueda interactuar, mi pregunta es la siguiente, cuando presiono otro boton para ir al frame determinado por ej: fotos , el sonido sigue funcionando no me lo corta... cual podria ser el problema???? les dejo el AS:

Código ActionScript :

video_tmp="invitado.flv"
var conexion:NetConnection = new NetConnection();
conexion.connect(null);
var stream:NetStream = new NetStream(conexion);
mi_video.attachVideo(stream);
stream.play(video_tmp);
//aseguramos 10 seg de reproduccion
stream.setBufferTime(10);
//
barra._xscale = 0;
onEnterFrame = function () {
bu_cargado.text = stream.bufferLength;
bu_trans.text = stream.time;
bu_total.text = Math.round(stream.bytesTotal/1024)/1000+" mb";
};
//botones_-----------------------------------
seg.restrict = 1-9;
btn1.onPress = function() {
stream.play(video_tmp);
};
btn1_1.onPress = function() {
stream.close();
};
btn2.onPress = function() {
stream.pause();
//obvio, para hacer pausa, ojo q es lo mismo para avanzar
};
btn3.onPress = function() {
stream.seek(0);
// va al inicio (cero segundos)
};
btn4.onPress = function() {
stream.seek(seg.text);
// va al segundo q nosotros escribamos
};
//status
stream.onStatus = function(infoObject:Object) {
if (infoObject.code == "NetStream.Play.Stop") {
trace("acabo");
}
if (infoObject.code == "NetStream.Play.StreamNotFound") {
trace("encontro error");
}
};

Por arieljbon

56 de clabLevel



 

argentina

msie7
Citar            
MensajeEscrito el 15 Mar 2009 12:56 am
Pero cuando pasas a otra opcion del menu antes debes detener el video, o sea ejecutar la accion del boton stop, eso estas haciendo en el menu tambien??

Por drarock

Claber

705 de clabLevel

3 tutoriales

Genero:Femenino  

Lima, Peru

firefox
Citar            
MensajeEscrito el 15 Mar 2009 03:15 pm
Drarock!!! Gracias!!!, definitivamente me faltaba eso!, en los botones le agregue stream.close(); y funciono perfectamente!! :D .
Saludos!!

Por arieljbon

56 de clabLevel



 

argentina

msie7

 

Cristalab BabyBlue v4 + V4 © 2011 Cristalab
Powered by ClabEngines v4, HTML5, love and ponies.