Server Side Graphics Generation
-
There are needs to generate
graphics which depend on the user's input.
-
Examples: access counter, statistics,
charts, direction to locations.
-
Sometimes it is impossible to
generate, ahead of the request time, all the gif or jpeg files for the
potential graphic images. There are too many and requiring too large
a storage space.
-
One solution is to generate
the requested graphics on-line at the server side.
-
With the Java applet and its
AWT library, it is also possible to generate the requested graphics on-line
at the client side.
-
It is a very interesting problem
to decide which solution is better.
-
It depends on
-
how large the graphics file
to be generated.
-
how long it takes for the server
to generate.
-
how long it takes for the client
to generate.
-
how large is the applet.
-
how fast is the connection.
-
how often the user requests
similar graphic results and assume that the same applet can be reused to
generate graphics.
-
are there additional data need
to be downloaded for the applet?
-
We will revisit this problem
when we finish the introduction of the applet programming.
-
For server-side graphics generation,
we introduce two examples:
-
Use GD.pm to
generate access counter gif images.
-
Use Gnuplot
and ppm2gif to generate a line chart.