Пример #1
0
 // Creating deflections arrays for n bristles
 // At the start no bristle is deflected
 // 2D array : bristle deflection on x (deflections[i][0]) and y (deflections[i][1])
 void deflectionsInit(int n)
 {
     deflections = new defl_struct[n];
     for (int i = 0; i < n; i++)
     {
         deflections[i] = new defl_struct(0.0f, 0.0f);
     }
 }
Пример #2
0
 // Creating deflections arrays for n bristles
 // At the start no bristle is deflected
 // 2D array : bristle deflection on x (deflections[i][0]) and y (deflections[i][1])
 void deflectionsInit(int n)
 {
     deflections = new defl_struct[n];
     for (int i=0; i < n; i++)
     {
         deflections[i] = new defl_struct(0.0f, 0.0f);
     }
 }