Exemplo n.º 1
0
void HW3b::wave()
{
    getforce();
    getvelocity();
    getposition();
    initVertexBuffer();
    updateGL();
}
Exemplo n.º 2
0
void DL_pts::apply_restrictions(DL_largevector* lv) {
  DL_vector force;
  getforce(lv,&force);
  if (g_is_dyna) ((DL_dyna *)g)->applyforce(&p,g,&force);
  if (sg_is_dyna) {
    force.neg(&force);
    ((DL_dyna*)(surf->get_geo()))->applyforce(&sstf,surf->get_geo(),&force);
  }
}
Exemplo n.º 3
0
void wave(void)
{
    if (waving)
    {
        getforce();
        getvelocity();
        getposition();
        glutPostRedisplay();
    }
}
Exemplo n.º 4
0
/////////////////////////////////////////////////////////
// bang
//
/////////////////////////////////////////////////////////
void newWave :: bangMess(void)
{

		savepos();

		getvelocity();
		getposition();

		getFaceNorms();
        getVertNorms();

        getforce();
		getdamp();

}
Exemplo n.º 5
0
/***
 *** The timeout function. Often in animations,
 *** timeout functions are suitable for continous
 *** frame updates.
 ***/
static gboolean
timeout (GtkWidget *widget)
{
  GtkAllocation allocation;
  GdkWindow *window;
  getforce ();
  getvelocity ();
  getposition ();

  window = gtk_widget_get_window (widget);
  gtk_widget_get_allocation (widget, &allocation);

  /* Invalidate the whole window. */
  gdk_window_invalidate_rect (window, &allocation, FALSE);

  /* Update synchronously (fast). */
  gdk_window_process_updates (window, FALSE);

  return TRUE;
}
Exemplo n.º 6
0
void DL_pts::reactionforce(DL_vector *force) {
  getforce(F,force);
}