/* Shader description goes here */
surface
constant_custom(float Kfb = 1;    /* fake brightness */
                float size = 0.1;
                /*size of the corner circle*/ 
                float center_size = 0.1; 
                /*size of the center circle*/
                float ring_size = 0.75; 
                float inside_circle_size = 0.45; 
                float cross_size = 0.45; /* [0.0 0.6] */
                float center_pos_s = 0.5; /* [collection Position] */
                float center_pos_t = 0.5; /* [collection Position] */
                float left_top_pos_s = 0.1; /* [collection Position] */
                float left_top_pos_t = 0.1; /* [collection Position] */
                float right_top_pos_s = 0.9; /* [collection Position] */
                float right_top_pos_t = 0.1; /* [collection Position] */
                float left_bottom_pos_s = 0.1; /* [collection Position] */
                float left_bottom_pos_t = 0.9; /* [collection Position] */
                float right_bottom_pos_s = 0.9; /* [collection Position] */
                float right_bottom_pos_t = 0.9; /* [collection Position] */        
                color forecolor = color(0.996, 0.624, 0.616); /* [collection Colors] */
                color backcolor = color(0.796, 0.424, 0.416); /* [collection Colors] */
                color center_color = color (0.5, 0.5, 0.5); /* [collection Colors] */
                    color center_ring_color = color (0.5 ,0.5, 0.5); /* [collection Colors] */
                color left_top_color = color (0.5, 0.5, 0.5); /* [collection Colors] */
                    color left_top_ring_color = color (0.5 ,0.5, 0.5); /* [collection Colors] */
                color right_top_color = color (0.5, 0.5, 0.5); /* [collection Colors] */
                    color right_top_ring_color = color (0.5 ,0.5, 0.5); /* [collection Colors] */
                color left_bottom_color = color (0.5, 0.5, 0.5); /* [collection Colors] */
                    color left_bottom_ring_color = color (0.5 ,0.5, 0.5); /* [collection Colors] */
                color right_bottom_color = color (0.5, 0.5, 0.5); /* [collection Colors] */
                    color right_bottom_ring_color = color (0.5 ,0.5, 0.5); /* [collection Colors] */
                color cross_color_h = color (0.5, 0.5, 0.5); /* [collection Colors] */
                    color cross_color_v = color (0.5, 0.5, 0.5); /* [collection Colors] */
                color bg_opacity = 1)
  
                
{
color    surfcolor = backcolor;
Oi = bg_opacity;
  
  
/*center ring*/
if (((s-center_pos_s)*(s-center_pos_s))+((t-center_pos_t)*(t-center_pos_t)) <= center_size && ((s-center_pos_s)*(s-center_pos_s))+((t-center_pos_t)*(t-center_pos_t)) >= center_size*ring_size)
    {    
    surfcolor = center_ring_color;
    Oi = 1;
    }
    
else if (((s-center_pos_s)*(s-center_pos_s))+((t-center_pos_t)*(t-center_pos_t)) <= center_size * inside_circle_size)
    {    
    surfcolor = center_color;
    Oi = 1;
    }
  
//left-top
else if (((s-left_top_pos_s)*(s-left_top_pos_s))+((t-left_top_pos_t)*(t-left_top_pos_t)) <= size && ((s-left_top_pos_s)*(s-left_top_pos_s))+((t-left_top_pos_t)*(t-left_top_pos_t)) >= size*ring_size)
    {    
    surfcolor = left_top_ring_color;
    Oi = 1;
    }
else if (((s-left_top_pos_s)*(s-left_top_pos_s))+((t-left_top_pos_t)*(t-left_top_pos_t)) <= size*inside_circle_size)
    {    
    surfcolor = left_top_color;
    Oi = 1;
    }
    
//right-top
else if (((s-right_top_pos_s)*(s-right_top_pos_s))+((t-right_top_pos_t)*(t-right_top_pos_t)) <= size && ((s-right_top_pos_s)*(s-right_top_pos_s))+((t-right_top_pos_t)*(t-right_top_pos_t)) >= size*ring_size)
    {    
    surfcolor = right_top_ring_color;
    Oi = 1;
    }
else if (((s-right_top_pos_s)*(s-right_top_pos_s))+((t-right_top_pos_t)*(t-right_top_pos_t)) <= size*inside_circle_size)
    {    
    surfcolor = right_top_color;
    Oi = 1;
    }
    
//left-bottom
else if (((s-left_bottom_pos_s)*(s-left_bottom_pos_s))+((t-left_bottom_pos_t)*(t-left_bottom_pos_t)) <= size && ((s-left_bottom_pos_s)*(s-left_bottom_pos_s))+((t-left_bottom_pos_t)*(t-left_bottom_pos_t)) >= size*ring_size)
    {    
    surfcolor = left_bottom_ring_color;
    Oi = 1;
    }
else if (((s-left_bottom_pos_s)*(s-left_bottom_pos_s))+((t-left_bottom_pos_t)*(t-left_bottom_pos_t)) <= size*inside_circle_size)
    {    
    surfcolor = left_bottom_color;
    Oi = 1;
    }
    
//right-bottom
else if (((s-right_bottom_pos_s)*(s-right_bottom_pos_s))+((t-right_bottom_pos_s)*(t-right_bottom_pos_s)) <= size && ((s-right_bottom_pos_s)*(s-right_bottom_pos_s))+((t-right_bottom_pos_s)*(t-right_bottom_pos_s)) >= size*ring_size)
    {    
    surfcolor = right_bottom_ring_color;
    Oi = 1;
    }
else if (((s-right_bottom_pos_s)*(s-right_bottom_pos_s))+((t-right_bottom_pos_s)*(t-right_bottom_pos_s)) <= size*inside_circle_size)
    {    
    surfcolor = right_bottom_color;
    Oi = 1;
    }
    
//center cross
else if (t>=cross_size && t <=1-cross_size)
    {    
    surfcolor = cross_color_h;
    Oi = 1;
    }
    
else if (s >=cross_size && s <=1-cross_size)
    {    
    surfcolor = cross_color_v;
    Oi = 1;
    }
  
  
/* STEP 1 - set the apparent surface opacity */
//Oi = Os * opacity;
  
/* STEP 2 - calculate the apparent surface color */
Ci = Oi * Cs * surfcolor * Kfb;
}