drawing line slowly!!

drawing line slowly!!

Post by abhimany » Thu, 12 Jun 2003 19:18:08



hi,

i have two point and want to draw line between them so that user can see that from which point the line start and to which point it ends. that is i wnat to draw it slowly.

how can i do it.

thanks in advance

abhimanyu.

 
 
 

drawing line slowly!!

Post by Ananth B » Thu, 12 Jun 2003 21:42:32


Hi Abhimanyu,
   you could just interpolate between the end points.

currpt->x = startpt->x * (1 - lambda) + endpt->x * lambda;
currpt->y = startpt->y * (1 - lambda) + endpt->y * lambda;

increment lambda from 0.0 to 1.0 in small increments, and do a lineto currpt
from the previous point.

Regards,
Ananth B.


Quote:

> hi,

> i have two point and want to draw line between them so that user can see

[snip]

 
 
 

drawing line slowly!!

Post by Adria » Thu, 12 Jun 2003 23:23:25


Hi,

How about using a TTimer object ? (It's on the System tab)

Call the method that draws the next point in the Timer-event of this
component.
The interval is given in milliseconds.
(Remember that if you want it to stop generating Timer-events, you have to
disable it :)

This way you don't draw extra, invisible interpolated, points, which is
better for system performance.

Hope this works for you,

Adrian.



Quote:

> hi,

> i have two point and want to draw line between them so that user can see

that from which point the line start and to which point it ends. that is i
wnat to draw it slowly.
Quote:

> how can i do it.

> thanks in advance

> abhimanyu.

 
 
 

1. Corel Draw 11 drawing rendering slowly

Hey all!

I've created a drawing in Corel Draw 11 that for some reason is
rending onscreen VERY slowly. I'm not sure when it started, but I do
know that now when I redraw (such as doing a zoom or refresh) it
actually can take up to 8 seconds to redraw.

I've put the CDR file online and you can download it at:

www.csd.ca/slowdrawing.cdr

There aren't too many objects. Some objects are 50% transparent. There
is one object with a texture fill applied to it. There are two objects
with bitmap fills. The rest are simple solid fills.

I'd appreciate if someone could take a look and let me know what's
happening with this drawing.

There should be some kind of "defrag" or optimize on these drawings to
clean up any noise from multiple edits.

Thanks!

2. Graphics papers 2

3. Adding colour to scanned line drawings for CMYK printing Adding colour to scanned line drawings for CMYK printing Adding colour to scanned line drawings for CMYK printing

4. General Demo Reel Question

5. Drawing different line types at different line width

6. Infini-D 3.0 rants or raves?

7. Draw polygon face and line in one line

8. Drawing non solid line with line width greater than one

9. HELP: Line drawing routine does not draw right.

10. ati radeon 8500 (line drawing and point drawing)