diff --git a/empennage_design/src/taw/conventional/low/lowConventionalEmpennageDesignPlot.cpp b/empennage_design/src/taw/conventional/low/lowConventionalEmpennageDesignPlot.cpp index 8f074b052526045ca7b46ce017fcb116c605bb8d..952e9c0361373af1cb7e32f14cb3d1a23a37f835 100644 --- a/empennage_design/src/taw/conventional/low/lowConventionalEmpennageDesignPlot.cpp +++ b/empennage_design/src/taw/conventional/low/lowConventionalEmpennageDesignPlot.cpp @@ -110,6 +110,10 @@ fs::path Conventional::plot_stabilizer_planform( const geom2::MultisectionSurface<geom2::AirfoilSection>& surface, const std::vector<geom2::MultisectionSurface<geom2::PolygonSection>>& spars, const std::vector<geom2::MultisectionSurface<geom2::PolygonSection>>& devices) { + /* Plot active */ + if (!rtIO->plotOn) { + return ""; + } auto coordinates_xy = geom2::transform::outline_2d(surface, geom2::Direction_3(0, 0, 1)); std::deque<double> spanwise; std::deque<double> chordwise; @@ -185,7 +189,7 @@ fs::path Conventional::plot_stabilizer_planform( ax->xlabel("y [m]"); ax->ylabel("x [m]"); } - + ax->limits_mode(matplot::manual); ax->axis(matplot::equal); if (is_vertical) { @@ -208,6 +212,10 @@ fs::path Conventional::plot_stabilizer_planform( fs::path Conventional::plot_thickness_and_twist_distribution( const geom2::MultisectionSurface<geom2::AirfoilSection>& surface) { + /* Plot active */ + if (rtIO->plotOn) { + return ""; + } std::vector<double> eta; std::vector<double> thickness_to_chord_ratio; std::vector<double> twist; @@ -250,6 +258,10 @@ fs::path Conventional::plot_thickness_and_twist_distribution( * \return fs::path */ std::vector<fs::path> Conventional::plot_airfoils(const geom2::MultisectionSurface<geom2::AirfoilSection>& surface) { + /* Plot active */ + if (!rtIO->plotOn) { + return {""}; + } std::map<std::string, std::vector<geom2::Point_2>> airfoils_data{}; std::vector<fs::path> airfoil_plots_path; @@ -295,4 +307,4 @@ std::vector<fs::path> Conventional::plot_airfoils(const geom2::MultisectionSurfa } } // namespace low -} // namespace taw \ No newline at end of file +} // namespace taw