Newsgroups: comp.sys.next Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!snorkelwacker.mit.edu!stanford.edu!leland.Stanford.EDU!news From: duggie@pengyou (Doug Felt) Subject: Re: How do you draw lines into the current view for Rubberbanding Message-ID: <1991May20.161151.22767@leland.Stanford.EDU> Sender: news@leland.Stanford.EDU (Mr News) Organization: AIR, Stanford University References: <507@heaven.woodside.ca.us> Date: Mon, 20 May 91 16:11:51 GMT Lines: 36 In article <507@heaven.woodside.ca.us> glenn@heaven.woodside.ca.us (Glenn Reid) writes: > Peter King writes > > > Check out instance drawing. Here's a little snippet of code that does > > temporary line drawing in response to a mouse-down method. > > [ code omitted ] > > > This causes a little bit of flicker (acceptable when rubber-banding). If you > > want to avoid the flicker, then you'd need to do double-buffering with > > off-screen windows and compositing. I'll leave this as an exercise for the > > reader. > > I'm curious; why isn't instance drawing implemented to avoid flickering in > the manner you suggest? It seems that this would be a better > implementation, and just as easy, unless I'm missing something. > > -- > Glenn Reid RightBrain Software > glenn@heaven.woodside.ca.us NeXT/PostScript developers > ..{adobe,next}!heaven!glenn 415-326-2974 (NeXTfax 326-2977) I'm curious too, but the answer is probably buried in the depths of history. One day at an 'informal developer camp' back the summer before the NeXT was announced I remember talking to someone from Adobe about this, and he said that was how the specs were defined, and implied that the people from NeXT had something to do with it. I never followed up. In my opinion flicker is never acceptable, not even for rubberbanding, if you want a professional-looking product. Offscreen buffering is the way to go, although unfortunately this is high overhead when you are selecting large areas of the screen. Doug Felt