[comp.windows.interviews] FillRect vs Stencil

hight@ERG.SRI.COM (John Hight) (06/04/91)

(Speaking in 2.6:)

My first attempt at Translating a series of FillRects to simulate
packets moving through a queue resulted in a rather disappointing
performance on my Sparc 2.  I've got to speed things up quite a bit,
and I'm wondering whether a series of Stencils (Bitmaps?) would be any
faster.  (Actually, my guess is it's not the Translating, but the
Updating done by my damage object which takes up so much time).  Does
anybody have an idea as to whether a Stencil can be redrawn faster
than a FillRect?

Thanks,
John Hight
SRI International

pwb@mrj.com (Peter W. Brewer) (06/04/91)

>performance on my Sparc 2.  I've got to speed things up quite a bit,

Which server are you using? My application uses rubberbanding fillrects and
I noted a tremendous performance improvement using xnews instead of the 
M.I.T. xsun server. This may alleviate some of your problem. 

linton@marktwain.rad.sgi.com (Mark Linton) (06/04/91)

In article <9106031709.AA01172@gorilla.erg.sri.com>, hight@ERG.SRI.COM (John Hight) writes:
|> 
|> (Speaking in 2.6:)
|> 
|> Does
|> anybody have an idea as to whether a Stencil can be redrawn faster
|> than a FillRect?

For equivalent sizes, it is hard to believe a stencil would be faster.  You might try running
xscope and seeing what operations are being sent to the X server in your inner loop.