[Bf-committers] Another interface_draw.c question: vec[7][2]

Lukas Steiblys imbusy at imbusy.org
Sat Sep 12 22:58:38 CEST 2009


Use a calculator. Taking arcsin of the first value of each pair and 
calculating the steps gives an average of 11.27059... degrees, or 
approximately 90 degrees divided by 8.
> Hi,
>
> In interface_draw.c I see a couple of  this arrays that are used to draw 
> rounded rectangles;
> float vec[7][2]= {{0.195, 0.02}, {0.383, 0.067}, {0.55, 0.169}, {0.707, 
> 0.293},
>                       {0.831, 0.45}, {0.924, 0.617}, {0.98, 0.805}};
>
>
> I'm wondering where these numbers came from? Probably it's a cached 
> results of cos(angle)/sin(angle).
> But what angle stepsize is used then?
>
> Roxlu
> _______________________________________________
> Bf-committers mailing list
> Bf-committers at blender.org
> http://lists.blender.org/mailman/listinfo/bf-committers
>
>   


-- 
Lukas Steiblys
http://imbusy.org



More information about the Bf-committers mailing list