C
C	$Id: wmlgfa.f,v 1.4 2008-07-27 00:17:37 haley Exp $
C                                                                      
C                Copyright (C)  2000
C        University Corporation for Atmospheric Research
C                All Rights Reserved
C
C The use of this Software is governed by a License Agreement.
C
      SUBROUTINE WMLGFA(XXC,YYC,NNC)
C
C  Subroutine for processing polygons generated by calls to PPINPO.
C
      DIMENSION XXC(NNC),YYC(NNC)
C
C  IDRFLG = -1  means draw a polyline only.
C         =  0  means draw a filled area only.
C         =  1  draws a filled area and a representative line for
C               showers.
C         =  2  draws a filled area and a representative line for
C               t-storms.
C         =  3  draws a filled area for showers.
C
      COMMON /WMLGCM/IDRFLG
C
      IF (IDRFLG .EQ. -1) THEN
        CALL GPL(NNC,XXC,YYC)
      ELSE IF (IDRFLG .EQ. 0) THEN
        CALL GFA(NNC,XXC,YYC)
      ELSE IF (IDRFLG .EQ. 1) THEN
        CALL GFA(NNC,XXC,YYC)
        CALL GQLWSC(IER,SCLO)
        CALL GSLWSC(.5)
        CALL GPL(2,XXC(2),YYC(2))
        CALL GSLWSC(SCLO)
      ELSE IF (IDRFLG .EQ. 2) THEN
        CALL GFA(NNC,XXC,YYC)
        CALL GQLWSC(IER,SCLO)
        CALL GSLWSC(.5)
        CALL GPL(4,XXC,YYC)
        CALL GSLWSC(SCLO)
      ELSE IF (IDRFLG .EQ. 3) THEN
        CALL GFA(NNC,XXC,YYC)
      ELSE IF (IDRFLG .EQ. 4) THEN
        CALL GFA(NNC,XXC,YYC)
        CALL GQLWSC(IER,SCLO)
        CALL GSLWSC(.5)
        CALL GPL(2,XXC,YYC)
        CALL GSLWSC(SCLO)
      ENDIF
C
      RETURN
      END
