Skip to content

mariusGundersen/PIGS

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PIGS - Progress Indicator via Gif Socket

This is based on the gifsocket made by Alvaro Videla: https://github.com/videlalvaro/gifsockets.

How does it work

Go to doHeavyWork.php, and you will see a progressing animated gif. The gif generated by the java class Pigs, which uses a delayed loop to add frames to the gif and push them to the client.

The java class could do something else, like uploading a file or transcoding a video, and report the progress to the client via the gifs.

How to install

Everything is ready to run, but you might have to build the java classes and set the permission on the pigs.bat and pigs.sh script.

To compile the java run this code:

$ javac.exe -classpath java/commons-io-2.4.jar -d classes/ java/*.java

You can test the java file by running the following code and opening the generated image in the browser.

$ cd classes
$ java Pigs noDelay > ../output.gif

Why PHP/Java?

This is a program that uses gifsockets and you want to know why I used PHP and Java?

Source

Some of the Java code is from http://www.fmsware.com/stuff/gif.html

About

Progress Indicator via Gif Sockets

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages