Back to JS main page

BY:Martin Holecko...BASTaRT PIX
DATE:1996-12-09


jsImagePlayer 1.0

COMMENTS:

jsImagePlayer 1.0

by Martin Holecko
September 1996, PRAHA, Czech Republic




Hi there!
I'd like to introduce you the jsImagePlayer. I named it ImagePlayer because it deals with numbered images not real movies. The "js" stands for javascript. It has been written to provide a movie player capable of displaying and controlling the movie right from the web page. Several plugins have been developed for this purpose but none of them (until now) supports more than two different computer platforms.

As the javascript is a regular part of Netscape (and perhaps also Explorer from that wosaname company) and therefore platform independence is achieved easily.

Here's an example of the player in action...

(Don't hesitate and try to press some of the little thingies below the picture. BUT wait a little if there is still some downloading activity).


But HOW does it actualy work?
The script first preloads number of images into netscape cache. The images are supposed to be named in the format: "imagename#.ext", where:

Some time after the preloading begins, an image saying "please wait, loading movie" is displayed to inform the unpatient user. The image is supposed to be placed in the same directory as the page and is scaled automaticaly. The message is replaced by the first frame when the whole sequence is downloaded.

Now you can play the movie (once, loop it or swing it), change its speed, play it reverse, play it frame by frame or jump to the frame you want by typing the number to the input field that shows the current frame number (see the known bug below). Works well both with GIFs and JPEGs. The user interface is kinda shitty, I know, but that was not the point of the whole thing. A pretty one, with nice controls and everything, should follow soon. But then I can call it version 1.5, right? :)

The whole script is on the beginning of the page so just grab it if you like it. I commented it quite a lot so it should be easy to alter. Do anything you want with it and drop me a note if you feel like it.


Enjoy! Martin.




KNOWN BUG:
when the page is located on a WWW Server that cannot handle the POST form submit method, pressing Enter after changing the frame number in the little input field causes the page to reload and an alert window to appear. This can be avoided by clicking with the mouse somewhere outside the input field rather than hitting the Enter to jump to the desired frame. If you are not sure what's your www server like, try it! (most should be alright)



(c)1996 by BASTaRT PIX
Remember to save the pictures
If you want this script just choose "Save Frame As..." (in Netscape) when you have the focus on the frame.

URL: http://www.oocities.org/SiliconValley/7116/jv_movie.html