PLplot: plstream.cc Source File

PLplot 5.15.0

plstream.cc
Go to the documentation of this file.
1 //----------------------------------*-C++-*----------------------------------//
2 //
3 // Copyright (C) 1995 Geoffrey Furnish
4 // Copyright (C) 1995-2002 Maurice LeBrun
5 // Copyright (C) 2000-2018 Alan W. Irwin
6 // Copyright (C) 2003 Joao Cardoso
7 // Copyright (C) 2003-2013 Andrew Ross
8 // Copyright (C) 2004-2005 Rafael Laboissiere
9 // Copyright (C) 2006-2008 Werner Smekal
10 // Copyright (C) 2009 Hazen Babcock
11 // Copyright (C) 2010-2011 Hezekiah M. Carty
12 // Copyright (C) 2014-2015 Phil Rosenberg
13 //
14 // This file is part of PLplot.
15 //
16 // PLplot is free software; you can redistribute it and/or modify
17 // it under the terms of the GNU Library General Public License as published
18 // by the Free Software Foundation; either version 2 of the License, or
19 // (at your option) any later version.
20 //
21 // PLplot is distributed in the hope that it will be useful,
22 // but WITHOUT ANY WARRANTY; without even the implied warranty of
23 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 // GNU Library General Public License for more details.
25 //
26 // You should have received a copy of the GNU Library General Public License
27 // along with PLplot; if not, write to the Free Software
28 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
29
30 //--------------------------------------------------------------------------
31 // @> Source file plstream.
32 //--------------------------------------------------------------------------
33
34 #include "plplot.h"
35 #include "plstream.h"
36
37 #include <iostream>
38
39 #ifdef PL_USE_NAMESPACE
40 using namespace std;
41 #endif
42
43 PLFLT Contourable_Data_evaluator( PLINT i, PLINT j, PLPointer p )
44 {
45 const Contourable_Data& d = *(Contourable_Data *) p;
46
47 return d( i, j );
48 }
49
50 void Coord_Xform_evaluator( PLFLT ox, PLFLT oy,
51 PLFLT *nx, PLFLT *ny, PLPointer p )
52 {
53 const Coord_Xformer& xf = *(Coord_Xformer *) p;
54
55 xf.xform( ox, oy, *nx, *ny );
56 }
57
58 // A specific case for handling transformation defined by 2-d grid vertex
59 // specification matrices.
60
61 cxx_pltr2::cxx_pltr2( Coord_2d& cx, Coord_2d& cy )
62 : xg( cx ), yg( cy )
63 {
64 }
65
66 // Next routine copied and modified for C++ from PLPLOT 4.99d.
67
68 //--------------------------------------------------------------------------
69 // pltr2()
70 //
71 // Does linear interpolation from doubly dimensioned coord arrays
72 // (column dominant, as per normal C 2d arrays).
73 //
74 // This routine includes lots of checks for out of bounds. This would
75 // occur occasionally due to some bugs in the contour plotter (now fixed).
76 // If an out of bounds coordinate is obtained, the boundary value is provided
77 // along with a warning. These checks should stay since no harm is done if
78 // if everything works correctly.
79 //--------------------------------------------------------------------------
80
81 void cxx_pltr2::xform( PLFLT x, PLFLT y, PLFLT& tx, PLFLT& ty ) const
82 {
83 int nx, ny;
84 xg.elements( nx, ny );
85
86 int ul, ur, vl, vr;
87 PLFLT du, dv;
88
89 PLFLT xll, xlr, xrl, xrr;
90 PLFLT yll, ylr, yrl, yrr;
91 PLFLT xmin, xmax, ymin, ymax;
92
93 ul = (int) x;
94 ur = ul + 1;
95 du = x - ul;
96
97 vl = (int) y;
98 vr = vl + 1;
99 dv = y - vl;
100
101 xmin = 0;
102 xmax = nx - 1;
103 ymin = 0;
104 ymax = ny - 1;
105
106 if ( x < xmin || x > xmax || y < ymin || y > ymax )
107 {
108 cerr << "cxx_pltr2::xform, Invalid coordinates\n";
109
110 if ( x < xmin )
111 {
112 if ( y < ymin )
113 {
114 tx = xg( 0, 0 );
115 ty = yg( 0, 0 );
116 }
117 else if ( y > ymax )
118 {
119 tx = xg( 0, ny - 1 );
120 ty = yg( 0, ny - 1 );
121 }
122 else
123 {
124 xll = xg( 0, vl );
125 yll = yg( 0, vl );
126 xlr = xg( 0, vr );
127 ylr = yg( 0, vr );
128
129 tx = xll * ( 1 - dv ) + xlr * ( dv );
130 ty = yll * ( 1 - dv ) + ylr * ( dv );
131 }
132 }
133 else if ( x > xmax )
134 {
135 if ( y < ymin )
136 {
137 tx = xg( nx - 1, 0 );
138 ty = yg( nx - 1, 0 );
139 }
140 else if ( y > ymax )
141 {
142 tx = xg( nx - 1, ny - 1 );
143 ty = yg( nx - 1, ny - 1 );
144 }
145 else
146 {
147 xll = xg( nx - 1, vl );
148 yll = yg( nx - 1, vl );
149 xlr = xg( nx - 1, vr );
150 ylr = yg( nx - 1, vr );
151
152 tx = xll * ( 1 - dv ) + xlr * ( dv );
153 ty = yll * ( 1 - dv ) + ylr * ( dv );
154 }
155 }
156 else
157 {
158 if ( y < ymin )
159 {
160 xll = xg( ul, 0 );
161 xrl = xg( ur, 0 );
162 yll = yg( ul, 0 );
163 yrl = yg( ur, 0 );
164
165 tx = xll * ( 1 - du ) + xrl * ( du );
166 ty = yll * ( 1 - du ) + yrl * ( du );
167 }
168 else if ( y > ymax )
169 {
170 xlr = xg( ul, ny - 1 );
171 xrr = xg( ur, ny - 1 );
172 ylr = yg( ul, ny - 1 );
173 yrr = yg( ur, ny - 1 );
174
175 tx = xlr * ( 1 - du ) + xrr * ( du );
176 ty = ylr * ( 1 - du ) + yrr * ( du );
177 }
178 }
179 }
180
181 // Normal case.
182 // Look up coordinates in row-dominant array.
183 // Have to handle right boundary specially -- if at the edge, we'd
184 // better not reference the out of bounds point.
185
186 else
187 {
188 xll = xg( ul, vl );
189 yll = yg( ul, vl );
190
191 // ur is out of bounds
192
193 if ( ur == nx && vr < ny )
194 {
195 xlr = xg( ul, vr );
196 ylr = yg( ul, vr );
197
198 tx = xll * ( 1 - dv ) + xlr * ( dv );
199 ty = yll * ( 1 - dv ) + ylr * ( dv );
200 }
201
202 // vr is out of bounds
203
204 else if ( ur < nx && vr == ny )
205 {
206 xrl = xg( ur, vl );
207 yrl = yg( ur, vl );
208
209 tx = xll * ( 1 - du ) + xrl * ( du );
210 ty = yll * ( 1 - du ) + yrl * ( du );
211 }
212
213 // both ur and vr are out of bounds
214
215 else if ( ur == nx && vr == ny )
216 {
217 tx = xll;
218 ty = yll;
219 }
220
221 // everything in bounds
222
223 else
224 {
225 xrl = xg( ur, vl );
226 xlr = xg( ul, vr );
227 xrr = xg( ur, vr );
228
229 yrl = yg( ur, vl );
230 ylr = yg( ul, vr );
231 yrr = yg( ur, vr );
232
233 tx = xll * ( 1 - du ) * ( 1 - dv ) + xlr * ( 1 - du ) * ( dv ) +
234 xrl * ( du ) * ( 1 - dv ) + xrr * ( du ) * ( dv );
235
236 ty = yll * ( 1 - du ) * ( 1 - dv ) + ylr * ( 1 - du ) * ( dv ) +
237 yrl * ( du ) * ( 1 - dv ) + yrr * ( du ) * ( dv );
238 }
239 }
240 }
241
242 //Callbacks
243
244 // Callback for plfill. This will just call the C plfill function
245
246 void plcallback::fill( PLINT n, const PLFLT *x, const PLFLT *y )
247 {
248 plfill( n, x, y );
249 }
250
251 // Transformation routines
252
253 // Identity transformation.
254
255 void plcallback::tr0( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty,
256 PLPointer pltr_data )
257 {
258 pltr0( x, y, tx, ty, pltr_data );
259 }
260
261 // Does linear interpolation from singly dimensioned coord arrays.
262
263 void plcallback::tr1( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty,
264 PLPointer pltr_data )
265 {
266 pltr1( x, y, tx, ty, pltr_data );
267 }
268
269 // Does linear interpolation from doubly dimensioned coord arrays
270 // (column dominant, as per normal C 2d arrays).
271
272 void plcallback::tr2( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty,
273 PLPointer pltr_data )
274 {
275 pltr2( x, y, tx, ty, pltr_data );
276 }
277
278 // Just like pltr2() but uses pointer arithmetic to get coordinates from
279 // 2d grid tables.
280
281 void plcallback::tr2p( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty,
282 PLPointer pltr_data )
283 {
284 pltr2p( x, y, tx, ty, pltr_data );
285 }
286
287 PLINT plstream::active_streams = 0;
288
289 plstream::plstream()
290 {
291 ::c_plmkstrm( &stream );
292 //::c_plinit();
293 active_streams++;
294 }
295
296 plstream::plstream ( PLS::stream_id sid, PLINT strm /*=0*/ )
297 {
298 switch ( sid )
299 {
300 case PLS::Next:
301 // throw( "plstream ctor option not implemented." );
302 break;
303
304 case PLS::Current:
305 ::c_plgstrm( &stream );
306 break;
307
308 case PLS::Specific:
309 stream = strm;
310 break;
311
312 default:
313 // throw( "plstream ctor option not implemented." );
314 break;
315 }
316 }
317
318 plstream::plstream( PLINT nx, PLINT ny, const char *driver, const char *file )
319 {
320 ::c_plmkstrm( &stream );
321
322 if ( driver )
323 ::c_plsdev( driver );
324 if ( file )
325 ::c_plsfnam( file );
326 ::c_plssub( nx, ny );
327 //::c_plinit();
328
329 active_streams++;
330 }
331
332 plstream::plstream( PLINT nx, PLINT ny, PLINT r, PLINT g, PLINT b,
333 const char *driver, const char *file )
334 {
335 ::c_plmkstrm( &stream );
336
337 if ( driver )
338 ::c_plsdev( driver );
339 if ( file )
340 ::c_plsfnam( file );
341 ::c_plssub( nx, ny );
342 ::c_plscolbg( r, g, b );
343 //::c_plinit();
344
345 active_streams++;
346 }
347
348 plstream::~plstream()
349 {
350 ::c_plsstrm( stream );
351 ::c_plend1();
352
353 active_streams--;
354 if ( !active_streams )
355 ::c_plend();
356 }
357
358 #define BONZAI { throw "plstream method not implemented."; }
359
360 // C routines callable from stub routines come first
361
362 // Advance to subpage "page", or to the next one if "page" = 0.
363
364 void
365 plstream::adv( PLINT page )
366 {
367 set_stream();
368
369 pladv( page );
370 }
371
372 void
373 plstream::arc( PLFLT x, PLFLT y, PLFLT a, PLFLT b, PLFLT angle1, PLFLT angle2,
374 PLFLT rotate, PLBOOL fill )
375 {
376 set_stream();
377
378 plarc( x, y, a, b, angle1, angle2, rotate, fill );
379 }
380
381 void
382 plstream::vect( const PLFLT * const *u, const PLFLT * const *v, PLINT nx, PLINT ny, PLFLT scale,
383 PLTRANSFORM_callback pltr, PLPointer pltr_data )
384 {
385 set_stream();
386
387 plvect( u, v, nx, ny, scale, pltr, pltr_data );
388 }
389
390 void
391 plstream::svect( const PLFLT *arrow_x, const PLFLT *arrow_y, PLINT npts, bool fill )
392 {
393 set_stream();
394
395 plsvect( arrow_x, arrow_y, npts, (PLBOOL) fill );
396 }
397
398 // This functions similarly to plbox() except that the origin of the axes is
399 // placed at the user-specified point (x0, y0).
400
401 void
402 plstream::axes( PLFLT x0, PLFLT y0, const char *xopt, PLFLT xtick, PLINT nxsub,
403 const char *yopt, PLFLT ytick, PLINT nysub )
404 {
405 set_stream();
406
407 plaxes( x0, y0, xopt, xtick, nxsub, yopt, ytick, nysub );
408 }
409
410 // Plot a histogram using x to store data values and y to store frequencies.
411
412 void plstream::bin( PLINT nbin, const PLFLT *x, const PLFLT *y, PLINT center )
413 {
414 set_stream();
415
416 plbin( nbin, x, y, center );
417 }
418
419 // Start new page. Should only be used with pleop().
420
421 void plstream::bop()
422 {
423 set_stream();
424
425 plbop();
426 }
427
428 // This draws a box around the current viewport.
429
430 void plstream::box( const char *xopt, PLFLT xtick, PLINT nxsub,
431 const char *yopt, PLFLT ytick, PLINT nysub )
432 {
433 set_stream();
434
435 plbox( xopt, xtick, nxsub, yopt, ytick, nysub );
436 }
437
438
439 // This is the 3-d analogue of plbox().
440
441 void
442 plstream::box3( const char *xopt, const char *xlabel, PLFLT xtick, PLINT nsubx,
443 const char *yopt, const char *ylabel, PLFLT ytick, PLINT nsuby,
444 const char *zopt, const char *zlabel, PLFLT ztick, PLINT nsubz )
445 {
446 set_stream();
447
448 plbox3( xopt, xlabel, xtick, nsubx,
449 yopt, ylabel, ytick, nsuby,
450 zopt, zlabel, ztick, nsubz );
451 }
452
453 // Calculate broken-down time from continuous time for current stream.
454 void plstream::btime( PLINT & year, PLINT & month, PLINT & day, PLINT & hour,
455 PLINT & min, PLFLT & sec, PLFLT ctime )
456 {
457 set_stream();
458
459 plbtime( &year, &month, &day, &hour, &min, &sec, ctime );
460 }
461
462 // Calculate world coordinates and subpage from relative device coordinates.
463
464 void plstream::calc_world( PLFLT rx, PLFLT ry, PLFLT & wx, PLFLT & wy,
465 PLINT & window )
466 {
467 set_stream();
468
469 plcalc_world( rx, ry, &wx, &wy, &window );
470 }
471
472 // Clear the current subpage.
473
474 void plstream::clear()
475 {
476 set_stream();
477
478 plclear();
479 }
480
481 // Set color, map 0. Argument is integer between 0 and 15.
482
483 void plstream::col0( PLINT icol0 )
484 {
485 set_stream();
486
487 plcol0( icol0 );
488 }
489
490 // Set the color using a descriptive name. Replaces plcol0().
491
492 void plstream::col( PLcolor c )
493 {
494 set_stream();
495
496 plcol0( (int) c );
497 }
498
499 // Set color, map 1. Argument is a float between 0. and 1.
500
501 void plstream::col1( PLFLT c )
502 {
503 set_stream();
504
505 plcol1( c );
506 }
507
508 #ifdef PL_DEPRECATED
509 // Old (incorrect) version retained only for compatibility
510 void plstream::col( PLFLT c )
511 {
512 set_stream();
513
514 cerr <<
515 "plstream::col(PLFLT c) : function deprecated. Use plstream::col1(PLFLT c) instead"
516 << endl;
517
518 plcol1( c );
519 }
520 #endif //PL_DEPRECATED
521
522 // Configure transformation between continuous and broken-down time (and
523 // vice versa) for current stream.
524 void plstream::configtime( PLFLT scale, PLFLT offset1, PLFLT offset2,
525 PLINT ccontrol, PLBOOL ifbtime_offset, PLINT year,
526 PLINT month, PLINT day, PLINT hour, PLINT min,
527 PLFLT sec )
528 {
529 set_stream();
530
531 plconfigtime( scale, offset1, offset2, ccontrol, ifbtime_offset, year,
532 month, day, hour, min, sec );
533 }
534
535
536
537 // Draws a contour plot from data in f(nx,ny). Is just a front-end to
538 // plfcont, with a particular choice for f2eval and f2eval_data.
539
540 void plstream::cont( const PLFLT * const *f, PLINT nx, PLINT ny, PLINT kx, PLINT lx,
541 PLINT ky, PLINT ly, const PLFLT *clevel, PLINT nlevel,
542 PLTRANSFORM_callback pltr, PLPointer pltr_data )
543 {
544 set_stream();
545
546 plcont( f, nx, ny, kx, lx, ky, ly, clevel, nlevel,
547 pltr, pltr_data );
548 }
549
550 // Draws a contour plot using the function evaluator f2eval and data stored
551 // by way of the f2eval_data pointer. This allows arbitrary organizations
552 // of 2d array data to be used.
553
554 void plstream::fcont( PLFLT ( *f2eval )( PLINT, PLINT, PLPointer ),
555 PLPointer f2eval_data,
556 PLINT nx, PLINT ny, PLINT kx, PLINT lx,
557 PLINT ky, PLINT ly, const PLFLT *clevel, PLINT nlevel,
558 PLTRANSFORM_callback pltr, PLPointer pltr_data )
559 {
560 set_stream();
561
562 plfcont( f2eval, f2eval_data,
563 nx, ny, kx, lx, ky, ly, clevel, nlevel,
564 pltr, pltr_data );
565 }
566
567 // Copies state parameters from the reference stream to the current stream.
568
569 void plstream::cpstrm( plstream & pls, bool flags )
570 {
571 set_stream();
572
573 plcpstrm( pls.stream, (PLBOOL) flags );
574 }
575
576 // Calculate continuous time from broken-down time for current stream.
577 void plstream::ctime( PLINT year, PLINT month, PLINT day, PLINT hour, PLINT min,
578 PLFLT sec, PLFLT & ctime )
579 {
580 set_stream();
581
582 plctime( year, month, day, hour, min, sec, &ctime );
583 }
584
585 // Converts input values from relative device coordinates to relative plot
586 // coordinates.
587
588 void plstream::did2pc( PLFLT & xmin, PLFLT & ymin, PLFLT & xmax, PLFLT & ymax )
589 {
590 set_stream();
591
592 pldid2pc( &xmin, &ymin, &xmax, &ymax );
593 }
594
595 // Converts input values from relative plot coordinates to relative device
596 // coordinates.
597
598 void plstream::dip2dc( PLFLT & xmin, PLFLT & ymin, PLFLT & xmax, PLFLT & ymax )
599 {
600 set_stream();
601
602 pldip2dc( &xmin, &ymin, &xmax, &ymax );
603 }
604
605 // These shouldn't be needed, are supposed to be handled by ctor/dtor
606 // semantics of the plstream object.
607
608 // End a plotting session for all open streams.
609
610 // void plstream::end()
611 // {
612 // set_stream();
613
614 // plend();
615 // }
616
617 // End a plotting session for the current stream only.
618
619 // void plstream::end1()
620 // {
621 // set_stream();
622
623 // plend1();
624 // }
625
626 // Simple interface for defining viewport and window.
627
628 void plstream::env( PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax,
629 PLINT just, PLINT axis )
630 {
631 set_stream();
632
633 plenv( xmin, xmax, ymin, ymax, just, axis );
634 }
635
636 // Similar to env() above, but in multiplot mode does not advance
637 // the subpage, instead the current subpage is cleared
638
639 void plstream::env0( PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax,
640 PLINT just, PLINT axis )
641 {
642 set_stream();
643
644 plenv0( xmin, xmax, ymin, ymax, just, axis );
645 }
646
647 // End current page. Should only be used with plbop().
648
649 void plstream::eop()
650 {
651 set_stream();
652
653 pleop();
654 }
655
656 // Plot horizontal error bars (xmin(i),y(i)) to (xmax(i),y(i)).
657
658 void plstream::errx( PLINT n, const PLFLT *xmin, const PLFLT *xmax, const PLFLT *y )
659 {
660 set_stream();
661
662 plerrx( n, xmin, xmax, y );
663 }
664
665 // Plot vertical error bars (x,ymin(i)) to (x(i),ymax(i)).
666
667 void plstream::erry( PLINT n, const PLFLT *x, const PLFLT *ymin, const PLFLT *ymax )
668 {
669 set_stream();
670
671 plerry( n, x, ymin, ymax );
672 }
673
674 // Advance to the next family file on the next new page.
675
676 void plstream::famadv()
677 {
678 set_stream();
679
680 plfamadv();
681 }
682
683 // Pattern fills the polygon bounded by the input points.
684
685 void plstream::fill( PLINT n, const PLFLT *x, const PLFLT *y )
686 {
687 set_stream();
688
689 plfill( n, x, y );
690 }
691
692 // Pattern fills the 3d polygon bounded by the input points.
693
694 void plstream::fill3( PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z )
695 {
696 set_stream();
697
698 plfill3( n, x, y, z );
699 }
700
701 // Flushes the output stream. Use sparingly, if at all.
702
703 void plstream::flush()
704 {
705 set_stream();
706
707 ::c_plflush();
708 }
709
710 // Sets the global font flag to 'ifont'.
711
712 void plstream::font( PLINT ifont )
713 {
714 set_stream();
715
716 plfont( ifont );
717 }
718
719 // Load specified font set.
720
721 void plstream::fontld( PLINT fnt )
722 {
723 set_stream();
724
725 plfontld( fnt );
726 }
727
728 // Get character default height and current (scaled) height.
729
730 void plstream::gchr( PLFLT & p_def, PLFLT & p_ht )
731 {
732 set_stream();
733
734 plgchr( &p_def, &p_ht );
735 }
736
737 // Returns 8 bit RGB values for given color from color map 0.
738
739 void plstream::gcol0( PLINT icol0, PLINT & r, PLINT & g, PLINT & b )
740 {
741 set_stream();
742
743 plgcol0( icol0, &r, &g, &b );
744 }
745
746 // Returns 8 bit RGB values + alpha value for given color from color map 0.
747
748 void plstream::gcol0a( PLINT icol0, PLINT & r, PLINT & g, PLINT & b, PLFLT & a )
749 {
750 set_stream();
751
752 plgcol0a( icol0, &r, &g, &b, &a );
753 }
754
755 // Returns the background color by 8 bit RGB value.
756
757 void plstream::gcolbg( PLINT & r, PLINT & g, PLINT & b )
758 {
759 set_stream();
760
761 plgcolbg( &r, &g, &b );
762 }
763
764 // Returns the background color by 8 bit RGB value + alpha value.
765
766 void plstream::gcolbga( PLINT & r, PLINT & g, PLINT & b, PLFLT & a )
767 {
768 set_stream();
769
770 plgcolbga( &r, &g, &b, &a );
771 }
772
773 // Returns the current compression setting
774
775 void plstream::gcompression( PLINT & compression )
776 {
777 set_stream();
778
779 plgcompression( &compression );
780 }
781
782 // Retrieve current window into device space.
783
784 void plstream::gdidev( PLFLT & mar, PLFLT & aspect, PLFLT & jx, PLFLT & jy )
785 {
786 set_stream();
787
788 plgdidev( &mar, &aspect, &jx, &jy );
789 }
790
791 // Get plot orientation.
792
793 void plstream::gdiori( PLFLT & rot )
794 {
795 set_stream();
796
797 plgdiori( &rot );
798 }
799
800 // Retrieve current window into plot space.
801
802 void plstream::gdiplt( PLFLT & xmin, PLFLT & ymin, PLFLT & xmax, PLFLT & ymax )
803 {
804 set_stream();
805
806 plgdiplt( &xmin, &ymin, &xmax, &ymax );
807 }
808
809 // Get FCI (font characterization integer)
810
811 void plstream::gfci( PLUNICODE & pfci )
812 {
813 set_stream();
814
815 plgfci( &pfci );
816 }
817
818 // Get family file parameters.
819
820 void plstream::gfam( PLINT & fam, PLINT & num, PLINT & bmax )
821 {
822 set_stream();
823
824 plgfam( &fam, &num, &bmax );
825 }
826
827 // Get the (current) output file name. Must be preallocated to >80 bytes.
828
829 void plstream::gfnam( char *fnam )
830 {
831 set_stream();
832
833 plgfnam( fnam );
834 }
835
836 // Get the current font family, style and weight
837
838 void plstream::gfont( PLINT & family, PLINT & style, PLINT & weight )
839 {
840 set_stream();
841
842 plgfont( &family, &style, &weight );
843 }
844
845 // Get current run level.
846
847 void plstream::glevel( PLINT & level )
848 {
849 set_stream();
850
851 plglevel( &level );
852 }
853
854 // Get output device parameters.
855
856 void plstream::gpage( PLFLT & xp, PLFLT & yp, PLINT & xleng, PLINT & yleng,
857 PLINT & xoff, PLINT & yoff )
858 {
859 set_stream();
860
861 plgpage( &xp, &yp, &xleng, &yleng, &xoff, &yoff );
862 }
863
864 // Switches to graphics screen.
865
866 void plstream::gra()
867 {
868 set_stream();
869
870 plgra();
871 }
872
873
874 // Draw gradient in polygon.
875
876 void plstream::gradient( PLINT n, const PLFLT *x, const PLFLT *y, PLFLT angle )
877 {
878 set_stream();
879
880 plgradient( n, x, y, angle );
881 }
882
883 // grid irregularly sampled data
884 void plstream::griddata( const PLFLT *x, const PLFLT *y, const PLFLT *z, PLINT npts,
885 const PLFLT *xg, PLINT nptsx, const PLFLT *yg, PLINT nptsy,
886 PLFLT **zg, PLINT type, PLFLT data )
887 {
888 set_stream();
889
890 plgriddata( x, y, z, npts, xg, nptsx, yg, nptsy, zg, type, data );
891 }
892
893 // Get subpage boundaries in absolute coordinates.
894
895 void plstream::gspa( PLFLT & xmin, PLFLT & xmax, PLFLT & ymin, PLFLT & ymax )
896 {
897 set_stream();
898
899 plgspa( &xmin, &xmax, &ymin, &ymax );
900 }
901
902 // This shouldn't be needed in this model.
903
904 // Get current stream number.
905
906 // void plstream::gstrm( PLINT *p_strm )
907 // {
908 // set_stream();
909
910 // plgstrm(p_strm);
911 // }
912
913 // Get the current library version number.
914
915 void plstream::gver( char *p_ver )
916 {
917 set_stream();
918
919 plgver( p_ver );
920 }
921
922 // Get viewport window in normalized world coordinates
923
924 void plstream::gvpd( PLFLT & xmin, PLFLT & xmax, PLFLT & ymin, PLFLT & ymax )
925 {
926 set_stream();
927
928 plgvpd( &xmin, &xmax, &ymin, &ymax );
929 }
930
931 // Get viewport window in world coordinates
932
933 void plstream::gvpw( PLFLT & xmin, PLFLT & xmax, PLFLT & ymin, PLFLT & ymax )
934 {
935 set_stream();
936
937 plgvpw( &xmin, &xmax, &ymin, &ymax );
938 }
939
940 // Get x axis labeling parameters.
941
942 void plstream::gxax( PLINT & digmax, PLINT & digits )
943 {
944 set_stream();
945
946 plgxax( &digmax, &digits );
947 }
948
949 // Get y axis labeling parameters.
950
951 void plstream::gyax( PLINT & digmax, PLINT & digits )
952 {
953 set_stream();
954
955 plgyax( &digmax, &digits );
956 }
957
958 // Get z axis labeling parameters
959
960 void plstream::gzax( PLINT & digmax, PLINT & digits )
961 {
962 set_stream();
963
964 plgzax( &digmax, &digits );
965 }
966
967 // Draws a histogram of n values of a variable in array data[0..n-1]
968
969 void plstream::hist( PLINT n, const PLFLT *data, PLFLT datmin, PLFLT datmax,
970 PLINT nbin, PLINT oldwin )
971 {
972 set_stream();
973
974 plhist( n, data, datmin, datmax, nbin, oldwin );
975 }
976
977 // Set current color (map 0) by hue, lightness, and saturation.
978
979 // Initializes PLplot, using preset or default options
980
981 void plstream::init()
982 {
983 set_stream();
984
985 plinit();
986
987 plgstrm( &stream );
988
989 // This is only set in the constructor.
990 //active_streams++;
991 }
992
993 // Draws a line segment from (x1, y1) to (x2, y2).
994
995 void plstream::join( PLFLT x1, PLFLT y1, PLFLT x2, PLFLT y2 )
996 {
997 set_stream();
998
999 pljoin( x1, y1, x2, y2 );
1000 }
1001
1002 // Simple routine for labelling graphs.
1003
1004 void plstream::lab( const char *xlabel, const char *ylabel,
1005 const char *tlabel )
1006 {
1007 set_stream();
1008
1009 pllab( xlabel, ylabel, tlabel );
1010 }
1011
1012 // Routine for drawing line, symbol, or cmap0 legends
1013
1014 void plstream::legend( PLFLT *p_legend_width, PLFLT *p_legend_height,
1015 PLINT opt, PLINT position, PLFLT x, PLFLT y, PLFLT plot_width,
1016 PLINT bg_color, PLINT bb_color, PLINT bb_style,
1017 PLINT nrow, PLINT ncolumn,
1018 PLINT nlegend, const PLINT *opt_array,
1019 PLFLT text_offset, PLFLT text_scale, PLFLT text_spacing,
1020 PLFLT text_justification,
1021 const PLINT *text_colors, const char * const *text,
1022 const PLINT *box_colors, const PLINT *box_patterns,
1023 const PLFLT *box_scales, const PLFLT *box_line_widths,
1024 const PLINT *line_colors, const PLINT *line_styles,
1025 const PLFLT *line_widths,
1026 const PLINT *symbol_colors, const PLFLT *symbol_scales,
1027 const PLINT *symbol_numbers, const char * const *symbols )
1028 {
1029 set_stream();
1030
1031 pllegend( p_legend_width, p_legend_height, opt, position, x, y, plot_width,
1032 bg_color, bb_color, bb_style, nrow, ncolumn, nlegend, opt_array,
1033 text_offset, text_scale, text_spacing, text_justification,
1034 text_colors, text, box_colors, box_patterns, box_scales,
1035 box_line_widths, line_colors, line_styles, line_widths,
1036 symbol_colors, symbol_scales, symbol_numbers, symbols );
1037 }
1038
1039 void plstream::colorbar( PLFLT *p_colorbar_width, PLFLT *p_colorbar_height,
1040 PLINT opt, PLINT position, PLFLT x, PLFLT y,
1041 PLFLT x_length, PLFLT y_length,
1042 PLINT bg_color, PLINT bb_color, PLINT bb_style,
1043 PLFLT low_cap_color, PLFLT high_cap_color,
1044 PLINT cont_color, PLFLT cont_width,
1045 PLINT n_labels, PLINT *label_opts, const char * const *label,
1046 PLINT n_axes, const char * const *axis_opts,
1047 PLFLT *ticks, PLINT *sub_ticks,
1048 PLINT *n_values, const PLFLT * const *values )
1049 {
1050 set_stream();
1051
1052 plcolorbar( p_colorbar_width, p_colorbar_height, opt, position, x, y,
1053 x_length, y_length, bg_color, bb_color, bb_style,
1054 low_cap_color, high_cap_color, cont_color, cont_width,
1055 n_labels, label_opts, label, n_axes, axis_opts,
1056 ticks, sub_ticks, n_values, values );
1057 }
1058
1059
1060 // Sets position of the light source
1061
1062 void plstream::lightsource( PLFLT x, PLFLT y, PLFLT z )
1063 {
1064 set_stream();
1065
1066 pllightsource( x, y, z );
1067 }
1068
1069 // Draws line segments connecting a series of points.
1070
1071 void plstream::line( PLINT n, const PLFLT *x, const PLFLT *y )
1072 {
1073 set_stream();
1074
1075 plline( n, x, y );
1076 }
1077
1078 // Draws a line in 3 space.
1079
1080 void plstream::line3( PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z )
1081 {
1082 set_stream();
1083
1084 plline3( n, x, y, z );
1085 }
1086
1087 // Set line style.
1088
1089 void plstream::lsty( PLINT lin )
1090 {
1091 set_stream();
1092
1093 pllsty( lin );
1094 }
1095
1096 // Plot continental outline in world coordinates
1097
1098 void plstream::map( PLMAPFORM_callback mapform,
1099 const char *name, PLFLT minx, PLFLT maxx,
1100 PLFLT miny, PLFLT maxy )
1101 {
1102 set_stream();
1103
1104 plmap( mapform, name, minx, maxx, miny, maxy );
1105 }
1106
1107 // Plot map lines
1108
1109 void plstream::mapline( PLMAPFORM_callback mapform, const char *name,
1110 PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy,
1111 const PLINT *plotentries, PLINT nplotentries )
1112 {
1113 set_stream();
1114
1115 plmapline( mapform, name, minx, maxx, miny, maxy, plotentries, nplotentries );
1116 }
1117
1118 // Plot map points
1119
1120 void plstream::mapstring( PLMAPFORM_callback mapform,
1121 const char *name, const char *string,
1122 PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy,
1123 const PLINT *plotentries, PLINT nplotentries )
1124 {
1125 set_stream();
1126
1127 plmapstring( mapform, name, string, minx, maxx, miny, maxy, plotentries, nplotentries );
1128 }
1129
1130 // Plot map text
1131
1132 void plstream::maptex( PLMAPFORM_callback mapform,
1133 const char *name, PLFLT dx, PLFLT dy, PLFLT just, const char *text,
1134 PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy,
1135 PLINT plotentry )
1136 {
1137 set_stream();
1138
1139 plmaptex( mapform, name, dx, dy, just, text, minx, maxx, miny, maxy, plotentry );
1140 }
1141
1142 // Plot map fills
1143
1144 void plstream::mapfill( PLMAPFORM_callback mapform,
1145 const char *name, PLFLT minx, PLFLT maxx, PLFLT miny,
1146 PLFLT maxy, const PLINT *plotentries, PLINT nplotentries )
1147 {
1148 set_stream();
1149
1150 plmapfill( mapform, name, minx, maxx, miny, maxy, plotentries, nplotentries );
1151 }
1152
1153 // Plot the latitudes and longitudes on the background.
1154
1155 void plstream::meridians( PLMAPFORM_callback mapform,
1156 PLFLT dlong, PLFLT dlat,
1157 PLFLT minlong, PLFLT maxlong,
1158 PLFLT minlat, PLFLT maxlat )
1159 {
1160 set_stream();
1161
1162 plmeridians( mapform, dlong, dlat, minlong, maxlong, minlat,
1163 maxlat );
1164 }
1165
1166 // Plots a mesh representation of the function z[x][y].
1167
1168 void plstream::mesh( const PLFLT *x, const PLFLT *y, const PLFLT * const *z, PLINT nx, PLINT ny,
1169 PLINT opt )
1170 {
1171 set_stream();
1172
1173 plmesh( x, y, z, nx, ny, opt );
1174 }
1175
1176 // Plots a mesh representation of the function z[x][y] with contour.
1177
1178 void plstream::meshc( const PLFLT *x, const PLFLT *y, const PLFLT * const *z, PLINT nx, PLINT ny,
1179 PLINT opt, const PLFLT *clevel, PLINT nlevel )
1180 {
1181 set_stream();
1182
1183 plmeshc( x, y, z, nx, ny, opt, clevel, nlevel );
1184 }
1185
1186 // Creates a new stream and makes it the default.
1187
1188 // void plstream::mkstrm( PLINT *p_strm )
1189 // {
1190 // set_stream();
1191
1192 // plmkstrm(p_strm);
1193 // }
1194
1195 // Prints out "text" at specified position relative to viewport
1196
1197 void plstream::mtex( const char *side, PLFLT disp, PLFLT pos, PLFLT just,
1198 const char *text )
1199 {
1200 set_stream();
1201
1202 plmtex( side, disp, pos, just, text );
1203 }
1204
1205 // Prints out "text" at specified position relative to viewport (3D)
1206
1207 void plstream::mtex3( const char *side, PLFLT disp, PLFLT pos, PLFLT just,
1208 const char *text )
1209 {
1210 set_stream();
1211
1212 plmtex3( side, disp, pos, just, text );
1213 }
1214
1215 // Plots a 3-d shaded representation of the function z[x][y].
1216
1217 void plstream::surf3d( const PLFLT *x, const PLFLT *y, const PLFLT * const *z,
1218 PLINT nx, PLINT ny, PLINT opt,
1219 const PLFLT *clevel, PLINT nlevel )
1220 {
1221 set_stream();
1222
1223 plsurf3d( x, y, z, nx, ny, opt, clevel, nlevel );
1224 }
1225
1226 // Plots a 3-d shaded representation of the function z[x][y] with
1227 // y index limits
1228
1229 void plstream::surf3dl( const PLFLT *x, const PLFLT *y, const PLFLT * const *z,
1230 PLINT nx, PLINT ny, PLINT opt,
1231 const PLFLT *clevel, PLINT nlevel,
1232 PLINT ixstart, PLINT ixn,
1233 const PLINT *indexymin, const PLINT *indexymax )
1234 {
1235 set_stream();
1236
1237 plsurf3dl( x, y, z, nx, ny, opt, clevel, nlevel, ixstart, ixn,
1238 indexymin, indexymax );
1239 }
1240
1241 // Plots a 3-d representation of the function z[x][y].
1242
1243 void plstream::plot3d( const PLFLT *x, const PLFLT *y, const PLFLT * const *z,
1244 PLINT nx, PLINT ny, PLINT opt, bool side )
1245 {
1246 set_stream();
1247
1248 ::plot3d( x, y, z, nx, ny, opt, (PLBOOL) side );
1249 }
1250
1251 // Plots a 3-d representation of the function z[x][y] with contour.
1252
1253 void plstream::plot3dc( const PLFLT *x, const PLFLT *y, const PLFLT * const *z,
1254 PLINT nx, PLINT ny, PLINT opt,
1255 const PLFLT *clevel, PLINT nlevel )
1256 {
1257 set_stream();
1258
1259 ::plot3dc( x, y, z, nx, ny, opt, clevel, nlevel );
1260 }
1261
1262 // Plots a 3-d representation of the function z[x][y] with contour
1263 // and y index limits
1264
1265 void plstream::plot3dcl( const PLFLT *x, const PLFLT *y, const PLFLT * const *z,
1266 PLINT nx, PLINT ny, PLINT opt,
1267 const PLFLT *clevel, PLINT nlevel,
1268 PLINT ixstart, PLINT ixn,
1269 const PLINT *indexymin, const PLINT *indexymax )
1270 {
1271 set_stream();
1272
1273 ::plot3dcl( x, y, z, nx, ny, opt, clevel, nlevel, ixstart, ixn,
1274 indexymin, indexymax );
1275 }
1276
1277 // Process options list using current options info.
1278
1279 PLINT plstream::parseopts( int *p_argc, char **argv, PLINT mode )
1280 {
1281 set_stream();
1282
1283 return ::plparseopts( p_argc, argv, mode );
1284 }
1285
1286 // Set fill pattern directly.
1287
1288 void plstream::pat( PLINT nlin, const PLINT *inc, const PLINT *del )
1289 {
1290 set_stream();
1291
1292 plpat( nlin, inc, del );
1293 }
1294
1295 // Draw a line connecting two points, accounting for coordinate transforms
1296
1297 void plstream::path( PLINT n, PLFLT x1, PLFLT y1, PLFLT x2, PLFLT y2 )
1298 {
1299 set_stream();
1300
1301 plpath( n, x1, y1, x2, y2 );
1302 }
1303
1304 // Plots array y against x for n points using ASCII code "code".
1305
1306 void plstream::poin( PLINT n, const PLFLT *x, const PLFLT *y, PLINT code )
1307 {
1308 set_stream();
1309
1310 plpoin( n, x, y, code );
1311 }
1312
1313 // Draws a series of points in 3 space.
1314
1315 void plstream::poin3( PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z, PLINT code )
1316 {
1317 set_stream();
1318
1319 plpoin3( n, x, y, z, code );
1320 }
1321
1322 // Draws a polygon in 3 space.
1323
1324 void plstream::poly3( PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z,
1325 const bool *draw, bool ifcc )
1326 {
1327 PLBOOL *loc_draw = new PLBOOL[n - 1];
1328 for ( int i = 0; i < n - 1; i++ )
1329 {
1330 loc_draw[i] = (PLBOOL) draw[i];
1331 }
1332
1333 set_stream();
1334
1335 plpoly3( n, x, y, z, loc_draw, (PLBOOL) ifcc );
1336
1337 delete [] loc_draw;
1338 }
1339
1340 // Set the floating point precision (in number of places) in numeric labels.
1341
1342 void plstream::prec( PLINT setp, PLINT prec )
1343 {
1344 set_stream();
1345
1346 plprec( setp, prec );
1347 }
1348
1349 // Set fill pattern, using one of the predefined patterns.
1350
1351 void plstream::psty( PLINT patt )
1352 {
1353 set_stream();
1354
1355 plpsty( patt );
1356 }
1357
1358 // Prints out "text" at world cooordinate (x,y).
1359
1360 void plstream::ptex( PLFLT x, PLFLT y, PLFLT dx, PLFLT dy, PLFLT just,
1361 const char *text )
1362 {
1363 set_stream();
1364
1365 plptex( x, y, dx, dy, just, text );
1366 }
1367
1368 // Prints out "text" at world cooordinate (x,y).
1369
1370 void plstream::ptex3( PLFLT wx, PLFLT wy, PLFLT wz,
1371 PLFLT dx, PLFLT dy, PLFLT dz,
1372 PLFLT sx, PLFLT sy, PLFLT sz, PLFLT just,
1373 const char *text )
1374 {
1375 set_stream();
1376
1377 plptex3( wx, wy, wz, dx, dy, dz, sx, sy, sz, just, text );
1378 }
1379
1380 // Get the world coordinates associated with device coordinates
1381
1382 PLINT plstream::translatecursor( PLGraphicsIn *gin )
1383 {
1384 set_stream();
1385
1386 return plTranslateCursor( gin );
1387 }
1388
1389 // Replays contents of plot buffer to current device/file.
1390
1391 void plstream::replot()
1392 {
1393 set_stream();
1394
1395 plreplot();
1396 }
1397
1398 // Set character height.
1399
1400 void plstream::schr( PLFLT def, PLFLT scale )
1401 {
1402 set_stream();
1403
1404 plschr( def, scale );
1405 }
1406
1407 // Set number of colors in cmap 0
1408
1409 void plstream::scmap0n( PLINT ncol0 )
1410 {
1411 set_stream();
1412
1413 plscmap0n( ncol0 );
1414 }
1415
1416 // Set number of colors in cmap 1
1417
1418 void plstream::scmap1n( PLINT ncol1 )
1419 {
1420 set_stream();
1421
1422 plscmap1n( ncol1 );
1423 }
1424
1425 // Set number of colors in cmap 1
1426
1427 void plstream::scmap1_range( PLFLT min_color, PLFLT max_color )
1428 {
1429 set_stream();
1430
1431 plscmap1_range( min_color, max_color );
1432 }
1433
1434 // Set number of colors in cmap 1
1435
1436 void plstream::gcmap1_range( PLFLT & min_color, PLFLT & max_color )
1437 {
1438 set_stream();
1439
1440 plgcmap1_range( &min_color, &max_color );
1441 }
1442
1443 // Set color map 0 colors by 8 bit RGB values
1444
1445 void plstream::scmap0( const PLINT *r, const PLINT *g, const PLINT *b, PLINT ncol0 )
1446 {
1447 set_stream();
1448
1449 plscmap0( r, g, b, ncol0 );
1450 }
1451
1452 // Set color map 0 colors by 8 bit RGB values + alpha value
1453
1454 void plstream::scmap0a( const PLINT *r, const PLINT *g, const PLINT *b, const PLFLT *a, PLINT ncol0 )
1455 {
1456 set_stream();
1457
1458 plscmap0a( r, g, b, a, ncol0 );
1459 }
1460
1461 // Set color map 1 colors by 8 bit RGB values
1462
1463 void plstream::scmap1( const PLINT *r, const PLINT *g, const PLINT *b, PLINT ncol1 )
1464 {
1465 set_stream();
1466
1467 plscmap1( r, g, b, ncol1 );
1468 }
1469
1470 // Set color map 1 colors by 8 bit RGB values + alpha value
1471
1472 void plstream::scmap1a( const PLINT *r, const PLINT *g, const PLINT *b, const PLFLT *a, PLINT ncol1 )
1473 {
1474 set_stream();
1475
1476 plscmap1a( r, g, b, a, ncol1 );
1477 }
1478
1479 // Set color map 1 colors using a piece-wise linear relationship between
1480 // intensity [0,1] (cmap 1 index) and position in HLS or RGB color space.
1481
1482 void plstream::scmap1l( bool itype, PLINT npts, const PLFLT *intensity,
1483 const PLFLT *coord1, const PLFLT *coord2, const PLFLT *coord3,
1484 const bool *alt_hue_path )
1485 {
1486 PLBOOL *loc_alt_hue_path = NULL;
1487 if ( alt_hue_path != NULL )
1488 {
1489 loc_alt_hue_path = new PLBOOL[npts - 1];
1490 for ( int i = 0; i < npts - 1; i++ )
1491 {
1492 loc_alt_hue_path[i] = (PLBOOL) alt_hue_path[i];
1493 }
1494 }
1495
1496 set_stream();
1497
1498 plscmap1l( (PLBOOL) itype, npts, intensity, coord1, coord2, coord3, loc_alt_hue_path );
1499
1500 if ( loc_alt_hue_path != NULL )
1501 delete [] loc_alt_hue_path;
1502 }
1503
1504 // Set color map 1 colors using a piece-wise linear relationship between
1505 // intensity [0,1] (cmap 1 index) and position in HLS or RGB color space
1506 // and alpha value.
1507
1508 void plstream::scmap1la( bool itype, PLINT npts, const PLFLT *intensity,
1509 const PLFLT *coord1, const PLFLT *coord2, const PLFLT *coord3,
1510 const PLFLT *a, const bool *alt_hue_path )
1511 {
1512 PLBOOL *loc_alt_hue_path = NULL;
1513 if ( alt_hue_path != NULL )
1514 {
1515 loc_alt_hue_path = new PLBOOL[npts - 1];
1516 for ( int i = 0; i < npts - 1; i++ )
1517 {
1518 loc_alt_hue_path[i] = (PLBOOL) alt_hue_path[i];
1519 }
1520 }
1521
1522 set_stream();
1523
1524 plscmap1la( (PLBOOL) itype, npts, intensity, coord1, coord2, coord3,
1525 a, loc_alt_hue_path );
1526
1527 if ( loc_alt_hue_path != NULL )
1528 delete [] loc_alt_hue_path;
1529 }
1530
1531 //
1532 // void plstream::scmap1l( bool itype, PLINT npts, PLFLT *intensity,
1533 // PLFLT *coord1, PLFLT *coord2, PLFLT *coord3)
1534 // {
1535 // set_stream();
1536 //
1537 // plscmap1l((PLBOOL) itype,npts,intensity,coord1,coord2,coord3,NULL);
1538 //
1539 // }
1540
1541 // Set a given color from color map 0 by 8 bit RGB value
1542
1543 void plstream::scol0( PLINT icol0, PLINT r, PLINT g, PLINT b )
1544 {
1545 set_stream();
1546
1547 plscol0( icol0, r, g, b );
1548 }
1549
1550 // Set a given color from color map 0 by 8 bit RGB value + alpha value
1551
1552 void plstream::scol0a( PLINT icol0, PLINT r, PLINT g, PLINT b, PLFLT a )
1553 {
1554 set_stream();
1555
1556 plscol0a( icol0, r, g, b, a );
1557 }
1558
1559 // Set the background color by 8 bit RGB value
1560
1561 void plstream::scolbg( PLINT r, PLINT g, PLINT b )
1562 {
1563 set_stream();
1564
1565 plscolbg( r, g, b );
1566 }
1567
1568 // Set the background color by 8 bit RGB + alpha value
1569
1570 void plstream::scolbga( PLINT r, PLINT g, PLINT b, PLFLT a )
1571 {
1572 set_stream();
1573
1574 plscolbga( r, g, b, a );
1575 }
1576
1577 // Used to globally turn color output on/off
1578
1579 void plstream::scolor( PLINT color )
1580 {
1581 set_stream();
1582
1583 plscolor( color );
1584 }
1585
1586 // Sets the compression level
1587
1588 void plstream::scompression( PLINT compression )
1589 {
1590 set_stream();
1591
1592 plscompression( compression );
1593 }
1594
1595 // Set the device (keyword) name
1596
1597 void plstream::sdev( const char *devname )
1598 {
1599 set_stream();
1600
1601 plsdev( devname );
1602 }
1603
1604 // Get the device (keyword) name
1605
1606 void plstream::gdev( char *devname )
1607 {
1608 set_stream();
1609
1610 plgdev( devname );
1611 }
1612
1613 // Set window into device space using margin, aspect ratio, and
1614 // justification
1615
1616 void plstream::sdidev( PLFLT mar, PLFLT aspect, PLFLT jx, PLFLT jy )
1617 {
1618 set_stream();
1619
1620 plsdidev( mar, aspect, jx, jy );
1621 }
1622
1623 // Set up transformation from metafile coordinates.
1624
1625 void plstream::sdimap( PLINT dimxmin, PLINT dimxmax,
1626 PLINT dimymin, PLINT dimymax,
1627 PLFLT dimxpmm, PLFLT dimypmm )
1628 {
1629 set_stream();
1630
1631 plsdimap( dimxmin, dimxmax, dimymin, dimymax, dimxpmm, dimypmm );
1632 }
1633
1634 // Set plot orientation, specifying rotation in units of pi/2.
1635
1636 void plstream::sdiori( PLFLT rot )
1637 {
1638 set_stream();
1639
1640 plsdiori( rot );
1641 }
1642
1643 // Set window into plot space
1644
1645 void plstream::sdiplt( PLFLT xmin, PLFLT ymin, PLFLT xmax, PLFLT ymax )
1646 {
1647 set_stream();
1648
1649 plsdiplt( xmin, ymin, xmax, ymax );
1650 }
1651
1652 // Set window into plot space incrementally (zoom)
1653
1654 void plstream::sdiplz( PLFLT xmin, PLFLT ymin, PLFLT xmax, PLFLT ymax )
1655 {
1656 set_stream();
1657
1658 plsdiplz( xmin, ymin, xmax, ymax );
1659 }
1660
1661 // Set the escape character for text strings.
1662
1663 void plstream::sesc( char esc )
1664 {
1665 set_stream();
1666
1667 plsesc( esc );
1668 }
1669
1670 // Set the offset and spacing of contour labels
1671
1672 void plstream::setcontlabelparam( PLFLT offset, PLFLT size, PLFLT spacing,
1673 PLINT active )
1674 {
1675 set_stream();
1676
1677 pl_setcontlabelparam( offset, size, spacing, active );
1678 }
1679
1680 // Set the format of the contour labels
1681
1682 void plstream::setcontlabelformat( PLINT lexp, PLINT sigdig )
1683 {
1684 set_stream();
1685
1686 pl_setcontlabelformat( lexp, sigdig );
1687 }
1688
1689 // Set family file parameters
1690
1691 void plstream::sfam( PLINT fam, PLINT num, PLINT bmax )
1692 {
1693 set_stream();
1694
1695 plsfam( fam, num, bmax );
1696 }
1697
1698 // Set FCI (font characterization integer)
1699
1700 void plstream::sfci( PLUNICODE fci )
1701 {
1702 set_stream();
1703
1704 plsfci( fci );
1705 }
1706
1707 // Set the output file name.
1708
1709 void plstream::sfnam( const char *fnam )
1710 {
1711 set_stream();
1712
1713 plsfnam( fnam );
1714 }
1715
1716 // Set the pointer to the data used in driver initialisation
1717
1718 void plstream::sdevdata( void *data )
1719 {
1720 set_stream();
1721
1722 plsdevdata( data );
1723 }
1724
1725 // Set the current font family, style and weight
1726
1727 void plstream::sfont( PLINT family, PLINT style, PLINT weight )
1728 {
1729 set_stream();
1730
1731 plsfont( family, style, weight );
1732 }
1733
1734 // Shade region.
1735
1736 void
1737 plstream::shade( const PLFLT * const *a, PLINT nx, PLINT ny,
1738 PLDEFINED_callback defined,
1739 PLFLT left, PLFLT right, PLFLT bottom, PLFLT top,
1740 PLFLT shade_min, PLFLT shade_max,
1741 PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width,
1742 PLINT min_color, PLFLT min_width,
1743 PLINT max_color, PLFLT max_width,
1744 PLFILL_callback fill, bool rectangular,
1745 PLTRANSFORM_callback pltr, PLPointer pltr_data )
1746 {
1747 set_stream();
1748
1749 plshade( a, nx, ny, defined, left, right, bottom, top,
1750 shade_min, shade_max,
1751 sh_cmap, sh_color, sh_width,
1752 min_color, min_width, max_color, max_width,
1753 fill, (PLBOOL) rectangular, pltr, pltr_data );
1754 }
1755
1756 void
1757 plstream::shades( const PLFLT * const *a, PLINT nx, PLINT ny,
1758 PLDEFINED_callback defined,
1759 PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax,
1760 const PLFLT *clevel, PLINT nlevel, PLFLT fill_width,
1761 PLINT cont_color, PLFLT cont_width,
1762 PLFILL_callback fill, bool rectangular,
1763 PLTRANSFORM_callback pltr, PLPointer pltr_data )
1764 {
1765 set_stream();
1766
1767 plshades( a, nx, ny, defined, xmin, xmax, ymin, ymax,
1768 clevel, nlevel, fill_width, cont_color, cont_width,
1769 fill, (PLBOOL) rectangular, pltr, pltr_data );
1770 }
1771
1772 void
1773 plstream::shade( Contourable_Data & d, PLFLT xmin, PLFLT xmax,
1774 PLFLT ymin, PLFLT ymax, PLFLT shade_min, PLFLT shade_max,
1775 PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width,
1776 PLINT min_color, PLFLT min_width,
1777 PLINT max_color, PLFLT max_width,
1778 bool rectangular,
1779 Coord_Xformer *pcxf )
1780 {
1781 set_stream();
1782
1783 int nx, ny;
1784 d.elements( nx, ny );
1785
1786 if ( pcxf != NULL )
1787 ::plfshade( Contourable_Data_evaluator, &d,
1788 NULL, NULL,
1789 nx, ny,
1790 xmin, xmax, ymin, ymax, shade_min, shade_max,
1791 sh_cmap, sh_color, sh_width,
1792 min_color, min_width, max_color, max_width,
1793 plcallback::fill, rectangular,
1794 Coord_Xform_evaluator, pcxf );
1795 else
1796 ::plfshade( Contourable_Data_evaluator, &d,
1797 NULL, NULL,
1798 nx, ny,
1799 xmin, xmax, ymin, ymax, shade_min, shade_max,
1800 sh_cmap, sh_color, sh_width,
1801 min_color, min_width, max_color, max_width,
1802 plcallback::fill, rectangular,
1803 NULL, NULL );
1804 }
1805
1806 #ifdef PL_DEPRECATED
1807 void
1808 plstream::shade1( const PLFLT *a, PLINT nx, PLINT ny,
1809 PLDEFINED_callback defined,
1810 PLFLT left, PLFLT right, PLFLT bottom, PLFLT top,
1811 PLFLT shade_min, PLFLT shade_max,
1812 PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width,
1813 PLINT min_color, PLFLT min_width,
1814 PLINT max_color, PLFLT max_width,
1815 PLFILL_callback fill, bool rectangular,
1816 PLTRANSFORM_callback pltr, PLPointer pltr_data )
1817 {
1818 set_stream();
1819
1820 plshade1( a, nx, ny, defined,
1821 left, right, bottom, top,
1822 shade_min, shade_max,
1823 sh_cmap, sh_color, sh_width,
1824 min_color, min_width, max_color, max_width,
1825 fill, (PLBOOL) rectangular, pltr, pltr_data );
1826 }
1827
1828 // Deprecated version using PLINT not bool
1829 void
1830 plstream::shade1( const PLFLT *a, PLINT nx, PLINT ny,
1831 PLDEFINED_callback defined,
1832 PLFLT left, PLFLT right, PLFLT bottom, PLFLT top,
1833 PLFLT shade_min, PLFLT shade_max,
1834 PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width,
1835 PLINT min_color, PLFLT min_width,
1836 PLINT max_color, PLFLT max_width,
1837 PLFILL_callback fill, PLINT rectangular,
1838 PLTRANSFORM_callback pltr, PLPointer pltr_data )
1839 {
1840 set_stream();
1841
1842 plshade1( a, nx, ny, defined,
1843 left, right, bottom, top,
1844 shade_min, shade_max,
1845 sh_cmap, sh_color, sh_width,
1846 min_color, min_width, max_color, max_width,
1847 fill, (PLBOOL) rectangular, pltr, pltr_data );
1848 }
1849 #endif //PL_DEPRECATED
1850
1851 void
1852 plstream::fshade( PLFLT ( *f2eval )( PLINT, PLINT, PLPointer ),
1853 PLPointer f2eval_data,
1854 PLFLT ( *c2eval )( PLINT, PLINT, PLPointer ),
1855 PLPointer c2eval_data,
1856 PLINT nx, PLINT ny,
1857 PLFLT left, PLFLT right, PLFLT bottom, PLFLT top,
1858 PLFLT shade_min, PLFLT shade_max,
1859 PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width,
1860 PLINT min_color, PLFLT min_width,
1861 PLINT max_color, PLFLT max_width,
1862 PLFILL_callback fill, bool rectangular,
1863 PLTRANSFORM_callback pltr, PLPointer pltr_data )
1864 {
1865 set_stream();
1866
1867 plfshade( f2eval, f2eval_data,
1868 c2eval, c2eval_data,
1869 nx, ny, left, right, bottom, top,
1870 shade_min, shade_max,
1871 sh_cmap, sh_color, sh_width,
1872 min_color, min_width, max_color, max_width,
1873 fill, (PLBOOL) rectangular, pltr, pltr_data );
1874 }
1875
1876 // Setup a user-provided custom labeling function
1877
1878 void plstream::slabelfunc( PLLABEL_FUNC_callback label_func, PLPointer label_data )
1879 {
1880 set_stream();
1881
1882 plslabelfunc( label_func, label_data );
1883 }
1884
1885 // Set up lengths of major tick marks.
1886
1887 void plstream::smaj( PLFLT def, PLFLT scale )
1888 {
1889 set_stream();
1890
1891 plsmaj( def, scale );
1892 }
1893
1894 // Set the RGB memory area to be plotted (with the 'mem' or 'memcairo' drivers)
1895
1896 void plstream::smem( PLINT maxx, PLINT maxy, void *plotmem )
1897 {
1898 set_stream();
1899
1900 plsmem( maxx, maxy, plotmem );
1901 }
1902
1903 // Set the RGBA memory area to be plotted (with the 'memcairo' drivers)
1904
1905 void plstream::smema( PLINT maxx, PLINT maxy, void *plotmem )
1906 {
1907 set_stream();
1908
1909 plsmema( maxx, maxy, plotmem );
1910 }
1911
1912 // Set up lengths of minor tick marks.
1913
1914 void plstream::smin( PLFLT def, PLFLT scale )
1915 {
1916 set_stream();
1917
1918 plsmin( def, scale );
1919 }
1920
1921 // Set orientation. Must be done before calling plinit.
1922
1923 void plstream::sori( PLINT ori )
1924 {
1925 set_stream();
1926
1927 plsori( ori );
1928 }
1929
1930 // Set output device parameters. Usually ignored by the driver.
1931
1932 void plstream::spage( PLFLT xp, PLFLT yp, PLINT xleng, PLINT yleng,
1933 PLINT xoff, PLINT yoff )
1934 {
1935 set_stream();
1936
1937 plspage( xp, yp, xleng, yleng, xoff, yoff );
1938 }
1939
1940 // Set the colors for color table 0 from a cmap0 file
1941
1942 void plstream::spal0( const char *filename )
1943 {
1944 set_stream();
1945
1946 plspal0( filename );
1947 }
1948
1949 // Set the colors for color table 1 from a cmap1 file
1950
1951 void plstream::spal1( const char *filename, bool interpolate )
1952 {
1953 set_stream();
1954
1955 plspal1( filename, (PLBOOL) interpolate );
1956 }
1957
1958 // Set the pause (on end-of-page) status
1959
1960 void plstream::spause( bool pause )
1961 {
1962 set_stream();
1963
1964 plspause( (PLBOOL) pause );
1965 }
1966
1967 // Set stream number.
1968
1969 void plstream::sstrm( PLINT strm )
1970 {
1971 set_stream();
1972
1973 plsstrm( strm );
1974 }
1975
1976 // Set the number of subwindows in x and y
1977
1978 void plstream::ssub( PLINT nx, PLINT ny )
1979 {
1980 set_stream();
1981
1982 plssub( nx, ny );
1983 }
1984
1985 // Set symbol height.
1986
1987 void plstream::ssym( PLFLT def, PLFLT scale )
1988 {
1989 set_stream();
1990
1991 plssym( def, scale );
1992 }
1993
1994 // Initialize PLplot, passing in the windows/page settings.
1995
1996 void plstream::star( PLINT nx, PLINT ny )
1997 {
1998 set_stream();
1999
2000 plstar( nx, ny );
2001 }
2002
2003 // Initialize PLplot, passing the device name and windows/page settings.
2004
2005 void plstream::start( const char *devname, PLINT nx, PLINT ny )
2006 {
2007 set_stream();
2008
2009 plstart( devname, nx, ny );
2010 }
2011
2012 // Set the coordinate transform
2013
2014 void plstream::stransform( PLTRANSFORM_callback coordinate_transform, PLPointer coordinate_transform_data )
2015 {
2016 set_stream();
2017
2018 plstransform( coordinate_transform, coordinate_transform_data );
2019 }
2020
2021 // Prints out the same string repeatedly at the n points in world
2022 // coordinates given by the x and y arrays. Supersedes plpoin and
2023 // plsymbol for the case where text refers to a unicode glyph either
2024 // directly as UTF-8 or indirectly via the standard text escape
2025 // sequences allowed for PLplot input strings.
2026
2027 void plstream::string( PLINT n, const PLFLT *x, const PLFLT *y, const char *string )
2028 {
2029 set_stream();
2030 plstring( n, x, y, string );
2031 }
2032
2033 // Prints out the same string repeatedly at the n points in world
2034 // coordinates given by the x, y, and z arrays. Supersedes plpoin3
2035 // for the case where text refers to a unicode glyph either directly
2036 // as UTF-8 or indirectly via the standard text escape sequences
2037 // allowed for PLplot input strings.
2038
2039 void plstream::string3( PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z, const char *string )
2040 {
2041 set_stream();
2042 plstring3( n, x, y, z, string );
2043 }
2044
2045 // Create 1d stripchart
2046
2047 void plstream::stripc( PLINT *id, const char *xspec, const char *yspec,
2048 PLFLT xmin, PLFLT xmax, PLFLT xjump,
2049 PLFLT ymin, PLFLT ymax,
2050 PLFLT xlpos, PLFLT ylpos, bool y_ascl,
2051 bool acc, PLINT colbox, PLINT collab,
2052 const PLINT colline[], const PLINT styline[],
2053 const char *legline[], const char *labx,
2054 const char *laby, const char *labtop )
2055 {
2056 set_stream();
2057
2058 plstripc( id, xspec, yspec, xmin, xmax, xjump, ymin, ymax, xlpos, ylpos,
2059 (PLBOOL) y_ascl, (PLBOOL) acc, colbox, collab, colline, styline,
2060 legline, labx, laby, labtop );
2061 }
2062
2063
2064 // Add a point to a stripchart.
2065
2066 void plstream::stripa( PLINT id, PLINT pen, PLFLT x, PLFLT y )
2067 {
2068 set_stream();
2069
2070 plstripa( id, pen, x, y );
2071 }
2072
2073 // Deletes and releases memory used by a stripchart.
2074
2075 void plstream::stripd( PLINT id )
2076 {
2077 set_stream();
2078
2079 plstripd( id );
2080 }
2081
2082 // plots a 2d image (or a matrix too large for plshade() ) - colors
2083 // automatically scaled
2084
2085 void plstream::image( const PLFLT * const *data, PLINT nx, PLINT ny,
2086 PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax,
2087 PLFLT zmin, PLFLT zmax,
2088 PLFLT Dxmin, PLFLT Dxmax, PLFLT Dymin, PLFLT Dymax )
2089 {
2090 set_stream();
2091
2092 plimage( data, nx, ny, xmin, xmax, ymin, ymax, zmin, zmax,
2093 Dxmin, Dxmax, Dymin, Dymax );
2094 }
2095
2096 // plots a 2d image (or a matrix too large for plshade() )
2097
2098 void plstream::imagefr( const PLFLT * const *data, PLINT nx, PLINT ny, PLFLT xmin, PLFLT xmax,
2099 PLFLT ymin, PLFLT ymax, PLFLT zmin, PLFLT zmax,
2100 PLFLT valuemin, PLFLT valuemax,
2101 PLTRANSFORM_callback pltr, PLPointer pltr_data )
2102 {
2103 set_stream();
2104
2105 plimagefr( data, nx, ny, xmin, xmax, ymin, ymax, zmin, zmax,
2106 valuemin, valuemax, pltr, pltr_data );
2107 }
2108
2109 // Set up a new line style
2110
2111 void plstream::styl( PLINT nms, const PLINT *mark, const PLINT *space )
2112 {
2113 set_stream();
2114
2115 plstyl( nms, mark, space );
2116 }
2117
2118 // Sets the edges of the viewport to the specified absolute coordinates
2119
2120 void plstream::svpa( PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax )
2121 {
2122 set_stream();
2123
2124 plsvpa( xmin, xmax, ymin, ymax );
2125 }
2126
2127 // Set x axis labeling parameters
2128
2129 void plstream::sxax( PLINT digmax, PLINT digits )
2130 {
2131 set_stream();
2132
2133 plsxax( digmax, digits );
2134 }
2135
2136 // Set inferior X window
2137
2138 void plstream::sxwin( PLINT window_id )
2139 {
2140 set_stream();
2141
2142 plsxwin( window_id );
2143 }
2144
2145 // Set y axis labeling parameters
2146
2147 void plstream::syax( PLINT digmax, PLINT digits )
2148 {
2149 set_stream();
2150
2151 plsyax( digmax, digits );
2152 }
2153
2154 // Plots array y against x for n points using Hershey symbol "code"
2155
2156 void plstream::sym( PLINT n, const PLFLT *x, const PLFLT *y, PLINT code )
2157 {
2158 set_stream();
2159
2160 plsym( n, x, y, code );
2161 }
2162
2163 // Set z axis labeling parameters
2164
2165 void plstream::szax( PLINT digmax, PLINT digits )
2166 {
2167 set_stream();
2168
2169 plszax( digmax, digits );
2170 }
2171
2172 // Switches to text screen.
2173
2174 void plstream::text()
2175 {
2176 set_stream();
2177
2178 pltext();
2179 }
2180
2181 // Set the format for date / time labels
2182
2183 void plstream::timefmt( const char *fmt )
2184 {
2185 set_stream();
2186
2187 pltimefmt( fmt );
2188 }
2189
2190 // Sets the edges of the viewport with the given aspect ratio, leaving
2191 // room for labels.
2192
2193 void plstream::vasp( PLFLT aspect )
2194 {
2195 set_stream();
2196
2197 plvasp( aspect );
2198 }
2199
2200 // Creates the largest viewport of the specified aspect ratio that fits
2201 // within the specified normalized subpage coordinates.
2202
2203 void plstream::vpas( PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax,
2204 PLFLT aspect )
2205 {
2206 set_stream();
2207
2208 plvpas( xmin, xmax, ymin, ymax, aspect );
2209 }
2210
2211 // Creates a viewport with the specified normalized subpage coordinates.
2212
2213 void plstream::vpor( PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax )
2214 {
2215 set_stream();
2216
2217 plvpor( xmin, xmax, ymin, ymax );
2218 }
2219
2220 // Defines a "standard" viewport with seven character heights for
2221 // the left margin and four character heights everywhere else.
2222
2223 void plstream::vsta()
2224 {
2225 set_stream();
2226
2227 plvsta();
2228 }
2229
2230 // Set up a window for three-dimensional plotting.
2231
2232 void plstream::w3d( PLFLT basex, PLFLT basey, PLFLT height, PLFLT xmin0,
2233 PLFLT xmax0, PLFLT ymin0, PLFLT ymax0, PLFLT zmin0,
2234 PLFLT zmax0, PLFLT alt, PLFLT az )
2235 {
2236 set_stream();
2237
2238 plw3d( basex, basey, height, xmin0, xmax0, ymin0, ymax0, zmin0, zmax0,
2239 alt, az );
2240 }
2241
2242 // Set pen width.
2243
2244 void plstream::width( PLFLT width )
2245 {
2246 set_stream();
2247
2248 plwidth( width );
2249 }
2250
2251 // Set up world coordinates of the viewport boundaries (2d plots).
2252
2253 void plstream::wind( PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax )
2254 {
2255 set_stream();
2256
2257 plwind( xmin, xmax, ymin, ymax );
2258 }
2259
2260 // Set xor mode; mode = 1-enter, 0-leave, status = 0 if not interactive device
2261
2262 void plstream::xormod( bool mode, bool *status )
2263 {
2264 PLBOOL loc_status;
2265
2266 set_stream();
2267
2268 plxormod( (PLBOOL) mode, &loc_status );
2269
2270 *status = ( loc_status != 0 );
2271 }
2272
2273 // Set the seed for the random number generator included.
2274
2275 void plstream::seed( unsigned int s )
2276 {
2277 set_stream();
2278
2279 plseed( s );
2280 }
2281
2282 // Returns a random number on [0,1]-interval.
2283
2284 PLFLT plstream::randd( void )
2285 {
2286 set_stream();
2287
2288 return plrandd();
2289 }
2290
2291 // The rest for use from C / C++ only
2292
2293 // Returns a list of file-oriented device names and their menu strings
2294
2295 void plstream::gFileDevs( const char ***p_menustr, const char ***p_devname,
2296 int *p_ndev )
2297 {
2298 set_stream();
2299
2300 plgFileDevs( p_menustr, p_devname, p_ndev );
2301 }
2302
2303 // Set the function pointer for the keyboard event handler
2304
2305 void plstream::sKeyEH( void ( *KeyEH )( PLGraphicsIn *, void *, int * ),
2306 void *KeyEH_data )
2307 {
2308 set_stream();
2309
2310 plsKeyEH( KeyEH, KeyEH_data );
2311 }
2312
2313 // Set the variables to be used for storing error info
2314
2315 void plstream::sError( PLINT *errcode, char *errmsg )
2316 {
2317 set_stream();
2318
2319 plsError( errcode, errmsg );
2320 }
2321
2322 // Sets an optional user exit handler.
2323
2324 void plstream::sexit( int ( *handler )( const char * ) )
2325 {
2326 set_stream();
2327
2328 plsexit( handler );
2329 }
2330
2331 // We obviously won't be using this object from Fortran...
2332 // // Identity transformation for plots from Fortran.
2333
2334 // void plstream::tr0f(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void *pltr_data )
2335 // {
2336 // set_stream();
2337
2338 // pltr0f(x,y,tx,ty,pltr_data);
2339 // }
2340
2341 // // Does linear interpolation from doubly dimensioned coord arrays
2342 // // (row dominant, i.e. Fortran ordering).
2343
2344 // void plstream::tr2f( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, void *pltr_data )
2345 // {
2346 // set_stream();
2347
2348 // pltr2f(x,y,tx,ty,pltr_data);
2349 // }
2350
2351 // Example linear transformation function for contour plotter.
2352 // This is not actually a part of the core library any more
2353 //
2354 // void plstream::xform( PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty )
2355 // {
2356 // set_stream();
2357 //
2358 // xform(x,y,tx,ty);
2359 // }
2360
2361 // Function evaluators
2362
2363 // Does a lookup from a 2d function array. Array is of type (PLFLT **),
2364 // and is column dominant (normal C ordering).
2365
2366 PLFLT plstream::f2eval2( PLINT ix, PLINT iy, PLPointer plf2eval_data )
2367 {
2368 set_stream();
2369
2370 return ::plf2eval2( ix, iy, plf2eval_data );
2371 }
2372
2373 // Does a lookup from a 2d function array. Array is of type (PLFLT *),
2374 // and is column dominant (normal C ordering).
2375
2376 PLFLT plstream::f2eval( PLINT ix, PLINT iy, PLPointer plf2eval_data )
2377 {
2378 set_stream();
2379
2380 return ::plf2eval( ix, iy, plf2eval_data );
2381 }
2382
2383 // Does a lookup from a 2d function array. Array is of type (PLFLT *),
2384 // and is row dominant (Fortran ordering).
2385
2386 PLFLT plstream::f2evalr( PLINT ix, PLINT iy, PLPointer plf2eval_data )
2387 {
2388 set_stream();
2389
2390 return ::plf2evalr( ix, iy, plf2eval_data );
2391 }
2392
2393 // Command line parsing utilities
2394
2395 // Clear internal option table info structure.
2396
2397 void plstream::ClearOpts()
2398 {
2399 set_stream();
2400
2401 ::plClearOpts();
2402 }
2403
2404 // Reset internal option table info structure.
2405
2406 void plstream::ResetOpts()
2407 {
2408 set_stream();
2409
2410 ::plResetOpts();
2411 }
2412
2413 // Merge user option table into internal info structure.
2414
2415 PLINT plstream::MergeOpts( PLOptionTable *options, const char *name,
2416 const char **notes )
2417 {
2418 set_stream();
2419
2420 return ::plMergeOpts( options, name, notes );
2421 }
2422
2423 // Set the strings used in usage and syntax messages.
2424
2425 void plstream::SetUsage( char *program_string, char *usage_string )
2426 {
2427 set_stream();
2428
2429 ::plSetUsage( program_string, usage_string );
2430 }
2431
2432 // Process input strings, treating them as an option and argument pair.
2433
2434 PLINT plstream::setopt( const char *opt, const char *optarg )
2435 {
2436 set_stream();
2437
2438 return ::plsetopt( opt, optarg );
2439 }
2440
2441 // Print usage & syntax message.
2442
2443 void plstream::OptUsage()
2444 {
2445 set_stream();
2446
2447 ::plOptUsage();
2448 }
2449
2450 // Miscellaneous
2451
2452 // Set the output file pointer
2453
2454 void plstream::gfile( FILE **p_file )
2455 {
2456 set_stream();
2457
2458 ::plgfile( p_file );
2459 }
2460
2461 // Get the output file pointer
2462
2463 void plstream::sfile( FILE *file )
2464 {
2465 set_stream();
2466
2467 ::plsfile( file );
2468 }
2469
2470
2471 // Get the escape character for text strings.
2472
2473 void plstream::gesc( char *p_esc )
2474 {
2475 set_stream();
2476
2477 ::plgesc( p_esc );
2478 }
2479
2480 // Front-end to driver escape function.
2481
2482 void plstream::cmd( PLINT op, void *ptr )
2483 {
2484 set_stream();
2485
2486 ::pl_cmd( op, ptr );
2487 }
2488
2489 // Return full pathname for given file if executable
2490
2491 PLINT plstream::FindName( char *p )
2492 {
2493 set_stream();
2494
2495 return plFindName( p );
2496 }
2497
2498 // Looks for the specified executable file according to usual search path.
2499
2500 char *plstream::FindCommand( char *fn )
2501 {
2502 set_stream();
2503
2504 return plFindCommand( fn );
2505 }
2506
2507 // Gets search name for file by concatenating the dir, subdir, and file
2508 // name, allocating memory as needed.
2509
2510 void plstream::GetName( char *dir, char *subdir, char *filename,
2511 char **filespec )
2512 {
2513 set_stream();
2514
2515 plGetName( dir, subdir, filename, filespec );
2516 }
2517
2518 // Prompts human to input an integer in response to given message.
2519
2520 PLINT plstream::GetInt( char *s )
2521 {
2522 set_stream();
2523
2524 return plGetInt( s );
2525 }
2526
2527 // Prompts human to input a float in response to given message.
2528
2529 PLFLT plstream::GetFlt( char *s )
2530 {
2531 set_stream();
2532
2533 return plGetFlt( s );
2534 }
2535
2536 // Determine the Iliffe column vector of pointers to PLFLT row
2537 // vectors corresponding to a 2D matrix of PLFLT's that is statically
2538 // allocated.
2539
2540 void plstream::Static2dGrid( PLFLT_NC_MATRIX zIliffe, PLFLT_VECTOR zStatic, PLINT nx, PLINT ny )
2541 {
2542 set_stream();
2543
2544 ::plStatic2dGrid( zIliffe, zStatic, nx, ny );
2545 }
2546
2547 // Allocate a block of memory for use as a 2-d grid of PLFLT's organized
2548 // as an Iliffe column vector of pointers to PLFLT row vectors.
2549
2550 void plstream::Alloc2dGrid( PLFLT ***f, PLINT nx, PLINT ny )
2551 {
2552 set_stream();
2553
2554 ::plAlloc2dGrid( f, nx, ny );
2555 }
2556
2557 // Frees a block of memory allocated with plAlloc2dGrid().
2558
2559 void plstream::Free2dGrid( PLFLT **f, PLINT nx, PLINT ny )
2560 {
2561 set_stream();
2562
2563 ::plFree2dGrid( f, nx, ny );
2564 }
2565
2566 // Find the maximum and minimum of a 2d matrix allocated with plAllc2dGrid().
2567 void plstream::MinMax2dGrid( const PLFLT * const *f, PLINT nx, PLINT ny,
2568 PLFLT *fmax, PLFLT *fmin )
2569 {
2570 set_stream();
2571
2572 ::plMinMax2dGrid( f, nx, ny, fmax, fmin );
2573 }
2574
2575 // Functions for converting between HLS and RGB color space
2576
2577 void plstream::hlsrgb( PLFLT h, PLFLT l, PLFLT s, PLFLT *p_r, PLFLT *p_g,
2578 PLFLT *p_b )
2579 {
2580 set_stream();
2581
2582 ::c_plhlsrgb( h, l, s, p_r, p_g, p_b );
2583 }
2584
2585 void plstream::rgbhls( PLFLT r, PLFLT g, PLFLT b, PLFLT *p_h, PLFLT *p_l,
2586 PLFLT *p_s )
2587 {
2588 set_stream();
2589
2590 ::c_plrgbhls( r, g, b, p_h, p_l, p_s );
2591 }
2592
2593 // Wait for right button mouse event and translate to world coordinates
2594
2595 PLINT plstream::GetCursor( PLGraphicsIn *gin )
2596 {
2597 set_stream();
2598
2599 return plGetCursor( gin );
2600 }
2601
2602 #ifdef PL_DEPRECATED
2603 // Deprecated version using PLINT instead of bool
2604 void
2605 plstream::svect( const PLFLT *arrow_x, const PLFLT *arrow_y, PLINT npts, PLINT fill )
2606 {
2607 set_stream();
2608
2609 plsvect( arrow_x, arrow_y, npts, (PLBOOL) fill );
2610 }
2611
2612 // Deprecated version using PLINT not bool
2613 void plstream::cpstrm( plstream & pls, PLINT flags )
2614 {
2615 set_stream();
2616
2617 plcpstrm( pls.stream, (PLBOOL) flags );
2618 }
2619
2620 // Deprecated version using PLINT not bool
2621 void plstream::plot3d( const PLFLT *x, const PLFLT *y, const PLFLT * const *z,
2622 PLINT nx, PLINT ny, PLINT opt, PLINT side )
2623 {
2624 set_stream();
2625
2626 ::plot3d( x, y, z, nx, ny, opt, (PLBOOL) side );
2627 }
2628
2629 // Deprecated version using PLINT not bool
2630 void plstream::poly3( PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z,
2631 const PLINT *draw, PLINT ifcc )
2632 {
2633 PLBOOL *loc_draw = new PLBOOL[n - 1];
2634 for ( int i = 0; i < n - 1; i++ )
2635 {
2636 loc_draw[i] = (PLBOOL) draw[i];
2637 }
2638
2639 set_stream();
2640
2641 plpoly3( n, x, y, z, loc_draw, (PLBOOL) ifcc );
2642
2643 delete [] loc_draw;
2644 }
2645
2646 // Deprecated version using PLINT instead of bool
2647 void plstream::scmap1l( PLINT itype, PLINT npts, const PLFLT *intensity,
2648 const PLFLT *coord1, const PLFLT *coord2, const PLFLT *coord3,
2649 const PLINT *alt_hue_path )
2650 {
2651 PLBOOL *loc_alt_hue_path = NULL;
2652 if ( alt_hue_path != NULL )
2653 {
2654 loc_alt_hue_path = new PLBOOL[npts - 1];
2655 for ( int i = 0; i < npts - 1; i++ )
2656 {
2657 loc_alt_hue_path[i] = (PLBOOL) alt_hue_path[i];
2658 }
2659 }
2660
2661 set_stream();
2662
2663 plscmap1l( (PLBOOL) itype, npts, intensity, coord1, coord2, coord3, loc_alt_hue_path );
2664
2665 if ( loc_alt_hue_path != NULL )
2666 delete [] loc_alt_hue_path;
2667 }
2668
2669 // Deprecated version using PLINT instead of bool
2670 void
2671 plstream::shade( const PLFLT * const *a, PLINT nx, PLINT ny,
2672 PLDEFINED_callback defined,
2673 PLFLT left, PLFLT right, PLFLT bottom, PLFLT top,
2674 PLFLT shade_min, PLFLT shade_max,
2675 PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width,
2676 PLINT min_color, PLFLT min_width,
2677 PLINT max_color, PLFLT max_width,
2678 PLFILL_callback fill, PLINT rectangular,
2679 PLTRANSFORM_callback pltr, PLPointer pltr_data )
2680 {
2681 set_stream();
2682
2683 plshade( a, nx, ny, defined, left, right, bottom, top,
2684 shade_min, shade_max,
2685 sh_cmap, sh_color, sh_width,
2686 min_color, min_width, max_color, max_width,
2687 fill, (PLBOOL) rectangular, pltr, pltr_data );
2688 }
2689
2690 // Deprecated version using PLINT instead of bool
2691 void
2692 plstream::shades( const PLFLT * const *a, PLINT nx, PLINT ny,
2693 PLDEFINED_callback defined,
2694 PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax,
2695 const PLFLT *clevel, PLINT nlevel, PLFLT fill_width,
2696 PLINT cont_color, PLFLT cont_width,
2697 PLFILL_callback fill, PLINT rectangular,
2698 PLTRANSFORM_callback pltr, PLPointer pltr_data )
2699 {
2700 set_stream();
2701
2702 plshades( a, nx, ny, defined, xmin, xmax, ymin, ymax,
2703 clevel, nlevel, fill_width, cont_color, cont_width,
2704 fill, (PLBOOL) rectangular, pltr, pltr_data );
2705 }
2706
2707 // Deprecated version using PLINT not bool
2708 void
2709 plstream::shade( Contourable_Data & d, PLFLT xmin, PLFLT xmax,
2710 PLFLT ymin, PLFLT ymax, PLFLT shade_min, PLFLT shade_max,
2711 PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width,
2712 PLINT min_color, PLFLT min_width,
2713 PLINT max_color, PLFLT max_width,
2714 PLINT rectangular,
2715 Coord_Xformer *pcxf )
2716 {
2717 set_stream();
2718
2719 int nx, ny;
2720 d.elements( nx, ny );
2721
2722 ::plfshade( Contourable_Data_evaluator, &d,
2723 NULL, NULL,
2724 nx, ny,
2725 xmin, xmax, ymin, ymax, shade_min, shade_max,
2726 sh_cmap, sh_color, sh_width,
2727 min_color, min_width, max_color, max_width,
2728 plcallback::fill, rectangular != 0,
2729 Coord_Xform_evaluator, pcxf );
2730 }
2731
2732 // Deprecated version using PLINT not bool
2733 void
2734 plstream::fshade( PLFLT ( *f2eval )( PLINT, PLINT, PLPointer ),
2735 PLPointer f2eval_data,
2736 PLFLT ( *c2eval )( PLINT, PLINT, PLPointer ),
2737 PLPointer c2eval_data,
2738 PLINT nx, PLINT ny,
2739 PLFLT left, PLFLT right, PLFLT bottom, PLFLT top,
2740 PLFLT shade_min, PLFLT shade_max,
2741 PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width,
2742 PLINT min_color, PLFLT min_width,
2743 PLINT max_color, PLFLT max_width,
2744 PLFILL_callback fill, PLINT rectangular,
2745 PLTRANSFORM_callback pltr, PLPointer pltr_data )
2746 {
2747 set_stream();
2748
2749 plfshade( f2eval, f2eval_data,
2750 c2eval, c2eval_data,
2751 nx, ny, left, right, bottom, top,
2752 shade_min, shade_max,
2753 sh_cmap, sh_color, sh_width,
2754 min_color, min_width, max_color, max_width,
2755 fill, (PLBOOL) rectangular, pltr, pltr_data );
2756 }
2757
2758 // Deprecated version using PLINT not bool
2759 void plstream::spause( PLINT pause )
2760 {
2761 set_stream();
2762
2763 plspause( (PLBOOL) pause );
2764 }
2765
2766 // Deprecated version using PLINT not bool
2767 void plstream::stripc( PLINT *id, const char *xspec, const char *yspec,
2768 PLFLT xmin, PLFLT xmax, PLFLT xjump,
2769 PLFLT ymin, PLFLT ymax, PLFLT xlpos, PLFLT ylpos,
2770 PLINT y_ascl, PLINT acc, PLINT colbox, PLINT collab,
2771 const PLINT colline[], const PLINT styline[],
2772 const char *legline[], const char *labx,
2773 const char *laby, const char *labtop )
2774 {
2775 set_stream();
2776
2777 plstripc( id, xspec, yspec, xmin, xmax, xjump, ymin, ymax, xlpos, ylpos,
2778 (PLBOOL) y_ascl, (PLBOOL) acc, colbox, collab, colline, styline,
2779 legline, labx, laby, labtop );
2780 }
2781
2782 // Deprecated version using PLINT not bool
2783 void plstream::xormod( PLINT mode, PLINT *status )
2784 {
2785 PLBOOL loc_status;
2786
2787 set_stream();
2788
2789 plxormod( (PLBOOL) mode, &loc_status );
2790
2791 *status = (PLINT) loc_status;
2792 }
2793
2794 #endif //PL_DEPRECATED
2795 //--------------------------------------------------------------------------
2796 // end of plstream.cc
2797 //--------------------------------------------------------------------------
PLS::Current
Definition: plstream.h:39
plsfam
#define plsfam
Definition: plplot.h:816
plplotc.plClearOpts
def plClearOpts
Definition: plplotc.py:8448
plw3d
#define plw3d
Definition: plplot.h:862
plf2evalr
PLFLT plf2evalr(PLINT ix, PLINT iy, PLPointer plf2eval_data)
Definition: plcont.c:466
plMergeOpts
PLINT plMergeOpts(PLOptionTable *options, PLCHAR_VECTOR name, PLCHAR_VECTOR *notes)
Definition: plargs.c:783
plsdevdata
void plsdevdata(void *data)
Definition: plcore.c:3844
plstream::spal1
void spal1(const char *filename, bool interpolate=true)
Definition: plstream.cc:1951
name
static const char * name
Definition: tkMain.c:135
plpath
#define plpath
Definition: plplot.h:761
plstream::adv
void adv(PLINT page)
Definition: plstream.cc:365
plstream::plstream
plstream(void)
Definition: plstream.cc:289
argv
static char ** argv
Definition: qt.cpp:49
plgxax
#define plgxax
Definition: plplot.h:748
plstream::clear
void clear(void)
Definition: plstream.cc:474
plgesc
void plgesc(char *p_esc)
Definition: plcore.c:3914
plsstrm
#define plsstrm
Definition: plplot.h:835
plstream::parseopts
PLINT parseopts(int *p_argc, char **argv, PLINT mode)
Definition: plstream.cc:1279
plGetCursor
PLINT plGetCursor(PLGraphicsIn *plg)
Definition: plpage.c:244
plstream::vpor
void vpor(PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax)
Definition: plstream.cc:2213
plGetInt
PLINT plGetInt(PLCHAR_VECTOR s)
Definition: plctrl.c:2910
plstream::poin
void poin(PLINT n, const PLFLT *x, const PLFLT *y, PLINT code)
Definition: plstream.cc:1306
plstream::stripd
void stripd(PLINT id)
Definition: plstream.cc:2075
PLTRANSFORM_callback
void(* PLTRANSFORM_callback)(PLFLT x, PLFLT y, PLFLT_NC_SCALAR xp, PLFLT_NC_SCALAR yp, PLPointer data)
Definition: plplot.h:257
plstream::cmd
void cmd(PLINT op, void *ptr)
Definition: plstream.cc:2482
plspage
#define plspage
Definition: plplot.h:831
plstream::btime
void btime(PLINT &year, PLINT &month, PLINT &day, PLINT &hour, PLINT &min, PLFLT &sec, PLFLT ctime)
Definition: plstream.cc:454
plGetName
void plGetName(PLCHAR_VECTOR dir, PLCHAR_VECTOR subdir, PLCHAR_VECTOR filename, char **filespec)
Definition: plctrl.c:2453
plvpor
#define plvpor
Definition: plplot.h:860
plFindName
PLINT plFindName(char *p)
Definition: plctrl.c:2432
plstream::scolbg
void scolbg(PLINT r, PLINT g, PLINT b)
Definition: plstream.cc:1561
plstream::rgbhls
void rgbhls(PLFLT r, PLFLT g, PLFLT b, PLFLT *p_h, PLFLT *p_l, PLFLT *p_s)
Definition: plstream.cc:2585
plstream::erry
void erry(PLINT n, const PLFLT *x, const PLFLT *ymin, const PLFLT *ymax)
Definition: plstream.cc:667
plstream::imagefr
void imagefr(const PLFLT *const *data, PLINT nx, PLINT ny, PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax, PLFLT zmin, PLFLT zmax, PLFLT valuemin, PLFLT valuemax, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plstream.cc:2098
c_plssub
void c_plssub(PLINT nx, PLINT ny)
Definition: plcore.c:3617
plmtex3
#define plmtex3
Definition: plplot.h:774
plerry
#define plerry
Definition: plplot.h:715
plstream::svect
void svect(const PLFLT *arrow_x=NULL, const PLFLT *arrow_y=NULL, PLINT npts=0, bool fill=false)
Definition: plstream.cc:391
Contourable_Data
Definition: plstream.h:50
plsyax
#define plsyax
Definition: plplot.h:852
plschr
#define plschr
Definition: plplot.h:790
plsdev
#define plsdev
Definition: plplot.h:806
PLFILL_callback
void(* PLFILL_callback)(PLINT n, PLFLT_VECTOR x, PLFLT_VECTOR y)
Definition: plplot.h:260
plstream::box
void box(const char *xopt, PLFLT xtick, PLINT nxsub, const char *yopt, PLFLT ytick, PLINT nysub)
Definition: plstream.cc:430
plgdev
#define plgdev
Definition: plplot.h:729
plstream::gdiplt
void gdiplt(PLFLT &xmin, PLFLT &ymin, PLFLT &xmax, PLFLT &ymax)
Definition: plstream.cc:802
plstream::f2evalr
PLFLT f2evalr(PLINT ix, PLINT iy, PLPointer plf2eval_data)
Definition: plstream.cc:2386
cxx_pltr2::xform
void xform(PLFLT x, PLFLT y, PLFLT &tx, PLFLT &ty) const
Definition: plstream.cc:81
min
int min(int a, int b)
Definition: plplot_octaveOCTAVE_wrap.cxx:2496
plstream::map
void map(PLMAPFORM_callback mapform, const char *name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy)
Definition: plstream.cc:1098
pllegend
#define pllegend
Definition: plplot.h:758
plf2eval
PLFLT plf2eval(PLINT ix, PLINT iy, PLPointer plf2eval_data)
Definition: plcont.c:447
mapform
void mapform(PLINT n, PLFLT *x, PLFLT *y)
Definition: tclAPI.c:3693
c_plgstrm
void c_plgstrm(PLINT *p_strm)
Definition: plcore.c:2652
plstream::sesc
void sesc(char esc)
Definition: plstream.cc:1663
plstream::SetUsage
void SetUsage(char *program_string, char *usage_string)
Definition: plstream.cc:2425
plstream::vect
void vect(const PLFLT *const *u, const PLFLT *const *v, PLINT nx, PLINT ny, PLFLT scale, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plstream.cc:382
pldid2pc
void pldid2pc(PLFLT *xmin, PLFLT *ymin, PLFLT *xmax, PLFLT *ymax)
Definition: plcore.c:1691
plshade
#define plshade
Definition: plplot.h:820
plscompression
#define plscompression
Definition: plplot.h:805
plarc
#define plarc
Definition: plplot.h:693
PLUNICODE
PLUINT PLUNICODE
Definition: plplot.h:201
plstream::griddata
void griddata(const PLFLT *x, const PLFLT *y, const PLFLT *z, PLINT npts, const PLFLT *xg, PLINT nptsx, const PLFLT *yg, PLINT nptsy, PLFLT **zg, PLINT type, PLFLT data)
Definition: plstream.cc:884
plot3dc
#define plot3dc
Definition: plplot.h:776
plstream::Static2dGrid
void Static2dGrid(PLFLT_NC_MATRIX zIliffe, PLFLT_VECTOR zStatic, PLINT nx, PLINT ny)
Definition: plstream.cc:2540
plot3dcl
#define plot3dcl
Definition: plplot.h:777
pllsty
#define pllsty
Definition: plplot.h:763
plstream::ssub
void ssub(PLINT nx, PLINT ny)
Definition: plstream.cc:1978
PLS::Specific
Definition: plstream.h:39
plstream::gcmap1_range
void gcmap1_range(PLFLT &min_color, PLFLT &max_color)
Definition: plstream.cc:1436
plsmin
#define plsmin
Definition: plplot.h:829
plwind
#define plwind
Definition: plplot.h:864
plclear
#define plclear
Definition: plplot.h:701
plfill
#define plfill
Definition: plplot.h:717
plconfigtime
#define plconfigtime
Definition: plplot.h:705
c_plend
void c_plend(void)
Definition: plcore.c:2484
plstream::GetInt
PLINT GetInt(char *s)
Definition: plstream.cc:2520
plstream::scmap0
void scmap0(const PLINT *r, const PLINT *g, const PLINT *b, PLINT ncol0)
Definition: plstream.cc:1445
plstream::col0
void col0(PLINT icol0)
Definition: plstream.cc:483
plstream::pat
void pat(PLINT nlin, const PLINT *inc, const PLINT *del)
Definition: plstream.cc:1288
plstream::cpstrm
void cpstrm(plstream &pls, bool flags)
Definition: plstream.cc:569
plstream::wind
void wind(PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax)
Definition: plstream.cc:2253
plsurf3dl
#define plsurf3dl
Definition: plplot.h:848
plf2eval2
PLFLT plf2eval2(PLINT ix, PLINT iy, PLPointer plf2eval_data)
Definition: plcont.c:428
plstream::sfnam
void sfnam(const char *fnam)
Definition: plstream.cc:1709
plstream::path
void path(PLINT n, PLFLT x1, PLFLT y1, PLFLT x2, PLFLT y2)
Definition: plstream.cc:1297
cxx_pltr2::cxx_pltr2
cxx_pltr2(Coord_2d &cx, Coord_2d &cy)
Definition: plstream.cc:61
plstream::smema
void smema(PLINT maxx, PLINT maxy, void *plotmem)
Definition: plstream.cc:1905
plmapline
void plmapline(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT_VECTOR plotentries, PLINT nplotentries)
Definition: plmap.c:594
plbtime
#define plbtime
Definition: plplot.h:699
pl_setcontlabelparam
#define pl_setcontlabelparam
Definition: plplot.h:691
plstream::gspa
void gspa(PLFLT &xmin, PLFLT &xmax, PLFLT &ymin, PLFLT &ymax)
Definition: plstream.cc:895
c_plend1
void c_plend1(void)
Definition: plcore.c:2542
c_plsdev
void c_plsdev(PLCHAR_VECTOR devname)
Definition: plcore.c:3640
plstream::randd
PLFLT randd(void)
Definition: plstream.cc:2284
plcallback::tr0
PLDLLIMPEXP_CXX void tr0(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer pltr_data)
Definition: plstream.cc:255
plstream::FindCommand
char * FindCommand(char *fn)
Definition: plstream.cc:2500
plstream::sdevdata
void sdevdata(void *data)
Definition: plstream.cc:1718
plscolbg
#define plscolbg
Definition: plplot.h:802
plstream::sori
void sori(PLINT ori)
Definition: plstream.cc:1923
plfont
#define plfont
Definition: plplot.h:720
c_plsfnam
void c_plsfnam(PLCHAR_VECTOR fnam)
Definition: plcore.c:3830
plstyl
#define plstyl
Definition: plplot.h:846
cxx_pltr2::yg
Coord_2d & yg
Definition: plstream.h:79
plpoly3
#define plpoly3
Definition: plplot.h:782
plstream::gfile
void gfile(FILE **p_file)
Definition: plstream.cc:2454
plstream::sfile
void sfile(FILE *file)
Definition: plstream.cc:2463
plimage
#define plimage
Definition: plplot.h:753
plstream::did2pc
void did2pc(PLFLT &xmin, PLFLT &ymin, PLFLT &xmax, PLFLT &ymax)
Definition: plstream.cc:588
Coord_2d::elements
virtual void elements(int &_nx, int &_ny)=0
plstream::setcontlabelformat
void setcontlabelformat(PLINT lexp, PLINT sigdig)
Definition: plstream.cc:1682
plfontld
#define plfontld
Definition: plplot.h:721
PLOptionTable
Definition: plplot.h:395
plscolbga
#define plscolbga
Definition: plplot.h:803
plstream::image
void image(const PLFLT *const *data, PLINT nx, PLINT ny, PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax, PLFLT zmin, PLFLT zmax, PLFLT Dxmin, PLFLT Dxmax, PLFLT Dymin, PLFLT Dymax)
Definition: plstream.cc:2085
plstream::sdidev
void sdidev(PLFLT mar, PLFLT aspect, PLFLT jx, PLFLT jy)
Definition: plstream.cc:1616
plbin
#define plbin
Definition: plplot.h:695
plTranslateCursor
PLINT plTranslateCursor(PLGraphicsIn *plg)
Definition: plpage.c:259
plsdiori
#define plsdiori
Definition: plplot.h:809
plstream::stripc
void stripc(PLINT *id, const char *xspec, const char *yspec, PLFLT xmin, PLFLT xmax, PLFLT xjump, PLFLT ymin, PLFLT ymax, PLFLT xlpos, PLFLT ylpos, bool y_ascl, bool acc, PLINT colbox, PLINT collab, const PLINT colline[], const PLINT styline[], const char *legline[], const char *labx, const char *laby, const char *labtop)
Definition: plstream.cc:2047
plstream::surf3d
void surf3d(const PLFLT *x, const PLFLT *y, const PLFLT *const *z, PLINT nx, PLINT ny, PLINT opt, const PLFLT *clevel, PLINT nlevel)
Definition: plstream.cc:1217
plstream::line
void line(PLINT n, const PLFLT *x, const PLFLT *y)
Definition: plstream.cc:1071
plstream::fill
void fill(PLINT n, const PLFLT *x, const PLFLT *y)
Definition: plstream.cc:685
plmeridians
void plmeridians(PLMAPFORM_callback mapform, PLFLT dlong, PLFLT dlat, PLFLT minlong, PLFLT maxlong, PLFLT minlat, PLFLT maxlat)
Definition: plmap.c:708
plparseopts
#define plparseopts
Definition: plplot.h:778
plmaptex
void plmaptex(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT dx, PLFLT dy, PLFLT just, PLCHAR_VECTOR text, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT plotentry)
Definition: plmap.c:639
plsym
#define plsym
Definition: plplot.h:853
plstream::gcompression
void gcompression(PLINT &compression)
Definition: plstream.cc:775
plscmap1
#define plscmap1
Definition: plplot.h:794
std
plstream::vsta
void vsta(void)
Definition: plstream.cc:2223
plinit
#define plinit
Definition: plplot.h:755
plstream::join
void join(PLFLT x1, PLFLT y1, PLFLT x2, PLFLT y2)
Definition: plstream.cc:995
plsfile
void plsfile(FILE *file)
Definition: plcore.c:3802
plctime
#define plctime
Definition: plplot.h:708
pltimefmt
#define pltimefmt
Definition: plplot.h:856
plscmap1n
#define plscmap1n
Definition: plplot.h:798
pldip2dc
void pldip2dc(PLFLT *xmin, PLFLT *ymin, PLFLT *xmax, PLFLT *ymax)
Definition: plcore.c:1737
plbop
#define plbop
Definition: plplot.h:696
plplotc.pltr0
def pltr0
Definition: plplotc.py:101
plstream::plot3d
void plot3d(const PLFLT *x, const PLFLT *y, const PLFLT *const *z, PLINT nx, PLINT ny, PLINT opt, bool side)
Definition: plstream.cc:1243
plsdiplt
#define plsdiplt
Definition: plplot.h:810
plsvect
#define plsvect
Definition: plplot.h:849
plscmap1a
#define plscmap1a
Definition: plplot.h:795
plssub
#define plssub
Definition: plplot.h:836
Coord_Xformer
Definition: plstream.h:61
plstream::env0
void env0(PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax, PLINT just, PLINT axis)
Definition: plstream.cc:639
c_plmkstrm
void c_plmkstrm(PLINT *p_strm)
Definition: plcore.c:2671
PLDEFINED_callback
PLINT(* PLDEFINED_callback)(PLFLT x, PLFLT y)
Definition: plplot.h:261
PLPointer
void * PLPointer
Definition: plplot.h:209
plspal1
#define plspal1
Definition: plplot.h:833
plsetopt
#define plsetopt
Definition: plplot.h:815
plmeshc
#define plmeshc
Definition: plplot.h:771
plgcompression
#define plgcompression
Definition: plplot.h:728
plszax
#define plszax
Definition: plplot.h:854
plvsta
#define plvsta
Definition: plplot.h:861
Coord_Xformer::xform
virtual void xform(PLFLT ox, PLFLT oy, PLFLT &nx, PLFLT &ny) const =0
plstream::shade
void shade(const PLFLT *const *a, PLINT nx, PLINT ny, PLDEFINED_callback defined, PLFLT left, PLFLT right, PLFLT bottom, PLFLT top, PLFLT shade_min, PLFLT shade_max, PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width, PLINT min_color, PLFLT min_width, PLINT max_color, PLFLT max_width, PLFILL_callback fill, bool rectangular, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plstream.cc:1737
plstream::scol0a
void scol0a(PLINT icol0, PLINT r, PLINT g, PLINT b, PLFLT a)
Definition: plstream.cc:1552
plgpage
#define plgpage
Definition: plplot.h:739
plaxes
#define plaxes
Definition: plplot.h:694
plsori
#define plsori
Definition: plplot.h:830
plstream::sfont
void sfont(PLINT family, PLINT style, PLINT weight)
Definition: plstream.cc:1727
plsError
void plsError(PLINT *errcode, char *errmsg)
Definition: plcore.c:3753
sid
static int sid
Definition: plstripc.c:44
plstream::sKeyEH
void sKeyEH(void(*KeyEH)(PLGraphicsIn *, void *, int *), void *KeyEH_data)
Definition: plstream.cc:2305
plstream::width
void width(PLFLT width)
Definition: plstream.cc:2244
plstream::seed
void seed(unsigned int s)
Definition: plstream.cc:2275
plstream::scolbga
void scolbga(PLINT r, PLINT g, PLINT b, PLFLT a)
Definition: plstream.cc:1570
plgdiplt
#define plgdiplt
Definition: plplot.h:732
plscmap0a
#define plscmap0a
Definition: plplot.h:792
plstream::scompression
void scompression(PLINT compression)
Definition: plstream.cc:1588
plstream::mapline
void mapline(PLMAPFORM_callback mapform, const char *name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, const PLINT *plotentries, PLINT nplotentries)
Definition: plstream.cc:1109
plstream::ResetOpts
void ResetOpts(void)
Definition: plstream.cc:2406
cxx_pltr2::xg
Coord_2d & xg
Definition: plstream.h:78
plfamadv
#define plfamadv
Definition: plplot.h:716
plstream::gfci
void gfci(PLUNICODE &pfci)
Definition: plstream.cc:811
plstream::plot3dc
void plot3dc(const PLFLT *x, const PLFLT *y, const PLFLT *const *z, PLINT nx, PLINT ny, PLINT opt, const PLFLT *clevel, PLINT nlevel)
Definition: plstream.cc:1253
plstream::fcont
void fcont(PLFLT(*f2eval)(PLINT, PLINT, PLPointer), PLPointer f2eval_data, PLINT nx, PLINT ny, PLINT kx, PLINT lx, PLINT ky, PLINT ly, const PLFLT *clevel, PLINT nlevel, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plstream.cc:554
plsmem
#define plsmem
Definition: plplot.h:827
plgfont
#define plgfont
Definition: plplot.h:737
plplotc.plSetUsage
def plSetUsage
Definition: plplotc.py:8456
color
static int color
Definition: ps.c:78
plstream::svpa
void svpa(PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax)
Definition: plstream.cc:2120
PLINT
int PLINT
Definition: plplot.h:181
plenv0
#define plenv0
Definition: plplot.h:712
plgdiori
#define plgdiori
Definition: plplot.h:731
plstream.h
plshades
#define plshades
Definition: plplot.h:824
PLBOOL
PLINT PLBOOL
Definition: plplot.h:204
plstream::mtex3
void mtex3(const char *side, PLFLT disp, PLFLT pos, PLFLT just, const char *text)
Definition: plstream.cc:1207
plstream::configtime
void configtime(PLFLT scale, PLFLT offset1, PLFLT offset2, PLINT ccontrol, PLBOOL ifbtime_offset, PLINT year, PLINT month, PLINT day, PLINT hour, PLINT min, PLFLT sec)
Definition: plstream.cc:524
plstream::shades
void shades(const PLFLT *const *a, PLINT nx, PLINT ny, PLDEFINED_callback defined, PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax, const PLFLT *clevel, PLINT nlevel, PLFLT fill_width, PLINT cont_color, PLFLT cont_width, PLFILL_callback fill, bool rectangular, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plstream.cc:1757
plssym
#define plssym
Definition: plplot.h:837
plstream::sstrm
void sstrm(PLINT strm)
Definition: plstream.cc:1969
plstream::sxax
void sxax(PLINT digmax, PLINT digits)
Definition: plstream.cc:2129
pljoin
#define pljoin
Definition: plplot.h:756
plgzax
#define plgzax
Definition: plplot.h:750
plstream::scmap1
void scmap1(const PLINT *r, const PLINT *g, const PLINT *b, PLINT ncol1)
Definition: plstream.cc:1463
plstream::scolor
void scolor(PLINT color)
Definition: plstream.cc:1579
plstream::gesc
void gesc(char *p_esc)
Definition: plstream.cc:2473
plstream::gvpw
void gvpw(PLFLT &xmin, PLFLT &xmax, PLFLT &ymin, PLFLT &ymax)
Definition: plstream.cc:933
plstream::w3d
void w3d(PLFLT basex, PLFLT basey, PLFLT height, PLFLT xmin0, PLFLT xmax0, PLFLT ymin0, PLFLT ymax0, PLFLT zmin0, PLFLT zmax0, PLFLT alt, PLFLT az)
Definition: plstream.cc:2232
plgfam
#define plgfam
Definition: plplot.h:734
plgdidev
#define plgdidev
Definition: plplot.h:730
plstream::poly3
void poly3(PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z, const bool *draw, bool ifcc)
Definition: plstream.cc:1324
plstream::errx
void errx(PLINT n, const PLFLT *xmin, const PLFLT *xmax, const PLFLT *y)
Definition: plstream.cc:658
plstream::text
void text(void)
Definition: plstream.cc:2174
plstar
#define plstar
Definition: plplot.h:838
plstream::~plstream
virtual ~plstream(void)
Definition: plstream.cc:348
plcpstrm
#define plcpstrm
Definition: plplot.h:707
plimagefr
#define plimagefr
Definition: plplot.h:754
plcalc_world
#define plcalc_world
Definition: plplot.h:700
plstream::spage
void spage(PLFLT xp, PLFLT yp, PLINT xleng, PLINT yleng, PLINT xoff, PLINT yoff)
Definition: plstream.cc:1932
plstream::mapstring
void mapstring(PLMAPFORM_callback mapform, const char *name, const char *string, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, const PLINT *plotentries, PLINT nplotentries)
Definition: plstream.cc:1120
plsfnam
#define plsfnam
Definition: plplot.h:818
plstream::gchr
void gchr(PLFLT &p_def, PLFLT &p_ht)
Definition: plstream.cc:730
plstream::ssym
void ssym(PLFLT def, PLFLT scale)
Definition: plstream.cc:1987
plhist
#define plhist
Definition: plplot.h:751
plstream::eop
void eop(void)
Definition: plstream.cc:649
plstream::plot3dcl
void plot3dcl(const PLFLT *x, const PLFLT *y, const PLFLT *const *z, PLINT nx, PLINT ny, PLINT opt, const PLFLT *clevel, PLINT nlevel, PLINT ixstart, PLINT ixn, const PLINT *indexymin, const PLINT *indexymax)
Definition: plstream.cc:1265
plstream::gcolbg
void gcolbg(PLINT &r, PLINT &g, PLINT &b)
Definition: plstream.cc:757
plstream::scmap1a
void scmap1a(const PLINT *r, const PLINT *g, const PLINT *b, const PLFLT *a, PLINT ncol1)
Definition: plstream.cc:1472
plstream::smem
void smem(PLINT maxx, PLINT maxy, void *plotmem)
Definition: plstream.cc:1896
plstream::col1
void col1(PLFLT c)
Definition: plstream.cc:501
plstream::scmap1n
void scmap1n(PLINT ncol1)
Definition: plstream.cc:1418
plgchr
#define plgchr
Definition: plplot.h:722
plstream::glevel
void glevel(PLINT &p_level)
Definition: plstream.cc:847
plsdidev
#define plsdidev
Definition: plplot.h:807
plstream::bop
void bop(void)
Definition: plstream.cc:421
plspal0
#define plspal0
Definition: plplot.h:832
c_plhlsrgb
void c_plhlsrgb(PLFLT h, PLFLT l, PLFLT s, PLFLT *p_r, PLFLT *p_g, PLFLT *p_b)
Definition: plctrl.c:1261
plstream::mtex
void mtex(const char *side, PLFLT disp, PLFLT pos, PLFLT just, const char *text)
Definition: plstream.cc:1197
plFree2dGrid
void plFree2dGrid(PLFLT **f, PLINT nx, PLINT PL_UNUSED(ny))
Definition: plmem.c:116
plfill3
#define plfill3
Definition: plplot.h:718
plsmema
#define plsmema
Definition: plplot.h:828
c_plsstrm
void c_plsstrm(PLINT strm)
Definition: plcore.c:2621
c_plflush
void c_plflush(void)
Definition: plcore.c:2230
plstream::meshc
void meshc(const PLFLT *x, const PLFLT *y, const PLFLT *const *z, PLINT nx, PLINT ny, PLINT opt, const PLFLT *clevel, PLINT nlevel)
Definition: plstream.cc:1178
plseed
#define plseed
Definition: plplot.h:813
plplotc.plOptUsage
def plOptUsage
Definition: plplotc.py:8460
plstring
#define plstring
Definition: plplot.h:841
plstransform
#define plstransform
Definition: plplot.h:840
plvect
#define plvect
Definition: plplot.h:858
plstream::GetFlt
PLFLT GetFlt(char *s)
Definition: plstream.cc:2529
plstream::sdiori
void sdiori(PLFLT rot)
Definition: plstream.cc:1636
plstream::surf3dl
void surf3dl(const PLFLT *x, const PLFLT *y, const PLFLT *const *z, PLINT nx, PLINT ny, PLINT opt, const PLFLT *clevel, PLINT nlevel, PLINT ixstart, PLINT ixn, const PLINT *indexymin, const PLINT *indexymax)
Definition: plstream.cc:1229
plstream::star
void star(PLINT nx, PLINT ny)
Definition: plstream.cc:1996
plstream::gfam
void gfam(PLINT &fam, PLINT &num, PLINT &bmax)
Definition: plstream.cc:820
plplotc.plResetOpts
def plResetOpts
Definition: plplotc.py:8452
plscmap1la
#define plscmap1la
Definition: plplot.h:797
plgfnam
#define plgfnam
Definition: plplot.h:736
plstream::sfci
void sfci(PLUNICODE fci)
Definition: plstream.cc:1700
plFindCommand
char * plFindCommand(PLCHAR_VECTOR fn)
Definition: plctrl.c:2146
plcont
#define plcont
Definition: plplot.h:706
plsxax
#define plsxax
Definition: plplot.h:851
plstream::syax
void syax(PLINT digmax, PLINT digits)
Definition: plstream.cc:2147
plstart
#define plstart
Definition: plplot.h:839
plstream::prec
void prec(PLINT setp, PLINT prec)
Definition: plstream.cc:1342
pleop
#define pleop
Definition: plplot.h:713
plmesh
#define plmesh
Definition: plplot.h:770
plstream
Definition: plstream.h:121
plstream::gxax
void gxax(PLINT &digmax, PLINT &digits)
Definition: plstream.cc:942
plstream::styl
void styl(PLINT nms, const PLINT *mark, const PLINT *space)
Definition: plstream.cc:2111
plsmaj
#define plsmaj
Definition: plplot.h:826
c_plrgbhls
void c_plrgbhls(PLFLT r, PLFLT g, PLFLT b, PLFLT *p_h, PLFLT *p_l, PLFLT *p_s)
Definition: plctrl.c:1294
plstream::stream
PLINT stream
Definition: plstream.h:122
plcol1
#define plcol1
Definition: plplot.h:703
c_plscolbg
void c_plscolbg(PLINT r, PLINT g, PLINT b)
Definition: plctrl.c:229
pllab
#define pllab
Definition: plplot.h:757
pllightsource
#define pllightsource
Definition: plplot.h:759
plbox
#define plbox
Definition: plplot.h:697
pl_cmd
void pl_cmd(PLINT op, void *ptr)
Definition: plctrl.c:2118
plstream::sfam
void sfam(PLINT fam, PLINT num, PLINT bmax)
Definition: plstream.cc:1691
plstream::stripa
void stripa(PLINT id, PLINT pen, PLFLT x, PLFLT y)
Definition: plstream.cc:2066
plstream::scmap0a
void scmap0a(const PLINT *r, const PLINT *g, const PLINT *b, const PLFLT *a, PLINT ncol0)
Definition: plstream.cc:1454
plgFileDevs
void plgFileDevs(const char ***p_menustr, const char ***p_devname, int *p_ndev)
Definition: plcore.c:3530
plstream::fshade
void fshade(PLFLT(*f2eval)(PLINT, PLINT, PLPointer), PLPointer f2eval_data, PLFLT(*c2eval)(PLINT, PLINT, PLPointer), PLPointer c2eval_data, PLINT nx, PLINT ny, PLFLT left, PLFLT right, PLFLT bottom, PLFLT top, PLFLT shade_min, PLFLT shade_max, PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width, PLINT min_color, PLFLT min_width, PLINT max_color, PLFLT max_width, PLFILL_callback fill, bool rectangular, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plstream.cc:1852
pltext
#define pltext
Definition: plplot.h:855
plstream::gfnam
void gfnam(char *fnam)
Definition: plstream.cc:829
plwidth
#define plwidth
Definition: plplot.h:863
plgver
#define plgver
Definition: plplot.h:745
plstream::ctime
void ctime(PLINT year, PLINT month, PLINT day, PLINT hour, PLINT min, PLFLT sec, PLFLT &ctime)
Definition: plstream.cc:577
plscol0a
#define plscol0a
Definition: plplot.h:801
plptex3
#define plptex3
Definition: plplot.h:786
plsexit
void plsexit(int(*handler)(PLCHAR_VECTOR))
Definition: plctrl.c:1987
Coord_Xform_evaluator
void Coord_Xform_evaluator(PLFLT ox, PLFLT oy, PLFLT *nx, PLFLT *ny, PLPointer p)
Definition: plstream.cc:50
plstream::vasp
void vasp(PLFLT aspect)
Definition: plstream.cc:2193
plsdiplz
#define plsdiplz
Definition: plplot.h:811
plstream::sdev
void sdev(const char *devname)
Definition: plstream.cc:1597
Contourable_Data::elements
virtual void elements(int &nx, int &ny) const
Definition: plstream.h:54
pls
static PLStream * pls[PL_NSTREAMS]
Definition: plcore.h:88
PLS::stream_id
stream_id
Definition: plstream.h:39
plspause
#define plspause
Definition: plplot.h:834
plstream::gyax
void gyax(PLINT &digmax, PLINT &digits)
Definition: plstream.cc:951
plstream::bin
void bin(PLINT nbin, const PLFLT *x, const PLFLT *y, PLINT center)
Definition: plstream.cc:412
plstream::timefmt
void timefmt(const char *fmt)
Definition: plstream.cc:2183
plstream::scmap1la
void scmap1la(bool itype, PLINT npts, const PLFLT *intensity, const PLFLT *coord1, const PLFLT *coord2, const PLFLT *coord3, const PLFLT *a, const bool *alt_hue_path=NULL)
Definition: plstream.cc:1508
plstream::init
void init(void)
Definition: plstream.cc:981
plline3
#define plline3
Definition: plplot.h:762
plplotc.plsxwin
def plsxwin
Definition: plplotc.py:364
plstripd
#define plstripd
Definition: plplot.h:845
plgfci
#define plgfci
Definition: plplot.h:735
plgspa
#define plgspa
Definition: plplot.h:743
plgcolbg
#define plgcolbg
Definition: plplot.h:726
plstream::vpas
void vpas(PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax, PLFLT aspect)
Definition: plstream.cc:2203
plstream::sexit
void sexit(int(*handler)(const char *))
Definition: plstream.cc:2324
plstripc
#define plstripc
Definition: plplot.h:844
plstream::mesh
void mesh(const PLFLT *x, const PLFLT *y, const PLFLT *const *z, PLINT nx, PLINT ny, PLINT opt)
Definition: plstream.cc:1168
plstripa
#define plstripa
Definition: plplot.h:843
plstring3
#define plstring3
Definition: plplot.h:842
plstream::setcontlabelparam
void setcontlabelparam(PLFLT offset, PLFLT size, PLFLT spacing, PLINT active)
Definition: plstream.cc:1672
plvpas
#define plvpas
Definition: plplot.h:859
plstream::gcol0a
void gcol0a(PLINT icol0, PLINT &r, PLINT &g, PLINT &b, PLFLT &a)
Definition: plstream.cc:748
plstream::scmap1l
void scmap1l(bool itype, PLINT npts, const PLFLT *intensity, const PLFLT *coord1, const PLFLT *coord2, const PLFLT *coord3, const bool *alt_hue_path=NULL)
Definition: plstream.cc:1482
plplotc.plMinMax2dGrid
def plMinMax2dGrid
Definition: plplotc.py:8464
plstream::line3
void line3(PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z)
Definition: plstream.cc:1080
plsfont
#define plsfont
Definition: plplot.h:819
plstream::sdimap
void sdimap(PLINT dimxmin, PLINT dimxmax, PLINT dimymin, PLINT dimymax, PLFLT dimxpmm, PLFLT dimypmm)
Definition: plstream.cc:1625
plmapfill
void plmapfill(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT_VECTOR plotentries, PLINT nplotentries)
Definition: plmap.c:661
PLS::Next
Definition: plstream.h:39
plpsty
#define plpsty
Definition: plplot.h:784
PLMAPFORM_callback
void(* PLMAPFORM_callback)(PLINT n, PLFLT_NC_VECTOR x, PLFLT_NC_VECTOR y)
Definition: plplot.h:256
plstream::box3
void box3(const char *xopt, const char *xlabel, PLFLT xtick, PLINT nsubx, const char *yopt, const char *ylabel, PLFLT ytick, PLINT nsuby, const char *zopt, const char *zlabel, PLFLT ztick, PLINT nsubz)
Definition: plstream.cc:442
options
static PLOptionTable options[]
Definition: tclMain.c:108
plgvpd
#define plgvpd
Definition: plplot.h:746
plpoin
#define plpoin
Definition: plplot.h:780
plgriddata
#define plgriddata
Definition: plplot.h:742
plgvpw
#define plgvpw
Definition: plplot.h:747
plstream::smaj
void smaj(PLFLT def, PLFLT scale)
Definition: plstream.cc:1887
plstream::sym
void sym(PLINT n, const PLFLT *x, const PLFLT *y, PLINT code)
Definition: plstream.cc:2156
text
static int text
Definition: ps.c:77
plstream::MinMax2dGrid
void MinMax2dGrid(PLFLT_MATRIX f, PLINT nx, PLINT ny, PLFLT *fmax, PLFLT *fmin)
Definition: plstream.cc:2567
plstream::dip2dc
void dip2dc(PLFLT &xmin, PLFLT &ymin, PLFLT &xmax, PLFLT &ymax)
Definition: plstream.cc:598
plstream::spause
void spause(bool pause)
Definition: plstream.cc:1960
plstream::lsty
void lsty(PLINT lin)
Definition: plstream.cc:1089
plstream::fontld
void fontld(PLINT fnt)
Definition: plstream.cc:721
plstream::gdev
void gdev(char *devname)
Definition: plstream.cc:1606
plstream::f2eval2
PLFLT f2eval2(PLINT ix, PLINT iy, PLPointer plf2eval_data)
Definition: plstream.cc:2366
plstream::mapfill
void mapfill(PLMAPFORM_callback mapform, const char *name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, const PLINT *plotentries, PLINT nplotentries)
Definition: plstream.cc:1144
plstream::env
void env(PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax, PLINT just, PLINT axis)
Definition: plstream.cc:628
plstream::MergeOpts
PLINT MergeOpts(PLOptionTable *options, const char *name, const char **notes)
Definition: plstream.cc:2415
plstream::replot
void replot(void)
Definition: plstream.cc:1391
PLFLT
float PLFLT
Definition: plplot.h:163
plstream::gver
void gver(char *p_ver)
Definition: plstream.cc:915
plscol0
#define plscol0
Definition: plplot.h:800
plplotc.pltr2
def pltr2
Definition: plplotc.py:109
plstream::sdiplt
void sdiplt(PLFLT xmin, PLFLT ymin, PLFLT xmax, PLFLT ymax)
Definition: plstream.cc:1645
plxormod
#define plxormod
Definition: plplot.h:865
PLLABEL_FUNC_callback
void(* PLLABEL_FUNC_callback)(PLINT axis, PLFLT value, PLCHAR_NC_VECTOR label, PLINT length, PLPointer data)
Definition: plplot.h:258
plerrx
#define plerrx
Definition: plplot.h:714
plstream::gra
void gra(void)
Definition: plstream.cc:866
plgcol0a
#define plgcol0a
Definition: plplot.h:725
plstream::schr
void schr(PLFLT def, PLFLT scale)
Definition: plstream.cc:1400
plstream::setopt
PLINT setopt(const char *opt, const char *optarg)
Definition: plstream.cc:2434
plgcolbga
#define plgcolbga
Definition: plplot.h:727
plstream::start
void start(const char *devname, PLINT nx, PLINT ny)
Definition: plstream.cc:2005
plfshade
void plfshade(PLF2EVAL_callback f2eval, PLPointer f2eval_data, PLF2EVAL_callback c2eval, PLPointer c2eval_data, PLINT nx, PLINT ny, PLFLT xmin, PLFLT xmax, PLFLT ymin, PLFLT ymax, PLFLT shade_min, PLFLT shade_max, PLINT sh_cmap, PLFLT sh_color, PLFLT sh_width, PLINT min_color, PLFLT min_width, PLINT max_color, PLFLT max_width, PLFILL_callback fill, PLINT rectangular, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plshade.c:416
plAlloc2dGrid
void plAlloc2dGrid(PLFLT ***f, PLINT nx, PLINT ny)
Definition: plmem.c:91
plstream::col
void col(PLcolor c)
Definition: plstream.cc:492
plstream::Free2dGrid
void Free2dGrid(PLFLT **f, PLINT nx, PLINT ny)
Definition: plstream.cc:2559
plstream::font
void font(PLINT ifont)
Definition: plstream.cc:712
plgyax
#define plgyax
Definition: plplot.h:749
plsesc
#define plsesc
Definition: plplot.h:814
plenv
#define plenv
Definition: plplot.h:711
plstream::f2eval
PLFLT f2eval(PLINT ix, PLINT iy, PLPointer plf2eval_data)
Definition: plstream.cc:2376
plstream::GetName
void GetName(char *dir, char *subdir, char *filename, char **filespec)
Definition: plstream.cc:2510
plstream::stransform
void stransform(PLTRANSFORM_callback coordinate_transform, PLPointer coordinate_transform_data)
Definition: plstream.cc:2014
plstream::szax
void szax(PLINT digmax, PLINT digits)
Definition: plstream.cc:2165
plstream::axes
void axes(PLFLT x0, PLFLT y0, const char *xopt, PLFLT xtick, PLINT nxsub, const char *yopt, PLFLT ytick, PLINT nysub)
Definition: plstream.cc:402
plstream::lab
void lab(const char *xlabel, const char *ylabel, const char *tlabel)
Definition: plstream.cc:1004
plgcmap1_range
#define plgcmap1_range
Definition: plplot.h:723
plcol0
#define plcol0
Definition: plplot.h:702
plstream::string3
void string3(PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z, const char *string)
Definition: plstream.cc:2039
plgfile
void plgfile(FILE **p_file)
Definition: plcore.c:3794
plsKeyEH
void plsKeyEH(void(*KeyEH)(PLGraphicsIn *, void *, int *), void *KeyEH_data)
Definition: plcore.c:3715
plbox3
#define plbox3
Definition: plplot.h:698
plstream::translatecursor
PLINT translatecursor(PLGraphicsIn *gin)
Definition: plstream.cc:1382
plcolorbar
#define plcolorbar
Definition: plplot.h:704
plstream::gpage
void gpage(PLFLT &xp, PLFLT &yp, PLINT &xleng, PLINT &yleng, PLINT &xoff, PLINT &yoff)
Definition: plstream.cc:856
PLFLT_NC_MATRIX
PLFLT ** PLFLT_NC_MATRIX
Definition: plplot.h:248
plstream::gdidev
void gdidev(PLFLT &mar, PLFLT &aspect, PLFLT &jx, PLFLT &jy)
Definition: plstream.cc:784
plstream::sError
void sError(PLINT *errcode, char *errmsg)
Definition: plstream.cc:2315
plstream::lightsource
void lightsource(PLFLT x, PLFLT y, PLFLT z)
Definition: plstream.cc:1062
plstream::sxwin
void sxwin(PLINT window_id)
Definition: plstream.cc:2138
plstream::hist
void hist(PLINT n, const PLFLT *data, PLFLT datmin, PLFLT datmax, PLINT nbin, PLINT oldwin)
Definition: plstream.cc:969
plglevel
#define plglevel
Definition: plplot.h:738
plstream::maptex
void maptex(PLMAPFORM_callback mapform, const char *name, PLFLT dx, PLFLT dy, PLFLT just, const char *text, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT plotentry)
Definition: plstream.cc:1132
plstream::ptex
void ptex(PLFLT x, PLFLT y, PLFLT dx, PLFLT dy, PLFLT just, const char *text)
Definition: plstream.cc:1360
Coord_2d
Definition: plstream.h:69
plstream::scol0
void scol0(PLINT icol0, PLINT r, PLINT g, PLINT b)
Definition: plstream.cc:1543
plpoin3
#define plpoin3
Definition: plplot.h:781
plstream::gcol0
void gcol0(PLINT icol0, PLINT &r, PLINT &g, PLINT &b)
Definition: plstream.cc:739
plscmap0n
#define plscmap0n
Definition: plplot.h:793
plstream::poin3
void poin3(PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z, PLINT code)
Definition: plstream.cc:1315
plstream::gFileDevs
void gFileDevs(const char ***p_menustr, const char ***p_devname, int *p_ndev)
Definition: plstream.cc:2295
plscolor
#define plscolor
Definition: plplot.h:804
plsvpa
#define plsvpa
Definition: plplot.h:850
plpat
#define plpat
Definition: plplot.h:779
plstream::meridians
void meridians(PLMAPFORM_callback mapform, PLFLT dlong, PLFLT dlat, PLFLT minlong, PLFLT maxlong, PLFLT minlat, PLFLT maxlat)
Definition: plstream.cc:1155
pl_setcontlabelformat
#define pl_setcontlabelformat
Definition: plplot.h:690
plstream::ClearOpts
void ClearOpts(void)
Definition: plstream.cc:2397
plscmap1_range
#define plscmap1_range
Definition: plplot.h:799
plstream::gvpd
void gvpd(PLFLT &xmin, PLFLT &xmax, PLFLT &ymin, PLFLT &ymax)
Definition: plstream.cc:924
plgcol0
#define plgcol0
Definition: plplot.h:724
plcallback::tr2
PLDLLIMPEXP_CXX void tr2(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer pltr_data)
Definition: plstream.cc:272
plstream::gradient
void gradient(PLINT n, const PLFLT *x, const PLFLT *y, PLFLT angle)
Definition: plstream.cc:876
plstream::active_streams
static PLINT active_streams
Definition: plstream.h:124
plGetFlt
PLFLT plGetFlt(PLCHAR_VECTOR s)
Definition: plctrl.c:2945
plreplot
#define plreplot
Definition: plplot.h:788
plstream::spal0
void spal0(const char *filename)
Definition: plstream.cc:1942
plstream::flush
void flush(void)
Definition: plstream.cc:703
plstream::legend
void legend(PLFLT *p_legend_width, PLFLT *p_legend_height, PLINT opt, PLINT position, PLFLT x, PLFLT y, PLFLT plot_width, PLINT bg_color, PLINT bb_color, PLINT bb_style, PLINT nrow, PLINT ncolumn, PLINT nlegend, const PLINT *opt_array, PLFLT text_offset, PLFLT text_scale, PLFLT text_spacing, PLFLT text_justification, const PLINT *text_colors, const char *const *text, const PLINT *box_colors, const PLINT *box_patterns, const PLFLT *box_scales, const PLFLT *box_line_widths, const PLINT *line_colors, const PLINT *line_styles, const PLFLT *line_widths, const PLINT *symbol_colors, const PLFLT *symbol_scales, const PLINT *symbol_numbers, const char *const *symbols)
Definition: plstream.cc:1014
plstream::arc
void arc(PLFLT x, PLFLT y, PLFLT a, PLFLT b, PLFLT angle1, PLFLT angle2, PLFLT rotate, PLBOOL fill)
Definition: plstream.cc:373
plcallback::tr1
PLDLLIMPEXP_CXX void tr1(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer pltr_data)
Definition: plstream.cc:263
plstream::hlsrgb
void hlsrgb(PLFLT h, PLFLT l, PLFLT s, PLFLT *p_r, PLFLT *p_g, PLFLT *p_b)
Definition: plstream.cc:2577
plstream::cont
void cont(const PLFLT *const *f, PLINT nx, PLINT ny, PLINT kx, PLINT lx, PLINT ky, PLINT ly, const PLFLT *clevel, PLINT nlevel, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plstream.cc:540
errmsg
static char errmsg[160]
Definition: tclAPI.c:158
plscmap1l
#define plscmap1l
Definition: plplot.h:796
plmap
void plmap(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy)
Definition: plmap.c:565
plprec
#define plprec
Definition: plplot.h:783
plstream::sdiplz
void sdiplz(PLFLT xmin, PLFLT ymin, PLFLT xmax, PLFLT ymax)
Definition: plstream.cc:1654
plptex
#define plptex
Definition: plplot.h:785
plstream::xormod
void xormod(bool mode, bool *status)
Definition: plstream.cc:2262
plline
#define plline
Definition: plplot.h:760
plstream::fill3
void fill3(PLINT n, const PLFLT *x, const PLFLT *y, const PLFLT *z)
Definition: plstream.cc:694
plgradient
#define plgradient
Definition: plplot.h:741
plstream::Alloc2dGrid
void Alloc2dGrid(PLFLT_NC_MATRIX *f, PLINT nx, PLINT ny)
Definition: plstream.cc:2550
plstream::gfont
void gfont(PLINT &family, PLINT &style, PLINT &weight)
Definition: plstream.cc:838
plstream::OptUsage
void OptUsage(void)
Definition: plstream.cc:2443
plstream::slabelfunc
void slabelfunc(PLLABEL_FUNC_callback label_func, PLPointer label_data)
Definition: plstream.cc:1878
plplot.h
plstream::ptex3
void ptex3(PLFLT wx, PLFLT wy, PLFLT wz, PLFLT dx, PLFLT dy, PLFLT dz, PLFLT sx, PLFLT sy, PLFLT sz, PLFLT just, const char *text)
Definition: plstream.cc:1370
pladv
#define pladv
Definition: plplot.h:692
plStatic2dGrid
void plStatic2dGrid(PLFLT_NC_MATRIX zIliffe, PLFLT_VECTOR zStatic, PLINT nx, PLINT ny)
Definition: plmem.c:61
plvasp
#define plvasp
Definition: plplot.h:857
PLFLT_VECTOR
const PLFLT * PLFLT_VECTOR
Definition: plplot.h:244
plrandd
#define plrandd
Definition: plplot.h:787
plstream::scmap1_range
void scmap1_range(PLFLT min_color, PLFLT max_color)
Definition: plstream.cc:1427
Contourable_Data_evaluator
PLFLT Contourable_Data_evaluator(PLINT i, PLINT j, PLPointer p)
Definition: plstream.cc:43
plstream::gdiori
void gdiori(PLFLT &rot)
Definition: plstream.cc:793
plscmap0
#define plscmap0
Definition: plplot.h:791
plmapstring
void plmapstring(PLMAPFORM_callback mapform, PLCHAR_VECTOR name, PLCHAR_VECTOR string, PLFLT minx, PLFLT maxx, PLFLT miny, PLFLT maxy, PLINT_VECTOR plotentries, PLINT nplotentries)
Definition: plmap.c:616
plstream::colorbar
void colorbar(PLFLT *p_colorbar_width, PLFLT *p_colorbar_height, PLINT opt, PLINT position, PLFLT x, PLFLT y, PLFLT x_length, PLFLT y_length, PLINT bg_color, PLINT bb_color, PLINT bb_style, PLFLT low_cap_color, PLFLT high_cap_color, PLINT cont_color, PLFLT cont_width, PLINT n_labels, PLINT *label_opts, const char *const *label, PLINT n_axes, const char *const *axis_opts, PLFLT *ticks, PLINT *sub_ticks, PLINT *n_values, const PLFLT *const *values)
Definition: plstream.cc:1039
plstream::smin
void smin(PLFLT def, PLFLT scale)
Definition: plstream.cc:1914
plgstrm
#define plgstrm
Definition: plplot.h:744
pltr2p
void pltr2p(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer pltr_data)
Definition: plcont.c:1113
plsfci
#define plsfci
Definition: plplot.h:817
plfcont
void plfcont(PLF2EVAL_callback f2eval, PLPointer f2eval_data, PLINT nx, PLINT ny, PLINT kx, PLINT lx, PLINT ky, PLINT ly, PLFLT_VECTOR clevel, PLINT nlevel, PLTRANSFORM_callback pltr, PLPointer pltr_data)
Definition: plcont.c:535
plstream::scmap0n
void scmap0n(PLINT ncol0)
Definition: plstream.cc:1409
plstream::gzax
void gzax(PLINT &digmax, PLINT &digits)
Definition: plstream.cc:960
plmtex
#define plmtex
Definition: plplot.h:773
label_func
void(* label_func)(PLINT, PLFLT, char *, PLINT, PLPointer)
Definition: plplotluacLUA_wrap.c:3049
plsurf3d
#define plsurf3d
Definition: plplot.h:847
plplotc.pltr1
def pltr1
Definition: plplotc.py:105
plgra
#define plgra
Definition: plplot.h:740
plstream::GetCursor
PLINT GetCursor(PLGraphicsIn *plg)
Definition: plstream.cc:2595
plstream::string
void string(PLINT n, const PLFLT *x, const PLFLT *y, const char *string)
Definition: plstream.cc:2027
plsdimap
#define plsdimap
Definition: plplot.h:808
plstream::psty
void psty(PLINT patt)
Definition: plstream.cc:1351
plstream::calc_world
void calc_world(PLFLT rx, PLFLT ry, PLFLT &wx, PLFLT &wy, PLINT &window)
Definition: plstream.cc:464
plcallback::tr2p
PLDLLIMPEXP_CXX void tr2p(PLFLT x, PLFLT y, PLFLT *tx, PLFLT *ty, PLPointer pltr_data)
Definition: plstream.cc:281
plcallback::fill
PLDLLIMPEXP_CXX void fill(PLINT n, const PLFLT *x, const PLFLT *y)
Definition: plstream.cc:246
plot3d
#define plot3d
Definition: plplot.h:775
PLcolor
PLcolor
Definition: plstream.h:42
plstream::FindName
PLINT FindName(char *p)
Definition: plstream.cc:2491
plstream::famadv
void famadv(void)
Definition: plstream.cc:676
plslabelfunc
#define plslabelfunc
Definition: plplot.h:825
plstream::gcolbga
void gcolbga(PLINT &r, PLINT &g, PLINT &b, PLFLT &a)
Definition: plstream.cc:766
PLGraphicsIn
Definition: plplot.h:433