System.Drawing and Animation? RRS feed

  • Question

  • User299798288 posted


     I have used system.drawing to produce a couple of cool images, one is a dashboard-type dial, and one is a Sierpinski space-filling curve.  These are coded up in the Page_Load method on the code-behind page of their respective web pages.  I plan to have a couple of Divs, in which it will say <asp:img source="the page with the system.drawing on back of it.aspx"

    So far so good, but I would ike to introduce an aspect of animation so that the needle on the dashboard dial can move around, and so that the user can see the Sierpinski curve being drawn (not just the finished product, sitting there, passive, like a picture).

    All I have thought of so far is to put an Ajax update-panel in, and call

    canvas.Save(Response.OutputStream, System.Drawing.Imaging.ImageFormat.Jpeg);

    at regular intervals.

     What is the best way to proceed? 

    Many thanks,


    Tuesday, April 14, 2009 5:24 AM

All replies

  • User299798288 posted

    Well, I could not get this to work.  But I came to the conclusion that it was a wrong concept architecturally, and that I was 'thinking desktop.' 

     What I mean by this is that my 'solution' involved a tight loop on the server, drawing recursive space-filling curves, and flushing the buffer to the client at regular intervals.  For some reason this did not work.

    Probably I should find a client-side drawing package.

    Thanks for all the responses.


    Friday, April 24, 2009 8:39 PM