home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / mac / programm / 13265 < prev    next >
Encoding:
Text File  |  1992-07-31  |  2.4 KB  |  48 lines

  1. Newsgroups: comp.sys.mac.programmer
  2. Path: sparky!uunet!cs.utexas.edu!zaphod.mps.ohio-state.edu!wupost!gumby!destroyer!sol.ctr.columbia.edu!The-Star.honeywell.com!umn.edu!epx.cis.umn.edu!mhall
  3. From: mhall@epx.cis.umn.edu ()
  4. Subject: Color and multifinder questions
  5. Message-ID: <1992Jul31.165703.10786@news2.cis.umn.edu>
  6. Sender: news@news2.cis.umn.edu (Usenet News Administration)
  7. Nntp-Posting-Host: epx.cis.umn.edu
  8. Organization: University of Minnesota
  9. References: <1992Jul29.154809.16204@gvl.unisys.com> <1992Jul30.020613.17378@newstand.syr.edu> <1992Jul31.151212.4777@gvl.unisys.com>
  10. Date: Fri, 31 Jul 1992 16:57:03 GMT
  11. Lines: 35
  12.  
  13.  
  14. Hello-
  15. I am writing a mathematics application that I want to be multifinder compatible
  16. and color quickdraw compatible.  A few questions to that end.
  17.  
  18. One-  The app contains a full color plot, where every point in the window is
  19. assigned a color (a bifurcation plot, actually)  The overhead for calling
  20. Moveto(h,v);
  21. PMForeColor(i);
  22. Lineto(h,v);
  23. is pretty much unacceptable.  Is it legal to draw directly into an offscreen
  24. CGrafPort by just shoving index values into the Pixmap?  If it is, what's the
  25. safest way to do it?  I have done it before, in a program for My Machine Only,
  26. and I had to create a table to match the Palette manager's index to the logical
  27. index for the pixmap.  Is that a Very Bad Thing?  I have read about the 
  28. tolerant+explicit usage, but that seems to be for 32 bit QD only, and I don't
  29. want to require that.  The basic idea is to create a 256 color image that I
  30. can blit to any depth (4 bit to 32 bit) screen.
  31.  
  32. Also- when do I handle changes in the color environment.  I have been handling
  33. them as soon as I recieve an update event, by just redrawing everything.  
  34. However, while in the control panel switching colors, The machine occasionally
  35. crashes (in the systemclick routine)  I am running from inside TP4.0.  I can't
  36. seem to find anything wrong with my redrawing, but then again, I haven't found
  37. any source that tells me how to handle these changes.
  38.  
  39. And #3, if you are still with me,  What's the best way to handle Multifinder
  40. during lengthy calculations?  I read previously that WNEvent/GNEvent take up
  41. a lot of time.  If I use EventAvail, will background tasks get time?  If
  42. I am in the background, Will I get time if all I am using is EventAvail? (oh,
  43. If EventAvail returns true, I call WN/GNEvent).  And how often should I call
  44. it from either back or front. Once a tick, or much more?
  45.  
  46. Thank you,
  47. matt hall
  48.