SWiSH Forum
Forum użytkowników programów SWiSH

SWiSH Max - Jak zrobić buforowanie VIDEO?

UndefinedMan - Sob 04 Kwi, 2009 14:36
Temat postu: Jak zrobić buforowanie VIDEO?
Witam, mam zdefiniowany odtwarzacz Video za pomocą kodu

Kod:
onSelfEvent (load) {
loadfunc = function(what){
    createEmptyMovieClip("watcher",1000);
    container.loadMovie(what);
        watcher.onEnterFrame = function(){
        if(_parent.container._width > 10){
//--the following makes the playersize for the movie-------           
            _parent.containerbox._width = _parent.container._width+17;
            _parent.containerbox._height = _parent.container._height+40;
            _parent.stopButton._y = _parent.container._height+18;
            _parent.stepBack._y = _parent.container._height+18;
            _parent.playButton._y = _parent.container._height+18;
            _parent.stepForward._y = _parent.container._height+18;
            _parent.sliderControls._y = _parent.container._height+25;
            delete watcher.onEnterFrame;
        }
    }
};
stepForward.onRollover = function(){
    this.gotoAndStop(2);
};
stepForward.onRollout = function(){
    this.gotoAndStop(1);
};
stepForward.onPress = function(){
    this.gotoAndStop(3);
    container.stop();
//    container._visible = false;//delete this line if you want visibleplayback
    this.onEnterFrame = function(){
    _parent.container.skipFrameAndStop(10);//or use nextFrameAndStop(); for 1 Frame
    }
};
stepForward.onRelease = function(){
//    container._visible = true;//delete this line if you want visibleplayback
    container.play();
    delete this.onEnterFrame;
};
stepForward.onReleaseOutside = function(){
//    container._visible = true;//delete this line if you want visibleplayback
    container.play();
    delete this.onEnterFrame;
};
stepBack.onRollover = function(){
    this.gotoAndStop(2);
};
stepBack.onRollout = function(){
    this.gotoAndStop(1);
};
stepBack.onPress = function(){
    this.gotoAndStop(3);
    container.stop();
    container._visible = false;//delete this line if you want visibleplayback
    this.onEnterFrame = function(){
    _parent.container.skipFrameAndStop(-5);//or prevFrameAndStop();
    }
};
stepBack.onRelease = function(){
    container._visible = true;//delete this line if you want visibleplayback
    container.play();
    delete this.onEnterFrame;
};
stepBack.onReleaseOutside = function(){
    container._visible = true;//delete this line if you want visibleplayback
    container.play();
    delete this.onEnterFrame;
};


//-------


}


Film skonwertowany do SWF odpala button.
Odtwarzacz bardzo dobrze chodzi, jednak chciałbym aby podczas zatrzymania filmu wyświetliła sie informacja, że jest buforowanie. Teraz jest tak, że się zatrzymuje film, zbuforuje SWF i dalej leci, ale między czasie nie ma informacji że buforuje.

Prosiłbym o pomoc.


Powered by phpBB modified by Przemo © 2003 phpBB Group