Most efficient method of generating PNG as HTTP response

Posted by awj on Stack Overflow See other posts from Stack Overflow or by awj
Published on 2010-06-16T10:15:06Z Indexed on 2010/06/16 10:22 UTC
Read the original article Hit count: 157

Filed under:
|
|

I've built an ASP.NET page whose output stream is a dynamically-generated PNG image containing only text on a transparent background.

The text is based upon database IDs contained in the querystring. There will be a limited number of variations.

Which one of the following would be the most efficient means of returning the image to the client?

  1. Store each variation upon the first generation, and thenceforth retrieve this from the drive.
  2. Simply generate the image each time.
  3. Cache the output response based upon the querystring.

© Stack Overflow or respective owner

Related posts about http

Related posts about cache