Fix -Wreorder warnings
This commit is contained in:
parent
522ab7be39
commit
bf3232d790
2 changed files with 15 additions and 6 deletions
15
Ball.cpp
15
Ball.cpp
|
@ -1,9 +1,18 @@
|
||||||
#include "Ball.hpp"
|
#include "Ball.hpp"
|
||||||
#include <cmath>
|
#include <cmath>
|
||||||
|
|
||||||
Ball::Ball(Point& _center, double _p, double _q) : Center(_center),
|
Ball::Ball(Point& _center, double _p, double _q) :
|
||||||
init_h(_center.z), bounce_number(0), crt_time(0), T(0), A(_center.z), B(0),
|
Center(_center),
|
||||||
U(sqrt(2 * G_CTE * _center.z)), surface(_center, _p, _q) {}
|
surface(_center, _p, _q),
|
||||||
|
init_h(_center.z),
|
||||||
|
bounce_number(0),
|
||||||
|
crt_time(0),
|
||||||
|
A(_center.z),
|
||||||
|
B(0),
|
||||||
|
U(sqrt(2 * G_CTE * _center.z)),
|
||||||
|
T(0)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
void Ball::_compute_pos() {
|
void Ball::_compute_pos() {
|
||||||
Center.x = A + B * crt_time - (G_CTE / 2) * crt_time * crt_time;
|
Center.x = A + B * crt_time - (G_CTE / 2) * crt_time * crt_time;
|
||||||
|
|
|
@ -28,9 +28,9 @@ class Spheroid : public ImplicitSurface {
|
||||||
* V is the volume. Extremely useful to have a constant volume in the
|
* V is the volume. Extremely useful to have a constant volume in the
|
||||||
* ball
|
* ball
|
||||||
**/
|
**/
|
||||||
size_t stiffness;
|
|
||||||
double p, q;
|
|
||||||
double V;
|
|
||||||
Point& center;
|
Point& center;
|
||||||
|
double p, q;
|
||||||
|
size_t stiffness;
|
||||||
|
double V;
|
||||||
void _compute_volume();
|
void _compute_volume();
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue