protected BufferedImage create_MEASURED_VALUE_Image ( final int WIDTH , final Color COLOR , final double ROTATION_OFFSET ) { if ( WIDTH <= 36 ) // 36 is needed otherwise the image size could be smaller than 1 { return UTIL . createImage ( 1 , 1 , Transparency . TRANSLUCENT ) ; } final int IMAGE_HEIGHT = ( int ) ( WIDTH * 0.0280373832 ) ; final int IMAGE_WIDTH = IMAGE_HEIGHT ; final BufferedImage IMAGE = UTIL . createImage ( IMAGE_WIDTH , IMAGE_HEIGHT , Transparency . TRANSLUCENT ) ; final Graphics2D G2 = IMAGE . createGraphics ( ) ; G2 . setRenderingHint ( RenderingHints . KEY_ANTIALIASING , RenderingHints . VALUE_ANTIALIAS_ON ) ; G2 . rotate ( ROTATION_OFFSET , IMAGE_WIDTH / 2.0 , IMAGE_HEIGHT / 2.0 ) ; final GeneralPath INDICATOR = new GeneralPath ( ) ; INDICATOR . setWindingRule ( Path2D . WIND_EVEN_ODD ) ; INDICATOR . moveTo ( IMAGE_WIDTH * 0.5 , IMAGE_HEIGHT ) ; INDICATOR . lineTo ( 0.0 , 0.0 ) ; INDICATOR . lineTo ( IMAGE_WIDTH , 0.0 ) ; INDICATOR . closePath ( ) ; G2 . setColor ( COLOR ) ; G2 . fill ( INDICATOR ) ; G2 . dispose ( ) ; return IMAGE ; }
Returns the image of the MinMeasuredValue and MaxMeasuredValue dependend