|
|
|||
File indexing completed on 2025-12-17 09:38:03
0001 // This file is part of the actsvg package. 0002 // 0003 // Copyright (C) 2022 CERN for the benefit of the ACTS project 0004 // 0005 // This Source Code Form is subject to the terms of the Mozilla Public 0006 // License, v. 2.0. If a copy of the MPL was not distributed with this 0007 // file, You can obtain one at http://mozilla.org/MPL/2.0/. 0008 0009 #pragma once 0010 0011 #include <array> 0012 #include <cmath> 0013 #include <vector> 0014 0015 #include "defs.hpp" 0016 0017 namespace actsvg { 0018 0019 namespace generators { 0020 0021 /** Generate phi values, respecting phi boundaries 0022 * 0023 * @param start_phi is the start for the arc generation 0024 * @param end_phi is the end of the arc generation 0025 * @param lseg is the number of segments used to generate the arc 0026 * 0027 * @return a vector of phi values for the arc 0028 */ 0029 std::vector<scalar> phi_values(scalar start_phi, scalar end_phi, 0030 unsigned int lseg); 0031 0032 /** Generate a contour for a sector 0033 * 0034 * @param inner_r is the inner radius 0035 * @param outer_r is the outer radius 0036 * @param start_phi is the start for the arc generation 0037 * @param end_phi is the end of the arc generation 0038 * @param lseg is the number of segments to approximate the arc 0039 * 0040 * @note this contour generation DOES NOT perform the y flip 0041 * @note start/end are respected in terms of orientation 0042 * 0043 **/ 0044 std::vector<point2> sector_contour(scalar inner_r, scalar outer_r, 0045 scalar start_phi, scalar end_phi, 0046 unsigned int lseg = 16); 0047 } // namespace generators 0048 0049 } // namespace actsvg
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|