Scene graph draw options#1279
Conversation
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1279 +/- ##
=======================================
Coverage 72.55% 72.55%
=======================================
Files 315 315
Lines 27540 27561 +21
=======================================
+ Hits 19982 19998 +16
- Misses 7558 7563 +5
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
joergbrech
left a comment
There was a problem hiding this comment.
Thanks! This looks great! I noticed a few things.
- When selecting "Show the complete aircraft with duct cutouts, the aircraft is generated a few times in a succession. This happens also with draw options that open a dialog: The dialog opens several times.
- The Draw Options entry exists also for geometries, that have no options, such as engines or engine pylons. The drop down menu is empty.
- There are some draw options that I would remove from the drop down, e.g. "Draw Control Point Net", "Show intersection line" and "Draw any component". I feel like these are not a property of the aircraft geometry but a separate function that should be kept in a menu.
- Some draw options could be disabled/excluded from the drop down, if they are not defined (far field, systems, ducts, flaps, structure)
- The draw options are all called "Show ...". IMHO we can remove the "Show".
- When selecting "Show Fuselage Profile" and then choosing another draw option for the fuselage, the profile is not removed.
- When selecting "Show Wing Profiles" and then choosing another draw option nothing happens. I am stuck on the profile view.
- When selecting "Show Wing Component segment points" a dialog for the eta xsi coordinaes appear several times. Maybe we can remove this draw option and just keep it in the menu?
- Please add a changelog entry.
| /** | ||
| * @brief Returns the mirrored loft at the wings symmetry plane | ||
| * @param input_shape Shape to be mirrored with the wings symmetry | ||
| * @return PNamedShape | ||
| */ |
There was a problem hiding this comment.
Eventhough we talked about this, now that some time has past I find this function a bit confusing. Why does it take an argument? What happens if the argument is nullptr? I think this function could use more explaining documentation.
| std::string mirrorName = mirroredShape->Name(); | ||
| mirrorName += "M"; | ||
| std::string mirrorShortName = mirroredShape->ShortName(); | ||
| mirrorShortName += "M"; | ||
| mirroredShape->SetName(mirrorName.c_str()); | ||
| mirroredShape->SetShortName(mirrorShortName.c_str()); |
There was a problem hiding this comment.
I think we agreed on a different suffix for mirrored uids? :mirrored
|
|
||
| // for (const auto& action : getDrawOptionsActions()) { | ||
| // QAction* act = findChild<QAction*>(action.name); | ||
| // if (act) { | ||
| // connect(act, &QAction::triggered, this, [this, action]() { | ||
| // action.handler(currentUid); // Pass the UID | ||
| // }); | ||
| // } | ||
| // } |
There was a problem hiding this comment.
dev artifact?
| // for (const auto& action : getDrawOptionsActions()) { | |
| // QAction* act = findChild<QAction*>(action.name); | |
| // if (act) { | |
| // connect(act, &QAction::triggered, this, [this, action]() { | |
| // action.handler(currentUid); // Pass the UID | |
| // }); | |
| // } | |
| // } |
| void drawWingComponentSegmentPoints(const QString& wingUID=nullptr); | ||
| void drawWingShells(const QString& wingUID=nullptr); | ||
| void drawWingFlaps(const QString& wingUID=nullptr); | ||
| void drawWingStructure(const QString& wingUID=nullptr); |
There was a problem hiding this comment.
Why nullptr default argument? I am surprised we can convert a nullptr to a const QString& without compiler error in the first place.
Why do we need a default argument?
| void drawFuselage(const QString& Uid=nullptr); | ||
| void drawFuselageTriangulation(const QString& Uid=nullptr); | ||
| void drawFuselageSamplePoints(const QString& Uid=nullptr); | ||
| void drawFuselageSamplePointsAngle(const QString& Uid=nullptr); | ||
| void drawFusedFuselage(const QString& Uid=nullptr); | ||
| void drawFuselageGuideCurves(const QString& Uid=nullptr); |
There was a problem hiding this comment.
See above. Why the nullptr default argument?
|
|
||
| // Rotor selection dialogs | ||
| QString dlgGetRotorSelection(); | ||
| QString dlgGetRotorSelection(const QString& rotorUid=nullptr); |
There was a problem hiding this comment.
See above. Why the nullptr default argument?
| QString dlgGetRotorBladeSelection(const QString& rotorBladeUid=nullptr); | ||
| QString dlgGetRotorBladeComponentSegmentSelection(const QString& rotorBladeCompSegUid=nullptr); |
There was a problem hiding this comment.
See above. Why the nullptr default argument?
|
|
||
| // Fuselage selection dialogs | ||
| QString dlgGetFuselageSelection(); | ||
| QString dlgGetFuselageSelection(const QString& Uid=nullptr); |
There was a problem hiding this comment.
See above. Why the nullptr default argument?
| for (int j = 1; j <= wing.GetComponentSegmentCount(); ++j) { | ||
| tigl::CCPACSWingComponentSegment& cs = wing.GetComponentSegment(j); | ||
|
|
||
| if (auto& teds = cs.GetControlSurfaces()->GetTrailingEdgeDevices()) { |
There was a problem hiding this comment.
Do we have to check if the cs has control surfaces in the first place?
| } | ||
| } | ||
| } | ||
| if (auto& leds = cs.GetControlSurfaces()->GetLeadingEdgeDevices()) { |
There was a problem hiding this comment.
See above. What if the cs has no control surfaces?
In this PR the draw options are introduced to the display options.
This makes it easy for the user to display the flaps or e.g. the triangulation.
Description
How Has This Been Tested?
Screenshots, that help to understand the changes(if applicable):
Checklist: