예제 #1
0
void
ooFlightRecorderStep(OOflightrecorder *fr, float dt)
{
  double currentSimTime = sim_time_get_jd();

  // Time
  double_array_push(&fr->data, currentSimTime);

  // Position
  double_array_push(&fr->data, 0.0);
  double_array_push(&fr->data, 0.0);
  double_array_push(&fr->data, 0.0);

  // Quaternion
  double_array_push(&fr->data, 0.0);
  double_array_push(&fr->data, 0.0);
  double_array_push(&fr->data, 0.0);
  double_array_push(&fr->data, 0.0);
}
예제 #2
0
inline void sparse_matrix_append(sparse_matrix_t *self, uint32_t col, double val) {
    uint32_array_push(self->indices, col);
    double_array_push(self->data, val);
    if (col >= self->n) self->n = col + 1;
}