/* Copyright (C) 1992 by Thomas Glen Smith. All Rights Reserved. */ /* revrot APL2 V1.0.0 ************************************************** * Called by reverse and rotate. Does initialization for both. * ***********************************************************************/ #define INCLUDES APLCB #include "includes.h" Aplcb revrot(rite,axis,axicnt,botcnt,topcnt) Aplcb rite; /* variable to be reversed/rotated */ int axis; /* axis of reversal/rotation */ int *axicnt,*botcnt,*topcnt; { Axispre; Errinit; Getcb; Intcopy; int *ip; Aplcb out; if (errinit()) return(NULL); if (OK!=axispre(rite,axis,axicnt,botcnt,topcnt)) return(NULL); out=getcb(NULL,rite->aplcount, (rite->aplflags & (APLMASK + APLAPL)) + APLTEMP, rite->aplrank,NULL); if (out == NULL) return(NULL); /* now copy shape */ ip=intcopy(out->apldim,rite->apldim,rite->aplrank,1); return(out); }