[R] using graphapp.h

Peter Dalgaard BSA p.dalgaard at biostat.ku.dk
Wed Jun 28 15:54:56 CEST 2000


"Vadim Kutsyy" <vadim at kutsyy.com> writes:

> What I need to do as to plot a few tens thousands squares of different
> colors.  As David mention, it can be done with polygon(), but it still be
> slow.  So I am trying to do it from c code.
> 
> As a result, I open the window with plot(), and then I want to plot in to
> that window from c code (in S it is done using "graphics.h").  The only
> thing I could think about, is to use "graphapp.h".  "graphapp.h" defines a
> lot of function for that (fillrect(rect r) for example), but I can not
> figure out how to make it grow in that window, which is already open by
> plot().

If you want to mess at the C level, I think you'd be better off
wedging into the higher-level primitives like GRect() from
src/main/graphics.c. This would have a much better chance of being
portable across devices and the efficiency loss is likely not to be
too bad. 

-- 
   O__  ---- Peter Dalgaard             Blegdamsvej 3  
  c/ /'_ --- Dept. of Biostatistics     2200 Cph. N   
 (*) \(*) -- University of Copenhagen   Denmark      Ph: (+45) 35327918
~~~~~~~~~~ - (p.dalgaard at biostat.ku.dk)             FAX: (+45) 35327907
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._



More information about the R-help mailing list