Package gov.nasa.worldwind.render

Examples of gov.nasa.worldwind.render.Material


      if (this.surfaceShape != null)
      {
         ShapeAttributes attr = this.surfaceShape.getAttributes();
         if (attr == null)
            attr = new BasicShapeAttributes();
         attr.setOutlineMaterial(new Material(color));
         attr.setOutlineOpacity(color.getAlpha() / 255d);
         this.surfaceShape.setAttributes(attr);
      }
      this.wwd.redraw();
   }
View Full Code Here


  
   static protected ShapeAttributes _s_getDefaultAttributes()
   {
        ShapeAttributes attributes = new BasicShapeAttributes();
       
        attributes.setInteriorMaterial(new Material(Color.BLACK, Color.LIGHT_GRAY, Color.DARK_GRAY, Color.BLACK, 0.0f));
       
        attributes.setOutlineMaterial(Material.DARK_GRAY);
        attributes.setDrawOutline(true);
       
        //attributes.setInteriorOpacity(0.95);
View Full Code Here

    static private PointPlacemarkAttributes _s_getAttributes_()
    {
       PointPlacemarkAttributes ppa = new PointPlacemarkAttributes();
      
       ppa.setLabelColor("ffffffff");
       ppa.setLineMaterial(new Material(Color.GREEN));
       ppa.setUsePointAsDefaultImage(true);
       ppa.setScale(10d);

       return ppa;
    }
View Full Code Here

        fltAlpha *= 2.5;
        int intAlpha = Math.round(fltAlpha);
        Color col = new Color(colRgb.getRed(), colRgb.getGreen(), colRgb.getBlue(), intAlpha);
       
       
        ppa.setLineMaterial(new Material(col));
        ppa.setScale(this._douScale_);
        ppa.setUsePointAsDefaultImage(true);   
        super.setAttributes(ppa);
    }
View Full Code Here

          if (objWhat == EnuEvtDspRndWwdEarthShpDimOne.COLOR)
          {
             Color col = (Color) evt.getValue();
            
             PointPlacemarkAttributes ppa = super.getAttributes();
             ppa.setLineMaterial(new Material(col));
             this.firePropertyChange(GfrShouldRedrawRnd.STR, null, null);
             return;
          }
         
          if (objWhat == EnuEvtDspRndWwdEarthShpDimOne.TRANSPARENCY)
          {
             Float flo = (Float) evt.getValue();
             float fltAlpha = flo.floatValue();
             fltAlpha *=100;
             fltAlpha *= 2.55;
             int intAlpha = Math.round(fltAlpha);
            
             PointPlacemarkAttributes ppa = super.getAttributes();
             Color colOld = ppa.getLineMaterial().getDiffuse();
             Color colNew = new Color(colOld.getRed(), colOld.getGreen(), colOld.getBlue(), intAlpha);
             ppa.setLineMaterial(new Material(colNew));
             this.firePropertyChange(GfrShouldRedrawRnd.STR, null, null);
             return;
          }
         
          return;
View Full Code Here

    }

    public static AirspaceAttributes getDefaultAttributes()
    {
        AirspaceAttributes attributes = new BasicAirspaceAttributes();
        attributes.setMaterial(new Material(Color.BLACK, Color.LIGHT_GRAY, Color.DARK_GRAY, Color.BLACK, 0.0f));
        attributes.setOutlineMaterial(Material.DARK_GRAY);
        attributes.setDrawOutline(true);
        attributes.setOpacity(0.95);
        attributes.setOutlineOpacity(.95);
        attributes.setOutlineWidth(2);
View Full Code Here

         
          if (objWhat == EnuEvtDspRndWwdEarthShpDimOne.COLOR)
          {
             Color col = (Color) evt.getValue();
             BasicShapeAttributes bsa = (BasicShapeAttributes) super.getAttributes();
             bsa.setOutlineMaterial(new Material(col));
             this.firePropertyChange(GfrShouldRedrawRnd.STR, null, null);
             return;
          }
         
          if (objWhat == EnuEvtDspRndWwdEarthShpDimOne.TRANSPARENCY)
View Full Code Here

       bsa.setDrawOutline(true);
       double dblWidthOut = (double) GfrWrpBasPrsDspPrjRndWwdEarthShpDimOneSegmentWiseYes.getInstance().getThickness(_strId);
       bsa.setOutlineWidth(dblWidthOut);
     
       Color colRgbOut = GfrWrpBasPrsDspPrjRndWwdEarthShpDimOneSegmentWiseYes.getInstance().getColor(super._strId)
       bsa.setOutlineMaterial(new Material(colRgbOut));
    
       float fltAlphaOut = GfrWrpBasPrsDspPrjRndWwdEarthShpDimOneSegmentWiseYes.getInstance().getTransparency(super._strId);
       bsa.setOutlineOpacity((double) fltAlphaOut);
    
       super.setAttributes(bsa);
View Full Code Here

         
          if (objWhat == EnuEvtDspRndWwdEarthDimTwo.COLOR_IN) // what about transparency?
          {
             Color col = (Color) evt.getValue();
             BasicShapeAttributes bsa = (BasicShapeAttributes) super.getAttributes();
             bsa.setInteriorMaterial(new Material(col));
             this.firePropertyChange(GfrShouldRedrawRnd.STR, null, null);
             return;
          }
         
          if (objWhat == EnuEvtDspRndWwdEarthDimTwo.TRANSPARENCY_IN)
          {
             Float flo = (Float) evt.getValue();
             float fltAlpha = flo.floatValue();
             BasicShapeAttributes bsa = (BasicShapeAttributes) super.getAttributes();
             bsa.setInteriorOpacity((double) fltAlpha);
             this.firePropertyChange(GfrShouldRedrawRnd.STR, null, null);
             return;
          }
         
          if (objWhat == EnuEvtDspRndWwdEarthDimTwo.COLOR_OUT) // what about transparency?
          {
             Color col = (Color) evt.getValue();
             BasicShapeAttributes bsa = (BasicShapeAttributes) super.getAttributes();
             bsa.setOutlineMaterial(new Material(col));
             this.firePropertyChange(GfrShouldRedrawRnd.STR, null, null);
             return;
          }
         
          if (objWhat == EnuEvtDspRndWwdEarthDimTwo.TRANSPARENCY_OUT)
View Full Code Here

      bsa.setDrawOutline(true);
      final double dblWidthOut = 1;
      bsa.setOutlineWidth(dblWidthOut);
     
      Color colRgbOut = GfrWrpBasPrsDspPrjRndWwdEarthShpDimTwo.getInstance().getColorOut(this._strId_)
     bsa.setOutlineMaterial(new Material(colRgbOut));
    
     float fltAlphaOut = GfrWrpBasPrsDspPrjRndWwdEarthShpDimTwo.getInstance().getTransparencyOut(this._strId_);
     bsa.setOutlineOpacity((double) fltAlphaOut);
      // end out
     
      // beg in
     bsa.setDrawInterior(true);
     Color colRgbIn = GfrWrpBasPrsDspPrjRndWwdEarthShpDimTwo.getInstance().getColorIn(this._strId_)
     bsa.setInteriorMaterial(new Material(colRgbIn));
    
     float fltAlphaIn = GfrWrpBasPrsDspPrjRndWwdEarthShpDimTwo.getInstance().getTransparencyIn(this._strId_);
     bsa.setInteriorOpacity((double) fltAlphaIn);
      // end in
    
View Full Code Here

TOP

Related Classes of gov.nasa.worldwind.render.Material

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.