You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The line 527 in file btSoftBody.cpp looks kindof suspicious to me: if (btSoftBody::eAeroModel::V_TwoSided)
This produces compiler warning C4127 as it is a constant conditional expression.
Usally I'd assume this is so that the following line could be disabled at compile time, but that is usually done using a #define, right?
The definition of btSoftBody::eAeroModel then lets me continue doubting that this is actually correct in the context.
struct eAeroModel {
enum _ {
V_Point, ///Vertex normals are oriented toward velocity
V_TwoSided, ///Vertex normals are flipped to match velocity
V_TwoSidedLiftDrag, ///Vertex normals are flipped to match velocity and lift and drag forces are applied
V_OneSided, ///Vertex normals are taken as it is
F_TwoSided, ///Face normals are flipped to match velocity
F_TwoSidedLiftDrag, ///Face normals are flipped to match velocity and lift and drag forces are applied
F_OneSided, ///Face normals are taken as it is
END
};
};
To disable line 528 you would have to switch V_Point and V_TwoSided, right?
This discussion was converted from issue #1269 on April 26, 2021 03:53.
Heading
Bold
Italic
Quote
Code
Link
Numbered list
Unordered list
Task list
Attach files
Mention
Reference
Menu
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
The line 527 in file btSoftBody.cpp looks kindof suspicious to me:
if (btSoftBody::eAeroModel::V_TwoSided)
This produces compiler warning C4127 as it is a constant conditional expression.
Usally I'd assume this is so that the following line could be disabled at compile time, but that is usually done using a #define, right?
The definition of btSoftBody::eAeroModel then lets me continue doubting that this is actually correct in the context.
To disable line 528 you would have to switch V_Point and V_TwoSided, right?
I have changed it in my copy to this:
This makes a lot more sense to me.
If any issues arrise from this change I will for sure comment again.
EDIT: Same thing in line 622
Beta Was this translation helpful? Give feedback.
All reactions