comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Help! Slow object graphics.
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Help! Slow object graphics. [message #29461 is a reply to message #29460] Tue, 19 February 2002 17:13 Go to previous message
Rick Towler is currently offline  Rick Towler
Messages: 821
Registered: August 1998
Senior Member
I would first try using the idl profiler procedure (see help). You'll need
to figure out where your program is wasting its time. I wish I could tell
you more. Although I have run into the "man my program is slow" problem
before, I don't have any quick fix answers for you.

Once you narrow your problem down post your findings.

-Rick


"tedcary" <tedcary@yahoo.com> wrote in message
news:3C72DFDE.E3E10AA@yahoo.com...
> Partly as a learning exercise, and partly based on advice from the
> newsgroup, I went ahead and wrote a 2D object graphics program based on
> XROI. The graphics tree branches out from the XROI graphics tree, which
> is to say the graphics hierarchy in my program shares its basic
> structure with XROI. The drawing functions are essentially borrowed
> from XROI as well.
>
> The problem is that drawing in my program is ridiculously slow, much
> slower than in XROI. During freehand drawing the pixels activated on
> screen lag noticeably behind the cursor position. Simple animations
> where I erase and redraw sequences of filled ~20-vertex polygons are
> also very slow, and take three times as long as in an earlier direct
> graphics version of the same program.
>
> The big difference is that my program is written as an object widget,
> since I envisioned subclassing it into several specialized ROI analysis
> programs. So everything might be buried a little deeper in the heap
> (pointers to pointers), although I notice that the info structure of
> XROI is in a pointer as well... Anyway, can this really account for
> the marked reduction in speed? If not, then I can't figure it out,
> since as far as I can tell my program is using almost exactly the same
> draw functions and graphics hierarchy as the faster XROI. There are no
> PRINT or HELP statements slowing things down by writing to the output
> log. The computer I'm using is not great, but is fairly new--733MHz Mac
> G4, 32Mb NVidia GeForce 2Mx, 256Mb + 895Mb(Virtual) RAM.
>
> I convinced my employer that converting my DG program to OG was worth
> the week it's taken, but I'm not sure he'll be so pleased to see that
> everything is slower than it was before... I thought object graphics
> weren't supposed to be so slow these days, so it must be the way I'm
> programming, although I really just copied XROI for the drawing part of
> the program. I hope it's not the heap thing, because I depend on the
> object widget functionality... Any ideas? Thanks.
>
>
>
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: Endian-ness
Next Topic: Need Some Good Ideas

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:03:26 PDT 2025

Total time taken to generate the page: 0.00440 seconds