Skip to content

GDI+ drawing have flicker/ slow down, need solution

sheetalw wattamwar

Asked Apr 12, 2010, 2:11 AM EDT1 answer
Share
LinkedInX
Hi, I am trying to scroll text from bottom to up by using GDI+ graphics object.
my code is

 Bitmap bmp = new Bitmap(1024, 768);
 Graphics gr = Graphics.FromImage((Image)bmp);
for (int count = 768; count >= -0; count--)
{
             gr.Clear(promptTextBackColor);
             gr.DrawString(richEditor.Text, font, new SolidBrush(ForeColor), 10, count);
} 
This gives too much jurk , then i used one following line of code

scrollForm.CreateGraphics().DrawImageUnscaled(bmp, 0, 0);
 
here scrollform is windows form on which i have to show scrolling.

now no jurk but it is very very slow, not acceptable by client.

can anyone know how to do it fast and more effective.
Please help.

1 Answer

Know the answer? Post it. Somebody with the same question will find it here.

  • 0
    no one have any answer!!!!!!!!!!!!!!
    0