mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-28 07:48:37 -04:00
*** empty log message ***
This commit is contained in:
parent
44a2efc45c
commit
8a63a62984
@ -1,6 +1,6 @@
|
||||
// Filename: LinearEulerIntegrator.cxx
|
||||
// Created by: charles (13Jun00)
|
||||
//
|
||||
//
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include "linearEulerIntegrator.h"
|
||||
@ -31,13 +31,13 @@ LinearEulerIntegrator::
|
||||
////////////////////////////////////////////////////////////////////
|
||||
// Function : Integrate
|
||||
// Access : Public
|
||||
// Description : Integrate a step of motion (based on dt) by
|
||||
// applying every force in force_vec to every object
|
||||
// Description : Integrate a step of motion (based on dt) by
|
||||
// applying every force in force_vec to every object
|
||||
// in obj_vec.
|
||||
////////////////////////////////////////////////////////////////////
|
||||
void LinearEulerIntegrator::
|
||||
child_integrate(Physical *physical,
|
||||
vector< PT(LinearForce) >& forces,
|
||||
child_integrate(Physical *physical,
|
||||
vector< PT(LinearForce) >& forces,
|
||||
float dt) {
|
||||
vector< PT(PhysicsObject) >::const_iterator current_object_iter;
|
||||
|
||||
@ -58,7 +58,7 @@ child_integrate(Physical *physical,
|
||||
// should help.
|
||||
|
||||
current_object_iter = physical->get_object_vector().begin();
|
||||
for (; current_object_iter != physical->get_object_vector().end();
|
||||
for (; current_object_iter != physical->get_object_vector().end();
|
||||
current_object_iter++) {
|
||||
LVector3f md_accum_vec, non_md_accum_vec, accel_vec, vel_vec;
|
||||
LPoint3f pos;
|
||||
@ -121,10 +121,10 @@ child_integrate(Physical *physical,
|
||||
// go from force space to object space
|
||||
f = matrices[index++] * cur_force->get_vector(current_object);
|
||||
|
||||
// tally it into the accum vectors
|
||||
// tally it into the accum vectors
|
||||
if (cur_force->get_mass_dependent() == true)
|
||||
md_accum_vec += f;
|
||||
else
|
||||
else
|
||||
non_md_accum_vec += f;
|
||||
}
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
// Filename: LinearIntegrator.C
|
||||
// Created by: charles (02Aug00)
|
||||
//
|
||||
//
|
||||
////////////////////////////////////////////////////////////////////
|
||||
|
||||
#include <get_rel_pos.h>
|
||||
@ -45,7 +45,7 @@ integrate(Physical *physical, vector< PT(LinearForce) > &forces,
|
||||
|
||||
vector< PT(PhysicsObject) >::const_iterator current_object_iter;
|
||||
current_object_iter = physical->get_object_vector().begin();
|
||||
for (; current_object_iter != physical->get_object_vector().end();
|
||||
for (; current_object_iter != physical->get_object_vector().end();
|
||||
current_object_iter++) {
|
||||
PhysicsObject *current_object = *current_object_iter;
|
||||
|
||||
@ -53,7 +53,7 @@ integrate(Physical *physical, vector< PT(LinearForce) > &forces,
|
||||
// processed.
|
||||
if (current_object == (PhysicsObject *) NULL)
|
||||
continue;
|
||||
|
||||
|
||||
// set the object's last position to its current position before we move it
|
||||
current_object->set_last_position(current_object->get_position());
|
||||
|
||||
|
@ -66,24 +66,24 @@
|
||||
/////////////////////////////////////////////////
|
||||
|
||||
// particle factory selection
|
||||
//#define POINT_PARTICLES
|
||||
#define ZSPIN_PARTICLES
|
||||
#define POINT_PARTICLES
|
||||
//#define ZSPIN_PARTICLES
|
||||
//#define ORIENTED_PARTICLES
|
||||
|
||||
// particle renderer selection
|
||||
#define POINT_PARTICLE_RENDERER
|
||||
//#define POINT_PARTICLE_RENDERER
|
||||
//#define LINE_PARTICLE_RENDERER
|
||||
//#define SPARKLE_PARTICLE_RENDERER
|
||||
//#define SPRITE_PARTICLE_RENDERER
|
||||
#define SPRITE_PARTICLE_RENDERER
|
||||
//#define GEOM_PARTICLE_RENDERER
|
||||
|
||||
// particle emitter selection
|
||||
//#define BOX_EMITTER
|
||||
//#define DISC_EMITTER
|
||||
#define DISC_EMITTER
|
||||
//#define LINE_EMITTER
|
||||
//#define POINT_EMITTER
|
||||
//#define RECTANGLE_EMITTER
|
||||
#define RING_EMITTER
|
||||
//#define RING_EMITTER
|
||||
//#define SPHERE_SURFACE_EMITTER
|
||||
//#define SPHERE_VOLUME_EMITTER
|
||||
//#define TANGENT_RING_EMITTER
|
||||
@ -434,10 +434,10 @@ event_add_particles(CPT_Event) {
|
||||
#endif
|
||||
#ifdef EMISSION_TYPE_CUSTOM
|
||||
#ifdef DISC_EMITTER_OUTER_ANGLE
|
||||
pe->set_outer_aoe(DISC_EMITTER_OUTER_ANGLE);
|
||||
pe->set_outer_angle(DISC_EMITTER_OUTER_ANGLE);
|
||||
#endif
|
||||
#ifdef DISC_EMITTER_INNER_ANGLE
|
||||
pe->set_inner_aoe(DISC_EMITTER_INNER_ANGLE);
|
||||
pe->set_inner_angle(DISC_EMITTER_INNER_ANGLE);
|
||||
#endif
|
||||
#ifdef DISC_EMITTER_OUTER_MAGNITUDE
|
||||
pe->set_outer_magnitude(DISC_EMITTER_OUTER_MAGNITUDE);
|
||||
|
Loading…
x
Reference in New Issue
Block a user