/*rdinit initial readar array for storing line images at start of calculation */ #include "cddefines.h" #include "input.h" #include "rdinit.h" void rdinit(void) { # ifdef DEBUG_FUN fputs( "<+>rdinit()\n", debug_fp ); # endif /* this sub must be called before calling READAR to get line images * it simply sets the pointer to set up reading the images * */ if( input.iReadWay > 0 ) { /* this is usual case, read from the start of array, the commands */ input.nRead = -1; } else if( input.iReadWay < 0 ) { /* this is special case where we read from end of array, the ini file */ /* save the current counter so we can reset it when done */ input.nReadSv = input.nRead; /* and set current counter to the bottom of the stack */ input.nRead = NKRD; } # ifdef DEBUG_FUN fputs( " <->rdinit()\n", debug_fp ); # endif return; }