Skip to content

AFNI/NIfTI Server

Sections
Personal tools
You are here: Home » AFNI » Documentation

Doxygen Source Code Documentation


Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals   Search  

color.c

Go to the documentation of this file.
00001 /* color.f -- translated by f2c (version 19961017).
00002    You must link the resulting object file with the libraries:
00003         -lf2c -lm   (in that order)
00004 */
00005 
00006 #include "f2c.h"
00007 
00008 /* Common Block Declarations */
00009 
00010 extern struct {
00011     real xpgmin, ypgmin, xpgmax, ypgmax, xclbot, yclbot, xcltop, ycltop, xbot,
00012              ybot, xtop, ytop, xmin, ymin, xmax, ymax;
00013     integer ixcoor, iycoor;
00014     real alphxx, betaxx, alphyy, betayy, tmajx, tminx, tmajy, tminy;
00015     integer majrx, minrx, majry, minry, isizx, isizy;
00016     real xphold, yphold;
00017 } zzzplt_;
00018 
00019 #define zzzplt_1 zzzplt_
00020 
00021 extern struct {
00022     real xphmax, yphmax;
00023     integer ixpmax, iypmax;
00024     real xpscal, ypscal;
00025     integer iflip, nplotr;
00026     char cfile[64];
00027 } zzpltr_;
00028 
00029 #define zzpltr_1 zzpltr_
00030 
00031 
00032 
00033 
00034 /* Subroutine */ int color_(integer *ncol)
00035 {
00036     /* Initialized data */
00037 
00038     static real rgb[21] /* was [3][7] */ = { 0.f,0.f,0.f,1.f,0.f,0.f,0.f,0.f,
00039             1.f,0.f,1.f,0.f,1.f,1.f,0.f,1.f,0.f,1.f,0.f,1.f,1.f };
00040 
00041     /* System generated locals */
00042     integer i__1, i__2;
00043 
00044     /* Local variables */
00045     static integer ic;
00046     extern /* Subroutine */ int zzmpco_(real *, real *, real *);
00047 
00048 
00049 /*  Set the color of subsequent lines */
00050 /* .......................................................................
00051  */
00052 
00053 
00054 /*  Internal Data for PLOTPAK */
00055 
00056 /* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
00057  */
00058 /* cc      IF( NPLOTR.EQ.1 .OR. NPLOTR.EQ.2 )THEN */
00059 /* cc         IF( NCOL .LE. 1 .OR. NCOL .GT. 7 )THEN */
00060 /* cc            CALL GCOLOR( 5Hclear ) */
00061 /* cc         ELSEIF( NCOL .EQ. 2 )THEN */
00062 /* cc            CALL GCOLOR( 3Hred ) */
00063 /* cc         ELSEIF( NCOL .EQ. 3 )THEN */
00064 /* cc            CALL GCOLOR( 4Hblue ) */
00065 /* cc         ELSEIF( NCOL .EQ. 4 )THEN */
00066 /* cc            CALL GCOLOR( 5Hgreen ) */
00067 /* cc         ELSEIF( NCOL .EQ. 5 )THEN */
00068 /* cc            CALL GCOLOR( 6Hyellow ) */
00069 /* cc         ELSEIF( NCOL .EQ. 6 )THEN */
00070 /* cc            CALL GCOLOR( 7Hmagenta ) */
00071 /* cc         ELSEIF( NCOL .EQ. 7 )THEN */
00072 /* cc            CALL GCOLOR( 4Hcyan ) */
00073 /* cc         ENDIF */
00074 
00075 /* cc      IF( NPLOTR.EQ.5 )THEN */
00076 /* cc         CALL ZZPCOL( NCOL ) */
00077 /* cc      ENDIF */
00078 
00079 /* cc      IF( NPLOTR .EQ. 6 )THEN */
00080 /* cc         IC = MAX( 1 , MIN( 7 , NCOL ) ) */
00081 /* cc         CALL ZZPSCO( RGB(1,IC) , RGB(2,IC) , RGB(3,IC) ) */
00082 /* cc      ENDIF */
00083     if (zzpltr_1.nplotr == 7) {
00084 /* Computing MAX */
00085         i__1 = 1, i__2 = min(7,*ncol);
00086         ic = max(i__1,i__2);
00087         zzmpco_(&rgb[ic * 3 - 3], &rgb[ic * 3 - 2], &rgb[ic * 3 - 1]);
00088     }
00089 
00090     return 0;
00091 } /* color_ */
00092 
00093 
00094 
00095 
00096 /* Subroutine */ int fcolor_(real *cr, real *cg, real *cb)
00097 {
00098     extern /* Subroutine */ int zzmpco_(real *, real *, real *);
00099 
00100 
00101 /*  Set the color of subsequent lines */
00102 /* .......................................................................
00103  */
00104 /* +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
00105  */
00106 
00107 /*  Internal Data for PLOTPAK */
00108 
00109     if (zzpltr_1.nplotr == 7) {
00110         zzmpco_(cr, cg, cb);
00111     }
00112     return 0;
00113 } /* fcolor_ */
00114 
 

Powered by Plone

This site conforms to the following standards: