C  ---CAMERA CONTROL ROUTINE--
C ---AC SWITCH 13 MUST BE UP TO ENTER PROGRAM--
C
      SUBROUTINE CAMERA(NB)
      LOGICAL T,F,ERROR
      COMMON/GENDAT/MCON(20,2),NTYPE(20),BSCALE(20),KOLOR(20),
     9IDENT(20)
      COMMON/MODDAT/IAX,DIST,SMODEL(7,17,2),MODNO(10)
      DATA T,F/.TRUE.,.FALSE./
C --- STOP DISPLAY---
      CALL DSTOP
C ----TURN ALL DISPLAY FILES OFF---
      DO 10 I=1,NB
      IF(NTYPE(I).EQ.10)GO TO 10
      CALL DISPLY(5,I)
10    CONTINUE
      IF(IAX.EQ.1)CALL DISPLY(5,21)
C--CHECK IF ELEMENT HAS A SYMBOL
      CALL SHUTTR(T,ERROR)
      DO 5 K=1,5000
5     CONTINUE
      DO 100 N=1,NB
      IF(NTYPE(N).EQ.10)GO TO 100
      CALL DISPLY(4,N)
C  --SELECT COLOUR---
      IWHT=0
      IREFR=0
      IREFB=0
      IREFG=0
      IBR=KOLOR(N)
      GO TO (11,12,13,14,15,16,17),IBR
C  ---RED---
11    IREFR=32
      GO TO 20
C  --BLUE---
12    IREFB=16
      GO TO 20
C  ---GREEN--
13    IREFG=24
      GO TO 20
C --YELLOW--
14      IREFR=64
      IREFG=48
      GO TO 20
C --CYAN---
15    IREFB=4
      IREFG=12
      GO TO 20
C  ---MAGENTA--
16    IREFR=32
      IREFB=16
      GO TO 20
C  --WHITE--
17    IWHT=14
20    CALL FILMER(IREFR,IREFB,IREFG,IWHT)
      CALL DISPLY(5,N)
100   CONTINUE
C  ---FILM AXIS---
      IF(IAX.EQ.0)GO TO 200
      IREFR=0
      IREFB=16
      IREFG=0
      IWHT=0
      CALL DISPLY(4,21)
      CALL FILMER(IREFR,IREFB,IREFG,IWHT)
C --RESET FILTERS AND START DISPLAY--
200   CALL SWITCH(1,0,2,0,3,0)
C --CLOSE SHUTTER--
      CALL SHUTTR(F,ERROR)
      DO 6 K=1,5000
6     CONTINUE
      CALL DGO
      RETURN
      END
