void btParticlesDynamicsWorld::postInitDeviceData() { m_hashSize = getMaxPowOf2(m_numParticles); createVBO(); allocateBuffers(); adjustGrid(); grabSimulationData(); }
/* fdp_tLayout: * Given graph g with ports nodes, layout g respecting ports. * If some node have position information, it may be useful to * reset temperature and other parameters to reflect this. */ void fdp_tLayout (graph_t* g, xparams* xpms) { int i; int reset; bport_t* pp = PORTS(g); double temp; Grid* grid; pointf ctr; Agnode_t* n; reset = init_params(g, xpms); temp = T0; ctr = initPositions (g, pp); if (T_useGrid) { grid = mkGrid (agnnodes (g)); adjustGrid (grid, agnnodes (g)); for (i = 0; i < loopcnt; i++) { temp = cool (temp, i); gAdjust (g, temp, pp, grid); } delGrid (grid); } else { for (i = 0; i < loopcnt; i++) { temp = cool (temp, i); adjust (g, temp, pp); } } if ((ctr.x != 0.0) || (ctr.y != 0.0)) { for (n = agfstnode(g); n; n = agnxtnode(g,n)) { ND_pos(n)[0] += ctr.x; ND_pos(n)[1] += ctr.y; } } dumpstat (g); if (reset) reset_params (); }