Code example for CornerPathEffect

0
      this.mShader = null;
      transformSegmentToPath(); 
 
      // Just the rendering bits left to do 
      Paint routePaint = new Paint();
      routePaint.setPathEffect( new CornerPathEffect( 10 ) );
//      Log.d( TAG, "Drawing color is "+trackColoringMethod ); 
      switch (trackColoringMethod)
      { 
         case ( DRAW_CALCULATED ):
         case ( DRAW_MEASURED ):
            routePaint.setShader( this.mShader );
            break; 
         case ( DRAW_RED ):
            routePaint.setColor( Color.RED );
            break; 
         case ( DRAW_GREEN ):
         default: 
            routePaint.setColor( Color.GREEN );
            break;