mirror of https://github.com/CGAL/cgal
Merge remote-tracking branch 'lrineau/CGAL-followup_PR_8170-lrineau' into Triangulation_3-CDT_3-lrineau
This commit is contained in:
commit
a2571bbab8
|
|
@ -0,0 +1,35 @@
|
|||
---
|
||||
Language: Cpp
|
||||
BasedOnStyle: LLVM
|
||||
AccessModifierOffset: -2
|
||||
AllowShortFunctionsOnASingleLine: true
|
||||
BinPackParameters: false
|
||||
BreakConstructorInitializers: BeforeComma
|
||||
BreakBeforeBraces: Custom
|
||||
BraceWrapping:
|
||||
AfterCaseLabel: false
|
||||
AfterClass: true
|
||||
AfterControlStatement: MultiLine
|
||||
AfterEnum: false
|
||||
AfterFunction: false
|
||||
AfterNamespace: false
|
||||
AfterObjCDeclaration: false
|
||||
AfterStruct: true
|
||||
AfterUnion: false
|
||||
AfterExternBlock: false
|
||||
BeforeCatch: false
|
||||
BeforeElse: false
|
||||
BeforeLambdaBody: false
|
||||
BeforeWhile: false
|
||||
IndentBraces: false
|
||||
SplitEmptyFunction: false
|
||||
SplitEmptyRecord: false
|
||||
SplitEmptyNamespace: false
|
||||
ColumnLimit: 120
|
||||
# Force pointers to the type for C++.
|
||||
DerivePointerAlignment: false
|
||||
PointerAlignment: Left
|
||||
# Control the spaces around conditionals
|
||||
SpacesInConditionalStatement: false
|
||||
SpaceBeforeParens: false
|
||||
...
|
||||
|
|
@ -0,0 +1,55 @@
|
|||
# Use an official Fedora as a parent image for the build stage
|
||||
FROM fedora:latest AS sources_deps
|
||||
|
||||
# Set environment variables to non-interactive
|
||||
ENV DEBIAN_FRONTEND=noninteractive
|
||||
|
||||
# Install dependencies
|
||||
RUN dnf update -y && dnf install -y \
|
||||
wget \
|
||||
make \
|
||||
gcc \
|
||||
gcc-c++ \
|
||||
patch \
|
||||
cmake \
|
||||
bison \
|
||||
flex \
|
||||
unzip \
|
||||
python3 \
|
||||
&& dnf clean all
|
||||
|
||||
# Copy the patch file to the build context
|
||||
COPY cgal-NO_ADDITIONAL_DETAILS.patch .
|
||||
|
||||
FROM sources_deps AS build
|
||||
|
||||
# Build and install Doxygen from sources
|
||||
ARG DOXYGEN_VERSION=1.9.6
|
||||
ARG MAKEFLAGS=-j$(nproc)
|
||||
RUN if [ -n "$DEBUG"];then set -x && make --version && ls -lZ /tmp && id; fi \
|
||||
&& DOXYGEN_VERSION_UNDERSCORE=$(echo ${DOXYGEN_VERSION} | sed 's/\./_/g') \
|
||||
&& wget https://github.com/doxygen/doxygen/archive/refs/tags/Release_${DOXYGEN_VERSION_UNDERSCORE}.zip \
|
||||
&& unzip Release_${DOXYGEN_VERSION_UNDERSCORE}.zip \
|
||||
&& cd doxygen-Release_${DOXYGEN_VERSION_UNDERSCORE} \
|
||||
&& patch -p1 < ../cgal-NO_ADDITIONAL_DETAILS.patch \
|
||||
&& mkdir build \
|
||||
&& cd build \
|
||||
&& cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release .. \
|
||||
&& cmake --build . \
|
||||
&& cmake --install . \
|
||||
&& mkdir -p /usr/local/share/doc/doxygen && cp ../LICENSE /usr/local/share/doc/doxygen/LICENSE.TXT \
|
||||
&& cd ../.. \
|
||||
&& rm -rf doxygen-Release_${DOXYGEN_VERSION_UNDERSCORE} Release_${DOXYGEN_VERSION_UNDERSCORE}.zip
|
||||
|
||||
# Use a smaller base image for the final stage
|
||||
FROM fedora:latest
|
||||
|
||||
# Install necessary runtime dependencies
|
||||
RUN set -x \
|
||||
&& dnf update -y && dnf install -y graphviz 'perl(Getopt::Std)' tex-bibtex cmake python3-lxml python3-pyquery \
|
||||
&& dnf clean all
|
||||
|
||||
# Copy Doxygen from the build stage
|
||||
COPY --from=build /usr/local/bin/doxygen /usr/local/bin
|
||||
COPY --from=build /usr/local/share/doc/doxygen/LICENSE.TXT /usr/local/share/doc/doxygen/LICENSE.TXT
|
||||
RUN doxygen --version
|
||||
|
|
@ -0,0 +1,23 @@
|
|||
SHELL := /bin/bash
|
||||
DOXYGEN_VERSIONS := 1.12.0 1.11.0 1.10.0 1.9.8 1.9.7 1.9.6
|
||||
|
||||
.PHONY: all build-% push-% build push
|
||||
|
||||
all: build
|
||||
@echo "Use `$(MAKE) push` to push the images to the registry."
|
||||
|
||||
build-%:
|
||||
@echo "MAKEFLAGS: $(MAKEFLAGS)"
|
||||
@echo "Building Doxygen version $*..."
|
||||
if [ "$$(getenforce || true)" == "Enforcing" ]; then Z=:z; else Z=; fi; \
|
||||
F="$(MAKEFLAGS)"; F=$${F##*fifo:}; F=$${F%% *}; \
|
||||
if [ -p "$$F" ]; then echo "The GNU make FIFO file exists:"; ls -l $$F; VOLUME_ARGS="-v $$F:$$F$$Z"; echo -- $$VOLUME_ARGS; fi; \
|
||||
podman build --build-arg DOXYGEN_VERSION=$* --build-arg "MAKEFLAGS=$(MAKEFLAGS)" $$VOLUME_ARGS -t cgal/doxygen:$* .
|
||||
|
||||
push-%: build-%
|
||||
@echo "Pushing cgal/doxygen:$*..."
|
||||
podman push cgal/doxygen:$*
|
||||
|
||||
build: $(foreach version,$(DOXYGEN_VERSIONS),build-$(version))
|
||||
|
||||
push: $(foreach version,$(DOXYGEN_VERSIONS),push-$(version))
|
||||
|
|
@ -0,0 +1,44 @@
|
|||
diff --git a/src/config.xml b/src/config.xml
|
||||
index 13910958a6..31f1354e44 100644
|
||||
--- a/src/config.xml
|
||||
+++ b/src/config.xml
|
||||
@@ -893,6 +893,18 @@ Go to the <a href="commands.html">next</a> section or return to the
|
||||
\note This will also disable the warnings about undocumented members
|
||||
that are normally produced when \ref cfg_warnings "WARNINGS" is
|
||||
set to \c YES.
|
||||
+]]>
|
||||
+ </docs>
|
||||
+ </option>
|
||||
+ </group>
|
||||
+ <group name='Build' docs='Build related configuration options'>
|
||||
+ <option type='bool' id='NO_ADDITIONAL_DETAILS' defval='0'>
|
||||
+ <docs>
|
||||
+<![CDATA[
|
||||
+ When the \c EXTRACT_ALL tag is set to \c YES and a member or class
|
||||
+ as no documentation, no detailed section will be produced if
|
||||
+ the \c NO_ADDITIONAL_DETAILS tag is set to \c YES.
|
||||
+ This tag has no effect if the \c EXTRACT_ALL tag is set to \c NO.
|
||||
]]>
|
||||
</docs>
|
||||
</option>
|
||||
diff --git a/src/memberdef.cpp b/src/memberdef.cpp
|
||||
index 08d9bf24c5..ab04e994c5 100644
|
||||
--- a/src/memberdef.cpp
|
||||
+++ b/src/memberdef.cpp
|
||||
@@ -2501,6 +2501,7 @@ bool MemberDefImpl::hasDetailedDescription() const
|
||||
if (!m_hasDetailedDescriptionCached)
|
||||
{
|
||||
bool extractAll = Config_getBool(EXTRACT_ALL);
|
||||
+ bool xAllNoDetailedSec = Config_getBool(NO_ADDITIONAL_DETAILS);
|
||||
bool alwaysDetailedSec = Config_getBool(ALWAYS_DETAILED_SEC);
|
||||
bool repeatBrief = Config_getBool(REPEAT_BRIEF);
|
||||
bool briefMemberDesc = Config_getBool(BRIEF_MEMBER_DESC);
|
||||
@@ -2512,7 +2513,7 @@ bool MemberDefImpl::hasDetailedDescription() const
|
||||
// the member has detailed documentation because the user added some comments
|
||||
bool docFilter =
|
||||
// extract all is enabled
|
||||
- extractAll ||
|
||||
+ (extractAll && !xAllNoDetailedSec) ||
|
||||
// has detailed docs
|
||||
!documentation().isEmpty() ||
|
||||
// has inbody docs
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
"name": "CGAL Doxygen Dev Container, version 1.12.0, with CGAL patch",
|
||||
"image": "docker.io/cgal/doxygen:1.12.0",
|
||||
"features": {
|
||||
"ghcr.io/devcontainers/features/git:1.3.2": {}
|
||||
},
|
||||
"customizations": {
|
||||
"vscode": {
|
||||
"extensions": [
|
||||
"ms-vscode.cmake-tools",
|
||||
"bbenoist.Doxygen",
|
||||
"ms-vscode.cpptools"
|
||||
]
|
||||
}
|
||||
},
|
||||
}
|
||||
|
|
@ -0,0 +1,29 @@
|
|||
[distrobox-doxygen-1.12.0]
|
||||
image=cgal/doxygen:1.12.0
|
||||
exported_bins="/usr/local/bin/doxygen /usr/bin/perl /usr/bin/cmake /usr/bin/python3"
|
||||
exported_bins_path=$HOME/.local/bin-doxygen-1.12.0
|
||||
|
||||
[distrobox-doxygen-1.11.0]
|
||||
image=cgal/doxygen:1.11.0
|
||||
exported_bins="/usr/local/bin/doxygen /usr/bin/perl /usr/bin/cmake /usr/bin/python3"
|
||||
exported_bins_path=$HOME/.local/bin-doxygen-1.11.0
|
||||
|
||||
[distrobox-doxygen-1.10.0]
|
||||
image=cgal/doxygen:1.10.0
|
||||
exported_bins="/usr/local/bin/doxygen /usr/bin/perl /usr/bin/cmake /usr/bin/python3"
|
||||
exported_bins_path=$HOME/.local/bin-doxygen-1.10.0
|
||||
|
||||
[distrobox-doxygen-1.9.8]
|
||||
image=cgal/doxygen:1.9.8
|
||||
exported_bins="/usr/local/bin/doxygen /usr/bin/perl /usr/bin/cmake /usr/bin/python3"
|
||||
exported_bins_path=$HOME/.local/bin-doxygen-1.9.8
|
||||
|
||||
[distrobox-doxygen-1.9.7]
|
||||
image=cgal/doxygen:1.9.7
|
||||
exported_bins="/usr/local/bin/doxygen /usr/bin/perl /usr/bin/cmake /usr/bin/python3"
|
||||
exported_bins_path=$HOME/.local/bin-doxygen-1.9.7
|
||||
|
||||
[distrobox-doxygen-1.9.6]
|
||||
image=cgal/doxygen:1.9.6
|
||||
exported_bins="/usr/local/bin/doxygen /usr/bin/perl /usr/bin/cmake /usr/bin/python3"
|
||||
exported_bins_path=$HOME/.local/bin-doxygen-1.9.6
|
||||
|
|
@ -44,11 +44,9 @@ Documentation/Doxyfile text eol=lf
|
|||
Documentation/pkglist_filter text eol=lf
|
||||
Installation/update_CHANGES text eol=lf
|
||||
Scripts/developer_scripts/autotest_cgal text eol=lf
|
||||
Scripts/developer_scripts/autotest_cgal_with_cmake text eol=lf
|
||||
Scripts/developer_scripts/cgal_build text eol=lf
|
||||
Scripts/developer_scripts/cgal_depend text eol=lf
|
||||
Scripts/developer_scripts/cgal_git_update_hooks_for_client text eol=lf
|
||||
Scripts/developer_scripts/cgal_test_with_cmake text eol=lf
|
||||
Scripts/developer_scripts/cgal2gml text eol=lf
|
||||
Scripts/developer_scripts/check_library_uses_no_gpl_files text eol=lf
|
||||
Scripts/developer_scripts/check_licenses text eol=lf
|
||||
|
|
@ -56,7 +54,6 @@ Scripts/developer_scripts/check_macro_names text eol=lf
|
|||
Scripts/developer_scripts/check_no_CGAL_USE_without_includes_before text eol=lf
|
||||
Scripts/developer_scripts/check_svn_keywords text eol=lf
|
||||
Scripts/developer_scripts/create_cgal_test text eol=lf
|
||||
Scripts/developer_scripts/create_cgal_test_with_cmake text eol=lf
|
||||
Scripts/developer_scripts/create_internal_release text eol=lf
|
||||
Scripts/developer_scripts/create_new_release text eol=lf
|
||||
Scripts/developer_scripts/detect_files_with_mixed_eol_styles text eol=lf
|
||||
|
|
|
|||
|
|
@ -7,9 +7,8 @@ permissions:
|
|||
|
||||
jobs:
|
||||
build:
|
||||
|
||||
if: github.repository == 'CGAL/cgal' || github.event_name != 'push'
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: install dependencies
|
||||
|
|
@ -17,7 +16,7 @@ jobs:
|
|||
.github/install.sh
|
||||
set -x
|
||||
sudo apt-get update && sudo apt-get install -y graphviz ssh bibtex2html
|
||||
sudo pip install lxml
|
||||
sudo pip install lxml
|
||||
sudo pip install 'pyquery==1.4.1' # it seems to be the last py2 compatible version
|
||||
wget --no-verbose -O doxygen_exe https://cgal.geometryfactory.com/~cgaltest/doxygen_1_8_13_patched/doxygen
|
||||
sudo mv doxygen_exe /usr/bin/doxygen
|
||||
|
|
|
|||
|
|
@ -7,9 +7,8 @@ permissions:
|
|||
|
||||
jobs:
|
||||
cmake-testsuite:
|
||||
|
||||
if: github.repository == 'CGAL/cgal' || github.event_name != 'push'
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: install dependencies
|
||||
|
|
@ -21,9 +20,8 @@ jobs:
|
|||
ctest -L Installation -j $(getconf _NPROCESSORS_ONLN)
|
||||
|
||||
cmake-testsuite-with-qt:
|
||||
|
||||
if: github.repository == 'CGAL/cgal' || github.event_name != 'push'
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: install dependencies
|
||||
|
|
|
|||
|
|
@ -1,75 +0,0 @@
|
|||
name: Filter Testsuite
|
||||
|
||||
on:
|
||||
issue_comment:
|
||||
types: [created]
|
||||
workflow_dispatch:
|
||||
|
||||
permissions: {}
|
||||
jobs:
|
||||
build:
|
||||
permissions:
|
||||
pull-requests: write # to create comment
|
||||
|
||||
if: (github.event.comment.user.login == 'sloriot' || github.event.comment.user.login == 'lrineau') && contains(github.event.comment.body, '/testme')
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/github-script@v7
|
||||
id: get_label
|
||||
with:
|
||||
result-encoding: string
|
||||
script: |
|
||||
//get branch name and username
|
||||
const pr_url = context.payload.issue.pull_request.url
|
||||
const pr_content = await github.request(pr_url)
|
||||
const label = pr_content.data.head.label
|
||||
const base = pr_content.data.base.ref
|
||||
console.log(label)
|
||||
return label+":"+base
|
||||
- name: Run Testsuite
|
||||
run: |
|
||||
mkdir -p ~/.ssh
|
||||
#ssh key
|
||||
(
|
||||
cat <<EOF
|
||||
${{ secrets.ssh_key }}
|
||||
EOF
|
||||
)>> ~/.ssh/id_rsa
|
||||
chmod 600 /home/runner/.ssh/id_rsa
|
||||
#ssh public key
|
||||
(
|
||||
cat <<EOF
|
||||
${{ secrets.ssh_key_pub }}
|
||||
EOF
|
||||
)>> ~/.ssh/id_rsa.pub
|
||||
chmod 644 /home/runner/.ssh/id_rsa.pub
|
||||
#known hosts
|
||||
wget --no-check-certificate https://cgal.geometryfactory.com/CGAL/ssh_known_hosts -O ~/.ssh/known_hosts
|
||||
#config file
|
||||
wget --no-check-certificate https://cgal.geometryfactory.com/CGAL/ssh_config -O ~/.ssh/config
|
||||
#list of hosts
|
||||
wget --no-check-certificate https://cgal.geometryfactory.com/CGAL/ssh_host_list -O ~/ssh_host_list
|
||||
#ssh command
|
||||
LABEL="${{ steps.get_label.outputs.result }}"
|
||||
USER_NAME=$(echo $LABEL | cut -d':' -f 1)
|
||||
BRANCH_NAME=$(echo $LABEL | cut -d':' -f 2)
|
||||
BASE=$(echo $LABEL | cut -d':' -f 3)
|
||||
PR_NUMBER=${{ github.event.issue.number }}
|
||||
mapfile -t HOSTS < ~/ssh_host_list;
|
||||
for i in ${!HOSTS[@]}; do
|
||||
HOST=$(echo ${HOSTS[$i]}|cut -d' ' -f 1 )
|
||||
PATH_TO_SCRIPT=$(echo ${HOSTS[$i]}|cut -d' ' -f 2 )
|
||||
echo "ssh ${HOST} ${PATH_TO_SCRIPT}/run_testsuite_from_branch_name.sh $USER_NAME $BRANCH_NAME $BASE $PR_NUMBER"
|
||||
ssh ${HOST} "${PATH_TO_SCRIPT}/run_testsuite_from_branch_name.sh $USER_NAME $BRANCH_NAME $BASE $PR_NUMBER"
|
||||
done
|
||||
- name: Post address
|
||||
uses: actions/github-script@v7
|
||||
with:
|
||||
script: |
|
||||
const address = "Testsuite launched. Results will appear on the following page: https://cgal.geometryfactory.com/~cgaltest/test_suite/TESTRESULTS/index.shtml "
|
||||
github.issues.createComment({
|
||||
owner: "CGAL",
|
||||
repo: "cgal",
|
||||
issue_number: ${{ github.event.issue.number }},
|
||||
body: address
|
||||
});
|
||||
|
|
@ -8,7 +8,6 @@ AABB_tree/demo/AABB_tree/Makefile
|
|||
AABB_tree/examples/AABB_tree/*.kdev*
|
||||
AABB_tree/examples/AABB_tree/*_example
|
||||
AABB_tree/examples/AABB_tree/Makefile
|
||||
AABB_tree/examples/AABB_tree/cgal_test_with_cmake
|
||||
AABB_tree/test/AABB_tree/*.kdev*
|
||||
AABB_tree/test/AABB_tree/Makefile
|
||||
AABB_tree/test/AABB_tree/aabb_correctness_triangle_test
|
||||
|
|
@ -18,17 +17,14 @@ AABB_tree/test/AABB_tree/aabb_distance_triangle_test
|
|||
AABB_tree/test/AABB_tree/aabb_intersection_triangle_test
|
||||
AABB_tree/test/AABB_tree/aabb_naive_vs_tree_distance_segment_test
|
||||
AABB_tree/test/AABB_tree/aabb_projection_triangle_test
|
||||
AABB_tree/test/AABB_tree/cgal_test_with_cmake
|
||||
Algebraic_foundations/test/Algebraic_foundations/Algebraic_extension_traits
|
||||
Algebraic_foundations/test/Algebraic_foundations/Algebraic_structure_traits
|
||||
Algebraic_foundations/test/Algebraic_foundations/Chinese_remainder_traits
|
||||
Algebraic_foundations/test/Algebraic_foundations/Coercion_traits
|
||||
Algebraic_foundations/test/Algebraic_foundations/Real_embeddable_traits
|
||||
Algebraic_foundations/test/Algebraic_foundations/Scalar_factor_traits
|
||||
Algebraic_foundations/test/Algebraic_foundations/cgal_test_with_cmake
|
||||
Algebraic_foundations/test/Algebraic_foundations/extended_euclidean_algorithm
|
||||
Algebraic_foundations/test/Algebraic_foundations/ipower
|
||||
Algebraic_kernel_d/test/Algebraic_kernel_d/cgal_test_with_cmake
|
||||
Algebraic_kernel_d/test/Algebraic_kernel_d/rs_isolator
|
||||
Alpha_shapes_2/demo/Alpha_shapes_2/Makefile
|
||||
Alpha_shapes_2/demo/Alpha_shapes_2/alpha_shapes_2
|
||||
|
|
@ -37,7 +33,6 @@ Alpha_shapes_2/examples/Alpha_shapes_2/alpha_shapes_2
|
|||
Alpha_shapes_3/demo/Alpha_shapes_3/Makefile
|
||||
Alpha_shapes_3/demo/Alpha_shapes_3/alpha_shapes_3
|
||||
Alpha_shapes_3/demo/Alpha_shapes_3/weighted_alpha_shapes_3
|
||||
Alpha_shapes_3/test/Alpha_shapes_3/cgal_test_with_cmake
|
||||
Alpha_shapes_3/test/Alpha_shapes_3/test_alpha_shape_3
|
||||
Alpha_shapes_3/test/Alpha_shapes_3/test_fixed_alpha_shape_3
|
||||
Alpha_shapes_3/test/Alpha_shapes_3/test_weighted_alpha_shape_3
|
||||
|
|
@ -60,7 +55,6 @@ Arrangement_on_surface_2/examples/Arrangement_on_surface_2/batched_point_locatio
|
|||
Arrangement_on_surface_2/examples/Arrangement_on_surface_2/bgl_dual_adapter
|
||||
Arrangement_on_surface_2/examples/Arrangement_on_surface_2/bgl_primal_adapter
|
||||
Arrangement_on_surface_2/examples/Arrangement_on_surface_2/bounded_planar_vertical_decomposition
|
||||
Arrangement_on_surface_2/examples/Arrangement_on_surface_2/cgal_test_with_cmake
|
||||
Arrangement_on_surface_2/examples/Arrangement_on_surface_2/circles
|
||||
Arrangement_on_surface_2/examples/Arrangement_on_surface_2/circular_arcs
|
||||
Arrangement_on_surface_2/examples/Arrangement_on_surface_2/circular_line_arcs
|
||||
|
|
@ -103,30 +97,24 @@ Arrangement_on_surface_2/examples/Arrangement_on_surface_2/unbounded_rational_fu
|
|||
Arrangement_on_surface_2/examples/Arrangement_on_surface_2/vertical_ray_shooting
|
||||
Arrangement_on_surface_2/test/Arrangement_on_surface_2/test_point_location.cpp
|
||||
BGL/examples/BGL_arrangement_2/Makefile
|
||||
BGL/examples/BGL_arrangement_2/cgal_test_with_cmake
|
||||
BGL/examples/BGL_arrangement_2/dual
|
||||
BGL/examples/BGL_arrangement_2/primal
|
||||
BGL/test/BGL/cgal_test_with_cmake
|
||||
Boolean_set_operations_2/demo/Boolean_set_operations_2/Makefile
|
||||
Boolean_set_operations_2/demo/Boolean_set_operations_2/boolean_operations_2
|
||||
Box_intersection_d/test/Box_intersection_d/automated_test
|
||||
Box_intersection_d/test/Box_intersection_d/benchmark.data
|
||||
Box_intersection_d/test/Box_intersection_d/benchmark_box_intersection
|
||||
Box_intersection_d/test/Box_intersection_d/box_grid
|
||||
Box_intersection_d/test/Box_intersection_d/cgal_test_with_cmake
|
||||
Box_intersection_d/test/Box_intersection_d/random_set_test
|
||||
CGAL_ImageIO/demo/CGALimageIO/Makefile
|
||||
CGAL_ImageIO/demo/CGALimageIO/cgal_test_with_cmake
|
||||
CGAL_ImageIO/demo/CGALimageIO/image_to_vtk_viewer
|
||||
CGAL_ImageIO/examples/CGALimageIO/Makefile
|
||||
CGAL_ImageIO/examples/CGALimageIO/cgal_test_with_cmake
|
||||
CGAL_ImageIO/examples/CGALimageIO/convert_raw_image_to_inr
|
||||
CGAL_ImageIO/examples/CGALimageIO/makefile
|
||||
CGAL_ImageIO/examples/CGALimageIO/test_imageio
|
||||
CGAL_ImageIO/src/CGAL_ImageIO/Makefile
|
||||
Circular_kernel_3/demo/Circular_kernel_3/Circular_kernel_3_demo
|
||||
Circular_kernel_3/demo/Circular_kernel_3/Makefile
|
||||
Circular_kernel_3/test/Circular_kernel_3/cgal_test_with_cmake
|
||||
Circular_kernel_3/test/Circular_kernel_3/test_Exact_spherical_kernel
|
||||
Circular_kernel_3/test/Circular_kernel_3/test_Lazy_Spherical_kernel
|
||||
Circular_kernel_3/test/Circular_kernel_3/test_Lazy_spherical_kernel_basics
|
||||
|
|
@ -137,7 +125,6 @@ Documentation/log/*.*
|
|||
Documentation/output
|
||||
Documentation/tags/*.*
|
||||
Generator/examples/Generator/ball_d
|
||||
Generator/examples/Generator/cgal_test_with_cmake
|
||||
Generator/examples/Generator/cube_d
|
||||
Generator/examples/Generator/grid_d
|
||||
Generator/examples/Generator/random_convex_set
|
||||
|
|
@ -149,7 +136,6 @@ Generator/examples/Generator/random_segments1
|
|||
Generator/examples/Generator/random_segments2
|
||||
Generator/examples/Generator/sphere_d
|
||||
Generator/test/Generator/bug
|
||||
Generator/test/Generator/cgal_test_with_cmake
|
||||
Generator/test/Generator/random_poly_test
|
||||
Generator/test/Generator/rcs_test
|
||||
Generator/test/Generator/test_combination_enumerator
|
||||
|
|
@ -178,7 +164,6 @@ GraphicsView/demo/Triangulation_2/Makefile
|
|||
GraphicsView/demo/Triangulation_2/Regular_triangulation_2
|
||||
GraphicsView/demo/Triangulation_2/qrc_*.cxx
|
||||
GraphicsView/demo/Triangulation_2/ui_*.h
|
||||
HalfedgeDS/test/HalfedgeDS/cgal_test_with_cmake
|
||||
HalfedgeDS/test/HalfedgeDS/test_hds
|
||||
HalfedgeDS/test/HalfedgeDS/test_hds_decorator
|
||||
Inscribed_areas/test/Inscribed_areas/Makefile
|
||||
|
|
@ -188,11 +173,8 @@ Installation/auxiliary/gdb/python/CGAL/printers.pyc
|
|||
Installation/auxiliary/gdb/test
|
||||
Installation/cmake/modules/*.tmp
|
||||
Installation/test/Installation/cgal_test
|
||||
/Installation/test/Installation/cgal_test_with_cmake
|
||||
Installation/test/Installation/deprecation_warning
|
||||
Interpolation/demo/Interpolation/cgal_test_with_cmake
|
||||
Intersections_3/test/Intersections_3/bbox_other_do_intersect_test
|
||||
Intersections_3/test/Intersections_3/cgal_test_with_cmake
|
||||
Intersections_3/test/Intersections_3/circle_other
|
||||
Intersections_3/test/Intersections_3/line_line
|
||||
Intersections_3/test/Intersections_3/segment_segment
|
||||
|
|
@ -206,7 +188,6 @@ Jet_fitting_3/examples/Jet_fitting_3/Single_estimation
|
|||
Jet_fitting_3/examples/Jet_fitting_3/VC
|
||||
Jet_fitting_3/test/Jet_fitting_3/Makefile
|
||||
Jet_fitting_3/test/Jet_fitting_3/blind_1pt
|
||||
/Jet_fitting_3/examples/Jet_fitting_3/cgal_test_with_cmake
|
||||
/Jet_fitting_3/examples/Jet_fitting_3/data_ellipe0.003.off.4ogl.txt
|
||||
Kernel_23/test/Kernel_23/Cartesian
|
||||
Kernel_23/test/Kernel_23/Dimension
|
||||
|
|
@ -220,7 +201,6 @@ Kernel_23/test/Kernel_23/Simple_cartesian
|
|||
Kernel_23/test/Kernel_23/Simple_homogeneous
|
||||
Kernel_23/test/Kernel_23/Test_IO.out
|
||||
/Kernel_23/test/Kernel_23/Test-*IO.out
|
||||
Kernel_23/test/Kernel_23/cgal_test_with_cmake
|
||||
Kernel_23/test/Kernel_23/test_kernel__
|
||||
Kinetic_data_structures/demo/Kinetic_data_structures/Delaunay_triangulation_2
|
||||
Kinetic_data_structures/demo/Kinetic_data_structures/Delaunay_triangulation_stable_subset_2
|
||||
|
|
@ -229,13 +209,11 @@ Kinetic_data_structures/demo/Kinetic_data_structures/KDS_Delaunay_triangulation_
|
|||
Kinetic_data_structures/demo/Kinetic_data_structures/KDS_generate_data
|
||||
Kinetic_data_structures/demo/Kinetic_data_structures/KDS_gui_2
|
||||
Kinetic_data_structures/demo/Kinetic_data_structures/Makefile
|
||||
Kinetic_data_structures/demo/Kinetic_data_structures/cgal_test_with_cmake
|
||||
Kinetic_data_structures/demo/Kinetic_data_structures/generate_data
|
||||
Kinetic_data_structures/demo/Kinetic_data_structures/gui_2
|
||||
Kinetic_data_structures/test/Kinetic_data_structures/Delaunay_triangulation_2
|
||||
Kinetic_data_structures/test/Kinetic_data_structures/Delaunay_triangulation_3
|
||||
Kinetic_data_structures/test/Kinetic_data_structures/active_objects_tables
|
||||
Kinetic_data_structures/test/Kinetic_data_structures/cgal_test_with_cmake
|
||||
Kinetic_data_structures/test/Kinetic_data_structures/exact_kds
|
||||
Kinetic_data_structures/test/Kinetic_data_structures/instantaneous_kernel
|
||||
Kinetic_data_structures/test/Kinetic_data_structures/numbers
|
||||
|
|
@ -248,8 +226,6 @@ Kinetic_data_structures/test/Kinetic_data_structures/test_KDS_Delaunay_triangula
|
|||
Kinetic_data_structures/test/Kinetic_data_structures/timings
|
||||
Linear_cell_complex/demo/Linear_cell_complex/Linear_cell_complex_3.qrc.depends
|
||||
Linear_cell_complex/demo/Linear_cell_complex/Linear_cell_complex_3_demo
|
||||
Linear_cell_complex/demo/Linear_cell_complex/cgal_test_with_cmake
|
||||
Linear_cell_complex/examples/Linear_cell_complex/cgal_test_with_cmake
|
||||
Linear_cell_complex/examples/Linear_cell_complex/linear_cell_complex_3
|
||||
Linear_cell_complex/examples/Linear_cell_complex/linear_cell_complex_3_triangulation
|
||||
Linear_cell_complex/examples/Linear_cell_complex/linear_cell_complex_3_with_colored_vertices
|
||||
|
|
@ -297,7 +273,6 @@ Mesh_2/demo/Mesh_2/*.core
|
|||
Mesh_2/demo/Mesh_2/*.moc
|
||||
Mesh_2/demo/Mesh_2/.*.deps
|
||||
Mesh_2/demo/Mesh_2/Makefile
|
||||
Mesh_2/demo/Mesh_2/cgal_test_with_cmake
|
||||
Mesh_2/demo/Mesh_2/conform
|
||||
Mesh_2/demo/Mesh_2/depends
|
||||
Mesh_2/demo/Mesh_2/filename.edg
|
||||
|
|
@ -309,7 +284,6 @@ Mesh_2/demo/Mesh_2/semantic.cache
|
|||
Mesh_2/doxygen
|
||||
Mesh_2/examples/Mesh_2/*.core
|
||||
Mesh_2/examples/Mesh_2/.*.deps
|
||||
Mesh_2/examples/Mesh_2/cgal_test_with_cmake
|
||||
Mesh_2/examples/Mesh_2/conform
|
||||
Mesh_2/examples/Mesh_2/conforming
|
||||
Mesh_2/examples/Mesh_2/depends
|
||||
|
|
@ -324,7 +298,6 @@ Mesh_2/test/Mesh_2/*.core
|
|||
Mesh_2/test/Mesh_2/.*.deps
|
||||
Mesh_2/test/Mesh_2/Makefile
|
||||
Mesh_2/test/Mesh_2/bench_double_map
|
||||
Mesh_2/test/Mesh_2/cgal_test_with_cmake
|
||||
Mesh_2/test/Mesh_2/conform_plus
|
||||
Mesh_2/test/Mesh_2/depends
|
||||
Mesh_2/test/Mesh_2/my_makefile
|
||||
|
|
@ -373,7 +346,6 @@ Mesh_3/examples/Mesh_3/.*.deps
|
|||
Mesh_3/examples/Mesh_3/random-image.inr
|
||||
Mesh_3/examples/Mesh_3/Makefile
|
||||
Mesh_3/examples/Mesh_3/applications
|
||||
Mesh_3/examples/Mesh_3/cgal_test_with_cmake
|
||||
Mesh_3/examples/Mesh_3/cgal_to_medit
|
||||
Mesh_3/examples/Mesh_3/chair-after.mesh
|
||||
Mesh_3/examples/Mesh_3/chair-after.png
|
||||
|
|
@ -411,7 +383,6 @@ Mesh_3/examples/Mesh_3/test_off
|
|||
/Mesh_3/test/Mesh_3/a.lua
|
||||
/Mesh_3/test/Mesh_3/applications
|
||||
/Mesh_3/test/Mesh_3/*.cgal
|
||||
/Mesh_3/test/Mesh_3/cgal_test_with_cmake
|
||||
/Mesh_3/test/Mesh_3/cgal_to_medit
|
||||
/Mesh_3/test/Mesh_3/combined_spheres
|
||||
/Mesh_3/test/Mesh_3/combined_spheres-with-sphere-oracle
|
||||
|
|
@ -513,11 +484,9 @@ Min_ellipse_2/.tmp
|
|||
Min_ellipse_2/Makefile
|
||||
Min_ellipse_2/bin
|
||||
Min_ellipse_2/doc_ps
|
||||
Minkowski_sum_3/test/Minkowski_sum_3/cgal_test_with_cmake
|
||||
Nef_2/test/Nef_2/EPoint-test
|
||||
Nef_2/test/Nef_2/Nef_polyhedron_2-test
|
||||
Nef_2/test/Nef_2/Polynomial-test
|
||||
Nef_2/test/Nef_2/cgal_test_with_cmake
|
||||
Nef_2/test/Nef_2/nef_2_point_location
|
||||
Nef_3/demo/Nef_3/Makefile
|
||||
Nef_3/examples/Nef_3/Makefile
|
||||
|
|
@ -575,7 +544,6 @@ Number_types/test/Number_types/_test_valid_finite_double
|
|||
Number_types/test/Number_types/_test_valid_finite_float
|
||||
Number_types/test/Number_types/bench_interval
|
||||
Number_types/test/Number_types/cgal_test
|
||||
Number_types/test/Number_types/cgal_test_with_cmake
|
||||
Number_types/test/Number_types/constant
|
||||
Number_types/test/Number_types/double
|
||||
Number_types/test/Number_types/doubletst
|
||||
|
|
@ -626,7 +594,6 @@ Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/moc_*.cpp
|
|||
Periodic_3_triangulation_3/demo/Periodic_3_triangulation_3/ui_*.h
|
||||
Periodic_3_triangulation_3/demo/Periodic_Lloyd_3/Periodic_Lloyd_3.qch
|
||||
Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/Test_tds_IO_3
|
||||
Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/cgal_test_with_cmake
|
||||
Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/test_periodic_3_alpha_shape_3
|
||||
Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/test_periodic_3_delaunay_3
|
||||
Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/test_periodic_3_delaunay_hierarchy_3
|
||||
|
|
@ -637,7 +604,6 @@ Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/test_periodic_3_trian
|
|||
Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/test_periodic_3_triangulation_traits_H_3
|
||||
Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/test_periodic_3_triangulation_traits_SC_3
|
||||
Periodic_3_triangulation_3/test/Periodic_3_triangulation_3/test_periodic_3_triangulation_traits_SH_3
|
||||
Point_set_2/test/Point_set_2/cgal_test_with_cmake
|
||||
Point_set_2/test/Point_set_2/nearest_nb1
|
||||
Point_set_2/test/Point_set_2/nearest_nb_fcn
|
||||
Point_set_2/test/Point_set_2/range_search_fcn
|
||||
|
|
@ -683,7 +649,6 @@ Point_set_processing_3/test/Point_set_processing_3/smoothing_test
|
|||
/Polygon_mesh_processing/test/Polygon_mesh_processing/elephant-oriented.off
|
||||
/Polygon_mesh_processing/test/Polygon_mesh_processing/elephant-shuffled.off
|
||||
/Polygon_mesh_processing/test/Polygon_mesh_processing/blobby_2cc_no_id.off
|
||||
/Polygon_mesh_processing/test/Polygon_mesh_processing/cgal_test_with_cmake
|
||||
/Polygon_mesh_processing/test/Polygon_mesh_processing/data/U.polylines.txt.off
|
||||
/Polygon_mesh_processing/test/Polygon_mesh_processing/data/hole1.txt.off
|
||||
/Polygon_mesh_processing/test/Polygon_mesh_processing/data/hole2.txt.off
|
||||
|
|
@ -707,7 +672,6 @@ Polyhedron/demo/Polyhedron/snapshot.*
|
|||
Polyhedron/demo/Polyhedron/ui_*.h
|
||||
Polyhedron/test/Polyhedron/*.kdev*
|
||||
Polyhedron/test/Polyhedron/Makefile
|
||||
Polyhedron/test/Polyhedron/cgal_test_with_cmake
|
||||
Polyhedron/test/Polyhedron/test_polyhedron
|
||||
Polynomial/test/Polynomial/Exponent_vector
|
||||
Polynomial/test/Polynomial/Interpolator
|
||||
|
|
@ -715,7 +679,6 @@ Polynomial/test/Polynomial/Polynomial_traits_d
|
|||
Polynomial/test/Polynomial/Polynomial_type_generator
|
||||
Polynomial/test/Polynomial/Polynomial_using_core
|
||||
Polynomial/test/Polynomial/Polynomial_using_leda
|
||||
Polynomial/test/Polynomial/cgal_test_with_cmake
|
||||
Polynomial/test/Polynomial/modular_gcd_utcf_algorithm_M
|
||||
Polynomial/test/Polynomial/modular_gcd_utcf_dfai
|
||||
Polynomial/test/Polynomial/modular_gcd_utcf_pure_wang
|
||||
|
|
@ -745,10 +708,8 @@ Polytope_distance_d/.obj
|
|||
Polytope_distance_d/.tmp
|
||||
Polytope_distance_d/Makefile
|
||||
Polytope_distance_d/bin
|
||||
Polytope_distance_d/test/Polytope_distance_d/cgal_test_with_cmake
|
||||
Polytope_distance_d/test/Polytope_distance_d/test_Polytope_distance_d_d
|
||||
Principal_component_analysis/test/Principal_component_analysis/bounding_box
|
||||
Principal_component_analysis/test/Principal_component_analysis/cgal_test_with_cmake
|
||||
Principal_component_analysis/test/Principal_component_analysis/linear_least_squares_fitting_circles_2
|
||||
Principal_component_analysis/test/Principal_component_analysis/linear_least_squares_fitting_cuboids_3
|
||||
Principal_component_analysis/test/Principal_component_analysis/linear_least_squares_fitting_points_2
|
||||
|
|
@ -773,7 +734,6 @@ Principal_component_analysis/test/Principal_component_analysis/test_linear_least
|
|||
Principal_component_analysis/test/Principal_component_analysis/test_linear_least_squares_fitting_tetrahedra_3
|
||||
Principal_component_analysis/test/Principal_component_analysis/test_linear_least_squares_fitting_triangles_2
|
||||
Principal_component_analysis/test/Principal_component_analysis/test_linear_least_squares_fitting_triangles_3
|
||||
/Profiling_tools/test/Profiling_tools/cgal_test_with_cmake
|
||||
/Profiling_tools/test/Profiling_tools/test_memory_sizer
|
||||
/Profiling_tools/test/Profiling_tools/test_timer
|
||||
QP_solver/documentation/Degeneracies.aux
|
||||
|
|
@ -805,7 +765,6 @@ Ridges_3/examples/Ridges_3/Compute_Ridges_Umbilics
|
|||
Ridges_3/examples/Ridges_3/Makefile
|
||||
Ridges_3/test/Ridges_3/Makefile
|
||||
Ridges_3/test/Ridges_3/ridge_test
|
||||
STL_Extension/test/STL_Extension/cgal_test_with_cmake
|
||||
STL_Extension/test/STL_Extension/test_Cache
|
||||
STL_Extension/test/STL_Extension/test_Compact_container
|
||||
STL_Extension/test/STL_Extension/test_Concatenate_iterator
|
||||
|
|
@ -827,7 +786,6 @@ STL_Extension/test/STL_Extension/test_nth_element
|
|||
STL_Extension/test/STL_Extension/test_stl_extension
|
||||
STL_Extension/test/STL_Extension/test_type_traits
|
||||
STL_Extension/test/STL_Extension/test_vector
|
||||
SearchStructures/test/RangeSegmentTrees/cgal_test_with_cmake
|
||||
SearchStructures/test/RangeSegmentTrees/test_segment_tree_set_2
|
||||
Skin_surface_3/.cdtproject
|
||||
Skin_surface_3/.project
|
||||
|
|
@ -838,7 +796,6 @@ Skin_surface_3/test/Skin_surface_3/err.txt
|
|||
Skin_surface_3/test/Skin_surface_3/makefile
|
||||
Skin_surface_3/test/Skin_surface_3/msgs.txt
|
||||
Skin_surface_3/test/Skin_surface_3/subdivision_test
|
||||
Spatial_sorting/test/Spatial_sorting/cgal_test_with_cmake
|
||||
Stream_lines_2/demo/Stream_lines_2/Makefile
|
||||
Stream_lines_2/demo/Stream_lines_2/streamlines
|
||||
Surface_mesh_parameterization/examples/Surface_mesh_parameterization/*.eps
|
||||
|
|
@ -966,20 +923,15 @@ Triangulation/test/Triangulation/output-pcds*
|
|||
Triangulation/test/Triangulation/pc
|
||||
Triangulation/test/Triangulation/pcds
|
||||
Triangulation/test/Triangulation/torture
|
||||
/Triangulation/examples/Triangulation/cgal_test_with_cmake
|
||||
/Triangulation/test/Triangulation/cgal_test_with_cmake
|
||||
/Triangulation/test/Triangulation/output-tds-*
|
||||
Triangulation_2/cgal_test_with_cmake
|
||||
Triangulation_2/demo/Triangulation_2/Makefile
|
||||
Triangulation_2/demo/Triangulation_2/constrained
|
||||
Triangulation_2/demo/Triangulation_2/constrained_delaunay_triangulation_2
|
||||
Triangulation_2/demo/Triangulation_2/delaunay_triangulation_2
|
||||
Triangulation_2/demo/Triangulation_2/regular_triangulation_2
|
||||
Triangulation_2/examples/Triangulation_2/cgal_test_with_cmake
|
||||
Triangulation_2/examples/Triangulation_2/regular
|
||||
Triangulation_2/test/Triangulation_2/Makefile
|
||||
Triangulation_2/test/Triangulation_2/T??.triangulation
|
||||
Triangulation_2/test/Triangulation_2/cgal_test_with_cmake
|
||||
Triangulation_2/test/Triangulation_2/file_tds*
|
||||
Triangulation_2/test/Triangulation_2/makefile
|
||||
Triangulation_2/test/Triangulation_2/test_cdt_degenerate_case
|
||||
|
|
@ -997,10 +949,8 @@ Triangulation_2/test/Triangulation_2/test_triangulation_2_bis
|
|||
Triangulation_2/test/Triangulation_2/test_triangulation_geom_traits
|
||||
Triangulation_2/test/Triangulation_2/test_triangulation_tds
|
||||
Triangulation_2/test/Triangulation_2/vrml_tds*
|
||||
Triangulation_3/benchmark/Triangulation_3/cgal_test_with_cmake
|
||||
Triangulation_3/benchmark/Triangulation_3/simple
|
||||
Triangulation_3/examples/Triangulation_3/adding_handles_3
|
||||
Triangulation_3/examples/Triangulation_3/cgal_test_with_cmake
|
||||
Triangulation_3/examples/Triangulation_3/color
|
||||
Triangulation_3/examples/Triangulation_3/fast_location_3
|
||||
Triangulation_3/examples/Triangulation_3/find_conflicts_3
|
||||
|
|
@ -1026,7 +976,6 @@ Triangulation_3/test/Triangulation_3/Test8_triangulation_IO_3_binary
|
|||
Triangulation_3/test/Triangulation_3/Test??_triangulation_IO_3
|
||||
Triangulation_3/test/Triangulation_3/Test?_triangulation_IO_3
|
||||
Triangulation_3/test/Triangulation_3/Test_tds_IO_3
|
||||
Triangulation_3/test/Triangulation_3/cgal_test_with_cmake
|
||||
Triangulation_3/test/Triangulation_3/makefile
|
||||
Triangulation_3/test/Triangulation_3/test_delaunay_3
|
||||
Triangulation_3/test/Triangulation_3/test_delaunay_hierarchy_3
|
||||
|
|
@ -1083,7 +1032,6 @@ ProgramOutput*
|
|||
ErrorOutput*
|
||||
CompilerOutput*
|
||||
error.txt
|
||||
cgal_test_with_cmake.log
|
||||
|
||||
# File created by the Semantic Bovinator (an Emacs package)
|
||||
semantic.cache
|
||||
|
|
@ -1140,9 +1088,7 @@ Doxyfile
|
|||
gmon.*
|
||||
|
||||
# Unsorted file names:
|
||||
/Point_set_processing_3/test/Point_set_processing_3/cgal_test_with_cmake
|
||||
/Point_set_processing_3/test/Point_set_processing_3/read_test
|
||||
/Nef_S2/test/Nef_S2/cgal_test_with_cmake
|
||||
/Arrangement_on_surface_2/test/Arrangement_on_surface_2/construction_test_suite_generator
|
||||
/Arrangement_on_surface_2/test/Arrangement_on_surface_2/ex_kernel_point
|
||||
/Arrangement_on_surface_2/test/Arrangement_on_surface_2/ex_kernel_segment
|
||||
|
|
@ -1190,15 +1136,11 @@ gmon.*
|
|||
/Principal_component_analysis/examples/Principal_component_analysis/barycenter
|
||||
/Principal_component_analysis/examples/Principal_component_analysis/bounding_box
|
||||
/Principal_component_analysis/examples/Principal_component_analysis/centroid
|
||||
/Principal_component_analysis/examples/Principal_component_analysis/cgal_test_with_cmake
|
||||
/Principal_component_analysis/examples/Principal_component_analysis/linear_least_squares_fitting_points_2
|
||||
/Principal_component_analysis/examples/Principal_component_analysis/linear_least_squares_fitting_triangles_3
|
||||
/Polygon/examples/Polygon/cgal_test_with_cmake
|
||||
/Polygon/test/Polygon/cgal_test_with_cmake
|
||||
/Polygon/test/Polygon/polytest.ascii
|
||||
/Polygon/test/Polygon/polytest.binary
|
||||
/Polygon/test/Polygon/polytest.pretty
|
||||
/Stream_support/test/Stream_support/cgal_test_with_cmake
|
||||
/*.html
|
||||
/Snap_rounding_2/test/Snap_rounding_2/data/out
|
||||
Polygonal_surface_reconstruction/examples/build*
|
||||
|
|
|
|||
|
|
@ -0,0 +1,7 @@
|
|||
{
|
||||
"default": true,
|
||||
"line-length": false,
|
||||
"no-duplicate-heading": {
|
||||
"siblings_only": true
|
||||
}
|
||||
}
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(AABB_traits_benchmark)
|
||||
|
||||
find_package(CGAL REQUIRED OPTIONAL_COMPONENTS Core)
|
||||
|
|
@ -13,7 +13,7 @@ create_single_source_cgal_program("tree_construction.cpp")
|
|||
find_package(benchmark QUIET)
|
||||
if(benchmark_FOUND)
|
||||
create_single_source_cgal_program("tree_creation.cpp")
|
||||
target_link_libraries(tree_creation benchmark::benchmark)
|
||||
target_link_libraries(tree_creation PRIVATE benchmark::benchmark)
|
||||
else()
|
||||
message(STATUS "NOTICE: The benchmark 'tree_creation.cpp' requires the Google benchmark library, and will not be compiled.")
|
||||
endif()
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
# This is the CMake script for compiling the AABB tree demo.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(AABB_tree_Demo)
|
||||
|
||||
# Find includes in corresponding build directories
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(AABB_tree_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(AABB_tree_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Advancing_front_surface_reconstruction_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Advancing_front_surface_reconstruction_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Algebraic_foundations_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Algebraic_foundations_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED COMPONENTS Core)
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Algebraic_kernel_d_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED COMPONENTS Core)
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Algebraic_kernel_d_Tests)
|
||||
|
||||
# CGAL and its components
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Algebraic_kernel_for_circles_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Algebraic_kernel_for_spheres_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Alpha_shapes_2_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Alpha_shapes_2_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Alpha_shapes_3_Demo)
|
||||
|
||||
# Find includes in corresponding build directories
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Alpha_shapes_3_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Alpha_shapes_3_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Alpha_wrap_3_Benchmark)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -75,7 +75,7 @@ double mean_min_angle(const Mesh& mesh)
|
|||
const Triangle_3 tr = surface_mesh_face_to_triangle(f, mesh);
|
||||
std::array<FT, 3> angles = triangle_angles(tr);
|
||||
|
||||
FT min_angle = std::min({angles[0], angles[1], angles[2]});
|
||||
FT min_angle = (std::min)({angles[0], angles[1], angles[2]});
|
||||
|
||||
min_angle = min_angle * (180.0 / CGAL_PI);
|
||||
mean_min_angle += min_angle;
|
||||
|
|
@ -93,7 +93,7 @@ double mean_max_angle(const Mesh& mesh)
|
|||
const Triangle_3 tr = surface_mesh_face_to_triangle(f, mesh);
|
||||
std::array<FT, 3> angles = triangle_angles(tr);
|
||||
|
||||
FT max_angle = std::max({angles[0], angles[1], angles[2]});
|
||||
FT max_angle = (std::max)({angles[0], angles[1], angles[2]});
|
||||
|
||||
max_angle = max_angle * (180.0 / CGAL_PI);
|
||||
mean_max_angle += max_angle;
|
||||
|
|
@ -151,8 +151,8 @@ double mean_edge_ratio(const Mesh& mesh,
|
|||
FT a = std::sqrt(CGAL::squared_distance(tr[0], tr[1]));
|
||||
FT b = std::sqrt(CGAL::squared_distance(tr[1], tr[2]));
|
||||
FT c = std::sqrt(CGAL::squared_distance(tr[2], tr[0]));
|
||||
FT min_edge = std::min({a, b, c});
|
||||
FT max_edge = std::max({a, b, c});
|
||||
FT min_edge = (std::min)({a, b, c});
|
||||
FT max_edge = (std::max)({a, b, c});
|
||||
FT edge_ratio = max_edge / min_edge;
|
||||
|
||||
mean_edge_ratio += edge_ratio;
|
||||
|
|
@ -181,7 +181,7 @@ double mean_aspect_ratio(const Mesh& mesh,
|
|||
FT c = std::sqrt(CGAL::squared_distance(tr[2], tr[0]));
|
||||
FT s = 0.5 * (a + b + c);
|
||||
FT inscribed_radius = std::sqrt((s * (s - a) * (s - b) * (s - c)) / s);
|
||||
FT max_edge = std::max({a, b, c});
|
||||
FT max_edge = (std::max)({a, b, c});
|
||||
FT aspect_ratio = max_edge / inscribed_radius;
|
||||
aspect_ratio /= (2. * std::sqrt(3.)); // normalized
|
||||
mean_aspect_ratio += aspect_ratio;
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Alpha_wrap_3_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Alpha_wrap_3_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Apollonius_graph_2_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED COMPONENTS Core)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Apollonius_graph_2_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED)
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Arithmetic_kernel_Tests)
|
||||
|
||||
find_package(CGAL REQUIRED COMPONENTS Core)
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ void validate(std::any & v, const std::vector<std::string> & values,
|
|||
Option_parser::my_validate<Option_parser::Strategy_id>(v, values);
|
||||
}
|
||||
|
||||
/*! Constructor */
|
||||
/*! constructs */
|
||||
Option_parser::Option_parser() :
|
||||
m_generic_opts("Generic options"),
|
||||
m_config_opts("Configuration options"),
|
||||
|
|
@ -136,7 +136,7 @@ Option_parser::Option_parser() :
|
|||
m_positional_opts.add("input-file", -1);
|
||||
}
|
||||
|
||||
/*! Parse the options */
|
||||
/*! parses the options */
|
||||
void Option_parser::operator()(int argc, char * argv[])
|
||||
{
|
||||
po::store(po::command_line_parser(argc, argv).
|
||||
|
|
@ -225,20 +225,20 @@ void Option_parser::operator()(int argc, char * argv[])
|
|||
}
|
||||
}
|
||||
|
||||
/*! Obtain the base file-name */
|
||||
/*! obtains the base file-name */
|
||||
const std::string & Option_parser::get_file_name(unsigned int i) const
|
||||
{
|
||||
return m_variable_map["input-file"].as<Input_path>()[i];
|
||||
}
|
||||
|
||||
/*! Obtain the full file-name */
|
||||
/*! obtains the full file-name */
|
||||
const std::string & Option_parser::get_full_name(unsigned int i) const
|
||||
{ return m_full_names[i]; }
|
||||
|
||||
/*! Obtain number of type options */
|
||||
/*! obtains number of type options */
|
||||
unsigned int Option_parser::get_number_opts(Type_id &)
|
||||
{ return sizeof(s_type_opts) / sizeof(char *); }
|
||||
|
||||
/*! Obtain number of strategy options */
|
||||
/*! obtains number of strategy options */
|
||||
unsigned int Option_parser::get_number_opts(Strategy_id &)
|
||||
{ return sizeof(s_strategy_opts) / sizeof(char *); }
|
||||
|
|
|
|||
|
|
@ -62,17 +62,17 @@ public:
|
|||
typedef Vector_strategy_id::iterator Vector_strategy_id_iter;
|
||||
|
||||
public:
|
||||
/*! \brief obtains number of type options */
|
||||
/*! obtains number of type options */
|
||||
static unsigned int get_number_opts(Type_id &);
|
||||
|
||||
/*! \brief obtains number of strategy options */
|
||||
/*! obtains number of strategy options */
|
||||
static unsigned int get_number_opts(Strategy_id &);
|
||||
|
||||
/*! Compare the i-th type option to a given option */
|
||||
/*! compares the i-th type option to a given option */
|
||||
static bool compare_opt(unsigned int i, const char * opt, Type_id &)
|
||||
{ return strcmp(s_type_opts[i], opt) == 0; }
|
||||
|
||||
/*! Compare the i-th strategy option to a given option */
|
||||
/*! compares the i-th strategy option to a given option */
|
||||
static bool compare_opt(unsigned int i, const char * opt, Strategy_id &)
|
||||
{ return strcmp(s_strategy_opts[i], opt) == 0; }
|
||||
|
||||
|
|
@ -94,19 +94,19 @@ public:
|
|||
Input_file_missing_error(std::string & str) : error(str) {}
|
||||
};
|
||||
|
||||
/*! Parse the options */
|
||||
/*! parses the options */
|
||||
void operator()(int argc, char * argv[]);
|
||||
|
||||
/*! Obtain the verbosity level */
|
||||
/*! obtains the verbosity level */
|
||||
unsigned int get_verbose_level() const { return m_verbose_level; }
|
||||
|
||||
/*! Obtain the number of input files */
|
||||
/*! obtains the number of input files */
|
||||
unsigned int get_number_files() const { return m_number_files; }
|
||||
|
||||
/*! \brief obtains the base file-name */
|
||||
/*! obtains the base file-name */
|
||||
const std::string & get_file_name(unsigned int i) const;
|
||||
|
||||
/*! \brief obtains the full file-name */
|
||||
/*! obtains the full file-name */
|
||||
const std::string & get_full_name(unsigned int i) const;
|
||||
|
||||
bool get_postscript() const { return m_postscript; }
|
||||
|
|
@ -117,10 +117,10 @@ public:
|
|||
const char * get_strategy_name(Strategy_code id) const
|
||||
{ return s_strategy_opts[id]; }
|
||||
|
||||
/*! Obtain the window width */
|
||||
/*! obtains the window width */
|
||||
unsigned int get_width() const { return m_win_width; }
|
||||
|
||||
/*! Obtain the window height */
|
||||
/*! obtains the window height */
|
||||
unsigned int get_height() const { return m_win_height; }
|
||||
|
||||
template <class MyId>
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Arrangement_on_surface_2_Demo)
|
||||
|
||||
if(NOT POLICY CMP0070 AND POLICY CMP0053)
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Arrangement_on_surface_2_earth_Demo)
|
||||
|
||||
if(NOT POLICY CMP0070 AND POLICY CMP0053)
|
||||
|
|
|
|||
|
|
@ -62,7 +62,7 @@ void GUI_country_pick_handler::mouse_press_event(QMouseEvent* e) {
|
|||
auto sd = sqrt(d);
|
||||
auto t1 = (-b - sd) / (2 * a);
|
||||
auto t2 = (-b + sd) / (2 * a);
|
||||
if (t1 > 0 && t2 > 0) ti = std::min(t1, t2);
|
||||
if (t1 > 0 && t2 > 0) ti = (std::min)(t1, t2);
|
||||
else if (t1 > 0) ti = t1;
|
||||
else ti = t2;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -140,7 +140,7 @@ void Main_widget::initializeGL() {
|
|||
for (auto& [country_name, triangle_points] : country_triangles_map) {
|
||||
auto country_triangles = std::make_unique<Triangles>(triangle_points);
|
||||
auto color = QVector4D(rndm(), rndm(), rndm(), 1);
|
||||
auto m = std::max(color.x(), std::max(color.y(), color.z()));
|
||||
auto m = (std::max)(color.x(), (std::max)(color.y(), color.z()));
|
||||
color /= m;
|
||||
color *= m_dimming_factor;
|
||||
color.setW(1);
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,355 +1,343 @@
|
|||
|
||||
namespace CGAL {
|
||||
|
||||
/*!
|
||||
\ingroup PkgArrangementOnSurface2TraitsClasses
|
||||
/*! \ingroup PkgArrangementOnSurface2TraitsClasses
|
||||
*
|
||||
* The traits class `Arr_algebraic_segment_traits_2` is a model of the
|
||||
* `ArrangementTraits_2` concept that handles planar algebraic curves of
|
||||
* arbitrary degree, and \f$ x\f$-monotone of such curves. A planar (real)
|
||||
* <I>algebraic curve</I> is the vanishing set of a polynomial in two variables,
|
||||
* that is, the curve is defined by the defining equation \f[
|
||||
* f(x):=\sum_{i+j\leq n} a_{ij} x^i y^j =0, \f] where \f$ n\f$ is the degree of
|
||||
* the curve.
|
||||
*
|
||||
* The traits class allows the construction of algebraic curves, by specifying
|
||||
* their implicit equation. \f$ x\f$-monotone and vertical segments of a curve
|
||||
* can also be defined; unbounded curves and segments are supported. The
|
||||
* template parameter `Coefficient` defines the innermost coefficient type of
|
||||
* the polynomials. Currently, the types `leda::integer` and `CORE::BigInt` are
|
||||
* supported as well as any instance of `CGAL::Sqrt_extension` that is
|
||||
* instantiated with one of the integral types above.
|
||||
*
|
||||
* \cgalModels{ArrangementTraits_2}
|
||||
*/
|
||||
|
||||
The traits class `Arr_algebraic_segment_traits_2` is a model of the `ArrangementTraits_2`
|
||||
concept that handles planar algebraic curves of arbitrary degree,
|
||||
and \f$ x\f$-monotone of such curves.
|
||||
A planar (real) <I>algebraic curve</I>
|
||||
is the vanishing set of a polynomial in two variables, that is, the
|
||||
curve is defined by the defining equation
|
||||
\f[ f(x):=\sum_{i+j\leq n} a_{ij} x^i y^j =0, \f]
|
||||
where \f$ n\f$ is the degree of the curve.
|
||||
|
||||
The traits class allows the construction of algebraic curves,
|
||||
by specifying their implicit equation. \f$ x\f$-monotone and vertical segments
|
||||
of a curve can also be defined; unbounded curves and segments are supported.
|
||||
The template parameter `Coefficient` defines
|
||||
the innermost coefficient type of the polynomials. Currently,
|
||||
the types `leda::integer` and `CORE::BigInt` are supported as well
|
||||
as any instance of `CGAL::Sqrt_extension` that is instantiated with
|
||||
one of the integral types above.
|
||||
|
||||
\cgalModels{ArrangementTraits_2}
|
||||
|
||||
|
||||
*/
|
||||
template <typename Coefficient>
|
||||
class Arr_algebraic_segment_traits_2 {
|
||||
public:
|
||||
|
||||
/// \name Types
|
||||
/// @{
|
||||
|
||||
/*! Value to specify whether a point should be in the interior of a segment, or
|
||||
* its minimal point, or its maximal point in lexicographic order.
|
||||
*/
|
||||
enum Site_of_point { POINT_IN_INTERIOR = 0, MIN_ENDPOINT = -1, MAX_ENDPOINT = 1 };
|
||||
|
||||
/*! the type for bivariate polynomials, with innermost coefficient type
|
||||
* `Coefficient`. Constitutes a model of the concept `Polynomial_d` with two
|
||||
* variables.
|
||||
*
|
||||
* \sa `CGAL::Polynomial_d`
|
||||
*/
|
||||
typedef unspecified_type Polynomial_2;
|
||||
|
||||
/*! model for the concept `AlgebraicKernel_1`
|
||||
*/
|
||||
typedef unspecified_type Algebraic_kernel_1;
|
||||
|
||||
/*! represents coordinates of points.
|
||||
* Typedef from `Algebraic_kernel_1::Algebraic_real_1`
|
||||
*/
|
||||
typedef unspecified_type Algebraic_real_1;
|
||||
|
||||
/*! Typedef from `Algebraic_kernel_1::Bound`
|
||||
*/
|
||||
typedef unspecified_type Bound;
|
||||
|
||||
/// @}
|
||||
|
||||
/// \name Accessing functor objects
|
||||
/// @{
|
||||
|
||||
/*!
|
||||
|
||||
*/
|
||||
Construct_curve_2 construct_curve_2_object() const;
|
||||
|
||||
/*!
|
||||
|
||||
*/
|
||||
Construct_point_2 construct_point_2_object() const;
|
||||
|
||||
/*!
|
||||
|
||||
*/
|
||||
Construct_x_monotone_segment_2 construct_x_monotone_segment_2_object() const;
|
||||
|
||||
/// @}
|
||||
|
||||
/*!
|
||||
|
||||
*/
|
||||
class Construct_curve_2 {
|
||||
public:
|
||||
|
||||
/// \name Object Creation Functors
|
||||
/// @{
|
||||
|
||||
/*! Returns a `Curve_2` object that represents the curve defined by the
|
||||
* polynomial `p`
|
||||
*/
|
||||
Curve_2 operator() (Polynomial_2 p);
|
||||
|
||||
/*! Returns a `Curve_2` object specified by `s`. The passed string represents
|
||||
* the defining polynomial of the curve and must be given in a MAPLE-readable
|
||||
* format using "x" as first and "y" as second variable, e.g.,
|
||||
* \f$(x^3*y-2*x)*(-6*x-y^3*x^6)\f$ for integer coefficients, and
|
||||
* \f$3/2*x*y^4-5/7*x^2+3/1\f$ for rational coefficients.
|
||||
*/
|
||||
Curve_2 operator() (std::string s);
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Construct_curve_2 */
|
||||
|
||||
/*!
|
||||
|
||||
*/
|
||||
class Construct_point_2 {
|
||||
public:
|
||||
|
||||
/// \name Object Creation Functors
|
||||
/// @{
|
||||
|
||||
/*! Returns a `Point_2` object that represents the `arcno`-th
|
||||
* point in the fiber of `cv` at \f$ x\f$-coordinate `x`,
|
||||
* counted from the bottom, starting with zero.
|
||||
* \pre (`cv` must not have a vertical line at `x`,
|
||||
* and \f$ 0\leq arcno < c\f$, where \f$ c\f$ is the number of points
|
||||
* in the fiber of `cv` at `x`.)
|
||||
*/
|
||||
Point_2 operator() (Algebraic_real_1 x, Curve_2 cv, int arcno);
|
||||
|
||||
/*! Returns a `Point_2` object that represents the
|
||||
* point on `xcv` at \f$ x\f$-coordinate `x`
|
||||
* \pre (`x` is in the \f$ x\f$-range of `xcv`.)
|
||||
*/
|
||||
Point_2 operator() (Algebraic_real_1 x, X_monotone_curve_2 xcv);
|
||||
|
||||
/*! Returns a `Point_2` object that represents (x,y)
|
||||
*/
|
||||
Point_2 operator() (Algebraic_real_1 x, Algebraic_real_1 y);
|
||||
|
||||
/*! Returns a `Point_2` object that represents (x,y)
|
||||
*/
|
||||
Point_2 operator() (Coefficient x, Coefficient y);
|
||||
|
||||
/*! Returns a `Point_2` object that represents (x,y)
|
||||
*/
|
||||
Point_2 operator() (Bound x, Bound y);
|
||||
|
||||
/*! Returns a `Point_2` object that represents (x,y)
|
||||
*/
|
||||
Point_2 operator() (int x, int y);
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Construct_point_2 */
|
||||
|
||||
/*!
|
||||
|
||||
*/
|
||||
class Construct_x_monotone_segment_2 {
|
||||
public:
|
||||
|
||||
/// \name Object Creation Functors
|
||||
/// @{
|
||||
|
||||
/*! inserts a sequence of `X_monotone_curve_2` objects (terminal segments) into
|
||||
* an output container given through an output iterator. These terminal segments
|
||||
* compose an \f$x\f$-monotone (or vertical) segment of a given curve that
|
||||
* starts in `end_min`, and ends in `end_max`.
|
||||
*
|
||||
* \param cv The input curve.
|
||||
* \param end_min The starting point.
|
||||
* \param end_max The ending point.
|
||||
* \param oi The output iterator that points at the output container.
|
||||
* \return The past-the-end iterator of the output container.
|
||||
*
|
||||
* \pre `end_min` must have a unique \f$x\f$-monotone segment to its right, or
|
||||
* `end_max` must have a unique \f$x\f$-monotone segment to its left.
|
||||
* Furthermore, `end_min` and `end_max` must be connected by an
|
||||
* \f$x\f$-monotone segment of `cv`)
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator operator() (Curve_2 cv, Point_2 end_min, Point_2 end_max,
|
||||
OutputIterator oi);
|
||||
|
||||
/*! inserts a sequence of `X_monotone_curve_2` objects into an output container
|
||||
* given through an output iterator. These segments form an \f$x\f$-monotone
|
||||
* (or vertical) segment of the curve `cv`.
|
||||
*
|
||||
* If `site_of_p==POINT_IN_INTERIOR`, the maximal segment is
|
||||
* returned that contains `p` in its interior.
|
||||
*
|
||||
* returned that contains `p` as its left endpoint.
|
||||
*
|
||||
* returned that contains `p` as its left endpoint.
|
||||
*
|
||||
* \pre (If `site_of_p==POINT_IN_INTERIOR`, `p`
|
||||
* must be an interior point of an \f$x\f$-monotone or a vertical
|
||||
* segment.
|
||||
* must either have a unique \f$x\f$-monotone segment to the right,
|
||||
* or a vertical segment from `p` upwards.
|
||||
* must either have a unique \f$x\f$-monotone segment to the left,
|
||||
* or a vertical segment from `p` downwards.)
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator operator() (Curve_2 cv, Point_2 p, Site_of_point site_of_p,
|
||||
OutputIterator out);
|
||||
|
||||
/*! inserts a sequence of `X_monotone_curve_2` objects into an output container
|
||||
* given through an output iterator. These segments form a straight-line
|
||||
* segment connecting the points `p` and `q`. If `p` and `q` share the same
|
||||
* \f$x\f$-coordinate, the constructed vertical segment consists of only one
|
||||
* `X_monotone_curve_2` object and can be computed efficiently. In the
|
||||
* non-vertical case, the construction is only possible if `p` and `q` have both
|
||||
* rational x- and y-coordinates.
|
||||
*
|
||||
* \pre (`p` must not be equal to `q`.)
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator operator() (Point_2 p, Point_2 q, OutputIterator out);
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Construct_x_monotone_segment_2 */
|
||||
|
||||
/*! Models the `ArrangementTraits_2::Curve_2` concept.
|
||||
* Represents algebraic curves. Internally, the type stores
|
||||
* topological-geometric information about the particular curve.
|
||||
* In order to use internal caching, instances should only be created
|
||||
* using the `Construct_curve_2` functor of the traits class.
|
||||
*/
|
||||
class Curve_2 {
|
||||
public:
|
||||
|
||||
/// \name Modifiers
|
||||
/// @{
|
||||
|
||||
/*! returns the defining polynomial of the curve.
|
||||
*/
|
||||
Polynomial_2 polynomial () const;
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Curve_2 */
|
||||
|
||||
/*! Models the `ArrangementBasicTraits_2::Point_2` concept.
|
||||
* Represents points in \f$ \mathbb{R}^2\f$. Intersection points of algebraic
|
||||
* curves are in general non-rational, so we need a data structure that is
|
||||
* capable of representing arbitrary points with algebraic coordinates.
|
||||
*
|
||||
* The traits class represents algebraic coordinates by the type
|
||||
* `Algebraic_real_1`, which is a model of the `AlgebraicReal_1` concept.
|
||||
* A point \f$ p\f$ is stored by a triple \f$ (x,cv,arcno)\f$,
|
||||
* where \f$ x\f$ is the \f$ x\f$-coordinate of a point, \f$ cv\f$ is an instance
|
||||
* of `Curve_2` that contains the point, (and has no vertical line at \f$ x\f$),
|
||||
* and \f$ arcno\f$ is an `int`, denoting that \f$ p\f$ is met as the
|
||||
* \f$arcno\f$-th point when shooting a vertical ray at \f$ x\f$, starting from
|
||||
* \f$-\infty\f$ (where counting starts with \f$ 0\f$).
|
||||
*
|
||||
* In addition to the methods listed below, the copy constructor and assignment
|
||||
* operator for `Point_2` objects are also supported.
|
||||
*
|
||||
* The functor `Construct_point_2` constructs `Point_2` instances.
|
||||
*/
|
||||
|
||||
class Point_2 {
|
||||
public:
|
||||
|
||||
/// \name Modifiers
|
||||
/// @{
|
||||
|
||||
/*! returns the \f$ x\f$-coordinate of `p`.
|
||||
*/
|
||||
Algebraic_real_1 x () const;
|
||||
|
||||
/*! returns the \f$ y\f$-coordinates of `p`.
|
||||
*
|
||||
* <B>Attention:</B> As described above, points are not stored
|
||||
* by their \f$ y\f$-coordinate in `Algebraic_real_1` representation. In fact,
|
||||
* this representation must be computed on demand, and might become quite
|
||||
* costly for points defined by high-degree polynomials. Therefore, it is
|
||||
* recommended to avoid to call this function as much as possible.
|
||||
*/
|
||||
Algebraic_real_1 y () const;
|
||||
|
||||
/*! returns a `Curve_2` instance that `p`is part of.
|
||||
*/
|
||||
Curve_2 curve () const;
|
||||
|
||||
/*! returns the arc number of `p`.
|
||||
*/
|
||||
int arcno () const;
|
||||
|
||||
/*! returns double-approximations of the \f$ x\f$- and \f$ y\f$-coordinates.
|
||||
*/
|
||||
std::pair<double,double> to_double () const;
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Point_2 */
|
||||
|
||||
/*! Models the `ArrangementBasicTraits_2::X_monotone_curve_2` concept.
|
||||
* Represents terminal segments of an algebraic curves, that means vertical
|
||||
* segments or \f$ x\f$-monotone segments with no critical \f$ x\f$-coordinate
|
||||
* in the interior of their \f$ x\f$-range. Terminal segments might either be
|
||||
* bounded or unbounded. By definition, each interior point of a non-vertical
|
||||
* segment has the same arc number (see the documentation of type `Point_2`
|
||||
* above, which is called the <I>arc number</I> of the segment (note the arc
|
||||
* number at the endpoints might differ). Such segments are represented
|
||||
* internally by a 4-tuple \f$ (p,q,cv,arcno)\f$, where \f$ p\f$ and \f$ q\f$
|
||||
* are the endpoints, \f$ cv\f$ is the <I>supporting curve</I> that the segment
|
||||
* belongs to, and arcno is the arc number of the segment.
|
||||
*
|
||||
* Arbitrary (weakly) \f$ x\f$-monotone segments are presented by a range
|
||||
* of `X_monotone_curve_2` instances, whose union equals the segment.
|
||||
* The functor `Construct_x_monotone_segment_2` allows their construction.
|
||||
* To construct all (maximal) terminal segments of a curve,
|
||||
* use the `Make_x_monotone_2` functor supplied by the traits class.
|
||||
*/
|
||||
class X_monotone_curve_2 {
|
||||
public:
|
||||
|
||||
/// \name Modifiers
|
||||
/// @{
|
||||
|
||||
/*! returns the supporting algebraic curve of `s`.
|
||||
*/
|
||||
Curve_2 curve () const;
|
||||
|
||||
/*! returns whether `s` is a vertical segment.
|
||||
*/
|
||||
bool is_vertical () const;
|
||||
|
||||
/*! returns whether `s` has a finite endpoint on the left
|
||||
*/
|
||||
bool is_finite (CGAL::Arr_curve_end ce) const;
|
||||
|
||||
/*! \pre (The corresponding curve end is finite)
|
||||
*/
|
||||
Point_2 curve_end (CGAL::Arr_curve_end ce) const;
|
||||
|
||||
/*! returns the arc number of the segment.
|
||||
* \pre (The segment is non-vertical)
|
||||
*/
|
||||
int arcno () const;
|
||||
|
||||
/*!
|
||||
returns the \f$ x\f$-coordinate of a vertical segment.
|
||||
\pre (The segment is vertical)
|
||||
*/
|
||||
Algebraic_real_1 x () const;
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::X_monotone_curve_2 */
|
||||
/// \name Types
|
||||
/// @{
|
||||
|
||||
/*! Value to specify whether a point should be in the interior of a segment, or
|
||||
* its minimal point, or its maximal point in lexicographic order.
|
||||
*/
|
||||
enum Site_of_point { POINT_IN_INTERIOR = 0, MIN_ENDPOINT = -1, MAX_ENDPOINT = 1 };
|
||||
|
||||
/*! the type for bivariate polynomials, with innermost coefficient type
|
||||
* `Coefficient`. Constitutes a model of the concept `Polynomial_d` with two
|
||||
* variables.
|
||||
*
|
||||
* \sa `CGAL::Polynomial_d`
|
||||
*/
|
||||
typedef unspecified_type Polynomial_2;
|
||||
|
||||
/*! model for the concept `AlgebraicKernel_1`
|
||||
*/
|
||||
typedef unspecified_type Algebraic_kernel_1;
|
||||
|
||||
/*! represents coordinates of points.
|
||||
* Typedef from `Algebraic_kernel_1::Algebraic_real_1`
|
||||
*/
|
||||
typedef unspecified_type Algebraic_real_1;
|
||||
|
||||
/*! Typedef from `Algebraic_kernel_1::Bound`
|
||||
*/
|
||||
typedef unspecified_type Bound;
|
||||
|
||||
/// @}
|
||||
|
||||
/// \name Accessing functor objects
|
||||
/// @{
|
||||
|
||||
/*!
|
||||
*/
|
||||
Construct_curve_2 construct_curve_2_object() const;
|
||||
|
||||
/*!
|
||||
*/
|
||||
Construct_point_2 construct_point_2_object() const;
|
||||
|
||||
/*!
|
||||
*/
|
||||
Construct_x_monotone_segment_2 construct_x_monotone_segment_2_object() const;
|
||||
|
||||
/// @}
|
||||
|
||||
/*!
|
||||
*/
|
||||
class Construct_curve_2 {
|
||||
public:
|
||||
|
||||
/// \name Object Creation Functors
|
||||
/// @{
|
||||
|
||||
/*! returns a `Curve_2` object that represents the curve defined by the
|
||||
* polynomial `p`
|
||||
*/
|
||||
Curve_2 operator() (Polynomial_2 p);
|
||||
|
||||
/*! returns a `Curve_2` object specified by `s`. The passed string represents
|
||||
* the defining polynomial of the curve and must be given in a MAPLE-readable
|
||||
* format using "x" as first and "y" as second variable, e.g.,
|
||||
* \f$(x^3*y-2*x)*(-6*x-y^3*x^6)\f$ for integer coefficients, and
|
||||
* \f$3/2*x*y^4-5/7*x^2+3/1\f$ for rational coefficients.
|
||||
*/
|
||||
Curve_2 operator() (std::string s);
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Construct_curve_2 */
|
||||
|
||||
/*!
|
||||
*/
|
||||
class Construct_point_2 {
|
||||
public:
|
||||
|
||||
/// \name Object Creation Functors
|
||||
/// @{
|
||||
|
||||
/*! returns a `Point_2` object that represents the `arcno`-th
|
||||
* point in the fiber of `cv` at \f$ x\f$-coordinate `x`,
|
||||
* counted from the bottom, starting with zero.
|
||||
* \pre (`cv` must not have a vertical line at `x`,
|
||||
* and \f$ 0\leq arcno < c\f$, where \f$ c\f$ is the number of points
|
||||
* in the fiber of `cv` at `x`.)
|
||||
*/
|
||||
Point_2 operator() (Algebraic_real_1 x, Curve_2 cv, int arcno);
|
||||
|
||||
/*! returns a `Point_2` object that represents the
|
||||
* point on `xcv` at \f$ x\f$-coordinate `x`
|
||||
* \pre (`x` is in the \f$ x\f$-range of `xcv`.)
|
||||
*/
|
||||
Point_2 operator() (Algebraic_real_1 x, X_monotone_curve_2 xcv);
|
||||
|
||||
/*! returns a `Point_2` object that represents (x,y)
|
||||
*/
|
||||
Point_2 operator() (Algebraic_real_1 x, Algebraic_real_1 y);
|
||||
|
||||
/*! returns a `Point_2` object that represents (x,y)
|
||||
*/
|
||||
Point_2 operator() (Coefficient x, Coefficient y);
|
||||
|
||||
/*! returns a `Point_2` object that represents (x,y)
|
||||
*/
|
||||
Point_2 operator() (Bound x, Bound y);
|
||||
|
||||
/*! returns a `Point_2` object that represents (x,y)
|
||||
*/
|
||||
Point_2 operator() (int x, int y);
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Construct_point_2 */
|
||||
|
||||
/*!
|
||||
*/
|
||||
class Construct_x_monotone_segment_2 {
|
||||
public:
|
||||
|
||||
/// \name Object Creation Functors
|
||||
/// @{
|
||||
|
||||
/*! inserts a sequence of `X_monotone_curve_2` objects (terminal segments) into
|
||||
* an output container given through an output iterator. These terminal segments
|
||||
* compose an \f$x\f$-monotone (or vertical) segment of a given curve that
|
||||
* starts in `end_min`, and ends in `end_max`.
|
||||
*
|
||||
* \param cv The input curve.
|
||||
* \param end_min The starting point.
|
||||
* \param end_max The ending point.
|
||||
* \param oi The output iterator that points at the output container.
|
||||
* \return The past-the-end iterator of the output container.
|
||||
*
|
||||
* \pre `end_min` must have a unique \f$x\f$-monotone segment to its right, or
|
||||
* `end_max` must have a unique \f$x\f$-monotone segment to its left.
|
||||
* Furthermore, `end_min` and `end_max` must be connected by an
|
||||
* \f$x\f$-monotone segment of `cv`)
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator operator() (Curve_2 cv, Point_2 end_min, Point_2 end_max,
|
||||
OutputIterator oi);
|
||||
|
||||
/*! inserts a sequence of `X_monotone_curve_2` objects into an output container
|
||||
* given through an output iterator. These segments form an \f$x\f$-monotone
|
||||
* (or vertical) segment of the curve `cv`.
|
||||
*
|
||||
* If `site_of_p==POINT_IN_INTERIOR`, the maximal segment is
|
||||
* returned that contains `p` in its interior.
|
||||
*
|
||||
* returned that contains `p` as its left endpoint.
|
||||
*
|
||||
* returned that contains `p` as its left endpoint.
|
||||
*
|
||||
* \pre (If `site_of_p==POINT_IN_INTERIOR`, `p`
|
||||
* must be an interior point of an \f$x\f$-monotone or a vertical
|
||||
* segment.
|
||||
* must either have a unique \f$x\f$-monotone segment to the right,
|
||||
* or a vertical segment from `p` upwards.
|
||||
* must either have a unique \f$x\f$-monotone segment to the left,
|
||||
* or a vertical segment from `p` downwards.)
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator operator() (Curve_2 cv, Point_2 p, Site_of_point site_of_p,
|
||||
OutputIterator out);
|
||||
|
||||
/*! inserts a sequence of `X_monotone_curve_2` objects into an output container
|
||||
* given through an output iterator. These segments form a straight-line
|
||||
* segment connecting the points `p` and `q`. If `p` and `q` share the same
|
||||
* \f$x\f$-coordinate, the constructed vertical segment consists of only one
|
||||
* `X_monotone_curve_2` object and can be computed efficiently. In the
|
||||
* non-vertical case, the construction is only possible if `p` and `q` have both
|
||||
* rational x- and y-coordinates.
|
||||
*
|
||||
* \pre (`p` must not be equal to `q`.)
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator operator() (Point_2 p, Point_2 q, OutputIterator out);
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Construct_x_monotone_segment_2 */
|
||||
|
||||
/*! A model of the the `ArrangementTraits_2::Curve_2` concept.
|
||||
* Represents algebraic curves. Internally, the type stores
|
||||
* topological-geometric information about the particular curve.
|
||||
* In order to use internal caching, instances should only be created
|
||||
* using the `Construct_curve_2` functor of the traits class.
|
||||
*/
|
||||
class Curve_2 {
|
||||
public:
|
||||
|
||||
/// \name Modifiers
|
||||
/// @{
|
||||
|
||||
/*! returns the defining polynomial of the curve.
|
||||
*/
|
||||
Polynomial_2 polynomial () const;
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Curve_2 */
|
||||
|
||||
/*! A model of the `ArrangementBasicTraits_2::Point_2` concept.
|
||||
* Represents points in \f$ \mathbb{R}^2\f$. Intersection points of algebraic
|
||||
* curves are in general non-rational, so we need a data structure that is
|
||||
* capable of representing arbitrary points with algebraic coordinates.
|
||||
*
|
||||
* The traits class represents algebraic coordinates by the type
|
||||
* `Algebraic_real_1`, which is a model of the `AlgebraicReal_1` concept.
|
||||
* A point \f$ p\f$ is stored by a triple \f$ (x,cv,arcno)\f$,
|
||||
* where \f$ x\f$ is the \f$ x\f$-coordinate of a point, \f$ cv\f$ is an instance
|
||||
* of `Curve_2` that contains the point, (and has no vertical line at \f$ x\f$),
|
||||
* and \f$ arcno\f$ is an `int`, denoting that \f$ p\f$ is met as the
|
||||
* \f$arcno\f$-th point when shooting a vertical ray at \f$ x\f$, starting from
|
||||
* \f$-\infty\f$ (where counting starts with \f$ 0\f$).
|
||||
*
|
||||
* In addition to the methods listed below, the copy constructor and assignment
|
||||
* operator for `Point_2` objects are also supported.
|
||||
*
|
||||
* The functor `Construct_point_2` constructs `Point_2` instances.
|
||||
*/
|
||||
|
||||
class Point_2 {
|
||||
public:
|
||||
|
||||
/// \name Modifiers
|
||||
/// @{
|
||||
|
||||
/*! returns the \f$ x\f$-coordinate of `p`.
|
||||
*/
|
||||
Algebraic_real_1 x () const;
|
||||
|
||||
/*! returns the \f$ y\f$-coordinates of `p`.
|
||||
*
|
||||
* <B>Attention:</B> As described above, points are not stored
|
||||
* by their \f$ y\f$-coordinate in `Algebraic_real_1` representation. In fact,
|
||||
* this representation must be computed on demand, and might become quite
|
||||
* costly for points defined by high-degree polynomials. Therefore, it is
|
||||
* recommended to avoid to call this function as much as possible.
|
||||
*/
|
||||
Algebraic_real_1 y () const;
|
||||
|
||||
/*! returns a `Curve_2` instance that `p`is part of.
|
||||
*/
|
||||
Curve_2 curve () const;
|
||||
|
||||
/*! returns the arc number of `p`.
|
||||
*/
|
||||
int arcno () const;
|
||||
|
||||
/*! returns double-approximations of the \f$ x\f$- and \f$ y\f$-coordinates.
|
||||
*/
|
||||
std::pair<double,double> to_double () const;
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::Point_2 */
|
||||
|
||||
/*! A model of the `ArrangementBasicTraits_2::X_monotone_curve_2` concept.
|
||||
* Represents terminal segments of an algebraic curves, that means vertical
|
||||
* segments or \f$ x\f$-monotone segments with no critical \f$ x\f$-coordinate
|
||||
* in the interior of their \f$ x\f$-range. Terminal segments might either be
|
||||
* bounded or unbounded. By definition, each interior point of a non-vertical
|
||||
* segment has the same arc number (see the documentation of type `Point_2`
|
||||
* above, which is called the <I>arc number</I> of the segment (note the arc
|
||||
* number at the endpoints might differ). Such segments are represented
|
||||
* internally by a 4-tuple \f$ (p,q,cv,arcno)\f$, where \f$ p\f$ and \f$ q\f$
|
||||
* are the endpoints, \f$ cv\f$ is the <I>supporting curve</I> that the segment
|
||||
* belongs to, and arcno is the arc number of the segment.
|
||||
*
|
||||
* Arbitrary (weakly) \f$ x\f$-monotone segments are presented by a range
|
||||
* of `X_monotone_curve_2` instances, whose union equals the segment.
|
||||
* The functor `Construct_x_monotone_segment_2` allows their construction.
|
||||
* To construct all (maximal) terminal segments of a curve,
|
||||
* use the `Make_x_monotone_2` functor supplied by the traits class.
|
||||
*/
|
||||
class X_monotone_curve_2 {
|
||||
public:
|
||||
|
||||
/// \name Modifiers
|
||||
/// @{
|
||||
|
||||
/*! returns the supporting algebraic curve of `s`.
|
||||
*/
|
||||
Curve_2 curve () const;
|
||||
|
||||
/*! returns whether `s` is a vertical segment.
|
||||
*/
|
||||
bool is_vertical () const;
|
||||
|
||||
/*! returns whether `s` has a finite endpoint on the left
|
||||
*/
|
||||
bool is_finite (CGAL::Arr_curve_end ce) const;
|
||||
|
||||
/*! \pre (The corresponding curve end is finite)
|
||||
*/
|
||||
Point_2 curve_end (CGAL::Arr_curve_end ce) const;
|
||||
|
||||
/*! returns the arc number of the segment.
|
||||
* \pre (The segment is non-vertical)
|
||||
*/
|
||||
int arcno () const;
|
||||
|
||||
/*! returns the \f$ x\f$-coordinate of a vertical segment.
|
||||
* \pre (The segment is vertical)
|
||||
*/
|
||||
Algebraic_real_1 x () const;
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2::X_monotone_curve_2 */
|
||||
|
||||
}; /* end Arr_algebraic_segment_traits_2 */
|
||||
|
||||
|
|
|
|||
|
|
@ -49,10 +49,10 @@ public:
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default */
|
||||
Arr_bounded_planar_topology_traits_2();
|
||||
|
||||
/*! Constructor from a geometry-traits object.
|
||||
/*! constructs from a geometry-traits object.
|
||||
* \param traits the traits.
|
||||
*/
|
||||
Arr_bounded_planar_topology_traits_2(const GeometryTraits_2* traits);
|
||||
|
|
@ -62,16 +62,16 @@ public:
|
|||
/// \name Accessors
|
||||
/// @{
|
||||
|
||||
/*! Obtain the DCEL (const version). */
|
||||
/*! obtains the DCEL (const version). */
|
||||
const Dcel& dcel() const;
|
||||
|
||||
/*! Obtain the DCEL (non-const version). */
|
||||
/*! obtains the DCEL (non-const version). */
|
||||
Dcel& dcel();
|
||||
|
||||
/*! Obtain the unbounded face (const version). */
|
||||
/*! obtains the unbounded face (const version). */
|
||||
const Face* unbounded_face() const;
|
||||
|
||||
/*! Obtain the unbounded face (non-const version). */
|
||||
/*! obtains the unbounded face (non-const version). */
|
||||
Face* unbounded_face();
|
||||
|
||||
/// @}
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ namespace CGAL {
|
|||
* \cgalModels{ArrangementTraits_2,ArrangementDirectionalXMonotoneTraits_2}
|
||||
*
|
||||
*/
|
||||
template< typename Kernel >
|
||||
template <typename Kernel>
|
||||
class Arr_circle_segment_traits_2 {
|
||||
public:
|
||||
|
||||
|
|
@ -133,7 +133,7 @@ public:
|
|||
/*! returns the target point.
|
||||
*
|
||||
* \pre `cv` is not a full circle.
|
||||
*/
|
||||
*/
|
||||
const Point_2& target() const;
|
||||
|
||||
/*! returns the orientation of the curve (`COLLINEAR` in case of line
|
||||
|
|
@ -189,7 +189,7 @@ public:
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! default constructor.
|
||||
/*! constructs default
|
||||
*/
|
||||
Point_2();
|
||||
|
||||
|
|
@ -323,15 +323,15 @@ public:
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! Trims the given x-monotone curve to an from src to tgt.
|
||||
/*! trims the given x-monotone curve to an from src to tgt.
|
||||
* \ pre `src` and `tgt` lies on the curve
|
||||
*/
|
||||
|
||||
X_monotone_curve_2(const X_monotone_curve_2& xcv,
|
||||
const Point_2& src,
|
||||
const Point_2& tgt)const
|
||||
const Point_2& tgt) const
|
||||
/// @}
|
||||
} /* end Arr_circle_segment_traits_2::Trim_2 */
|
||||
} /* end Arr_circle_segment_traits_2::Trim_2 */
|
||||
|
||||
}; /* end Arr_circle_segment_traits_2 */
|
||||
|
||||
|
|
|
|||
|
|
@ -260,11 +260,11 @@ public:
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! construct a default point.
|
||||
/*! constructs a default point.
|
||||
*/
|
||||
Point_2();
|
||||
|
||||
/*! construct a point from an algebraic point.
|
||||
/*! constructs a point from an algebraic point.
|
||||
*/
|
||||
Point_2(const typename Alg_kernel::Point_2& p);
|
||||
|
||||
|
|
@ -401,7 +401,7 @@ public:
|
|||
*/
|
||||
X_monotone_curve_2 operator()(const Curve_2& cv) const;
|
||||
|
||||
/*! Constructs an \f$x\f$-monotone curve connecting the two given endpoints.
|
||||
/*! constructs an \f$x\f$-monotone curve connecting the two given endpoints.
|
||||
* \param source The first point.
|
||||
* \param target The second point.
|
||||
* \pre `source` and `target` must not be the same.
|
||||
|
|
@ -409,7 +409,7 @@ public:
|
|||
*/
|
||||
X_monotone_curve_2 operator()(const Point_2& source, const Point_2& target) const;
|
||||
|
||||
/*! Constructs a special segment of a given line connecting to given
|
||||
/*! constructs a special segment of a given line connecting to given
|
||||
* endpoints.
|
||||
* \param a, b, c The coefficients of the supporting line (\f$ax + by + c = 0\f$).
|
||||
* \param source The source point.
|
||||
|
|
@ -427,33 +427,34 @@ public:
|
|||
*/
|
||||
class Construct_bbox_2 {
|
||||
public:
|
||||
/*! Obtain a bounding box for a conic arc.
|
||||
/*! obtains a bounding box for a conic arc.
|
||||
* \param cv The conic arc.
|
||||
* \return The bounding box.
|
||||
*/
|
||||
Bbox_2 operator()(const Curve_2& cv) const { return bbox(cv); }
|
||||
|
||||
/*! Obtain a bounding box for an \f$x\f$-monotone conic arc.
|
||||
/*! obtains a bounding box for an \f$x\f$-monotone conic arc.
|
||||
* \param xcv The \f$x\f$-monotone conic arc.
|
||||
* \return The bounding box.
|
||||
*/
|
||||
Bbox_2 operator()(const X_monotone_curve_2& xcv) const { return bbox(xcv); }
|
||||
};
|
||||
|
||||
/*! \name Auxiliary Functor definitions, used gor, e.g., the landmarks
|
||||
/*! \name Auxiliary Functor definitions, used gor, e.g., the landmarks \
|
||||
* point-location strategy and the drawing function.
|
||||
*/
|
||||
//@{
|
||||
typedef double Approximate_number_type;
|
||||
typedef CGAL::Cartesian<Approximate_number_type> Approximate_kernel;
|
||||
typedef Approximate_kernel::Point_2 Approximate_point_2;
|
||||
//@}
|
||||
|
||||
/*! \class Approximate_2
|
||||
* A functor that approximates a point and an \f$x\f$-monotone curve.
|
||||
*/
|
||||
class Approximate_2 {
|
||||
public:
|
||||
/*! Obtain an approximation of a point coordinate.
|
||||
/*! obtains an approximation of a point coordinate.
|
||||
* \param p The exact point.
|
||||
* \param i The coordinate index (either 0 or 1).
|
||||
* \pre `i` is either 0 or 1.
|
||||
|
|
@ -462,7 +463,7 @@ public:
|
|||
*/
|
||||
Approximate_number_type operator()(const Point_2& p, int i) const;
|
||||
|
||||
/*! Obtain an approximation of a point.
|
||||
/*! obtains an approximation of a point.
|
||||
* \param p The exact point.
|
||||
*/
|
||||
Approximate_point_2 operator()(const Point_2& p) const;
|
||||
|
|
@ -496,7 +497,7 @@ public:
|
|||
*/
|
||||
class Trim_2 {
|
||||
public:
|
||||
/*! Trims the given \f$x\f$-monotone arc to new endpoints.
|
||||
/*! trims the given \f$x\f$-monotone arc to new endpoints.
|
||||
* \param xcv The \f$x\f$-monotone arc
|
||||
* \param source The new source point.
|
||||
* \param target The new target point.
|
||||
|
|
@ -505,28 +506,28 @@ public:
|
|||
X_monotone_curve_2 operator()(const X_monotone_curve_2& xcv,
|
||||
const Point_2& source,
|
||||
const Point_2& target) const;
|
||||
|
||||
};
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
||||
/*! Obtain a `Construct_curve_2` functor. */
|
||||
/*! obtains a `Construct_curve_2` functor. */
|
||||
Construct_curve_2 construct_curve_2_object() const;
|
||||
|
||||
/*! Obtain a `Construct_x_monotone_curve_2` functor. */
|
||||
/*! obtains a `Construct_x_monotone_curve_2` functor. */
|
||||
Construct_x_monotone_curve_2 construct_x_monotone_curve_2_object() const;
|
||||
|
||||
/*! Obtain a `Bbox_2` functor. */
|
||||
/*! obtains a `Bbox_2` functor. */
|
||||
Construct_bbox_2 construct_bbox_2_object() const;
|
||||
|
||||
/*! Obtain a `Trim_2` functor. */
|
||||
/*! obtains a `Trim_2` functor. */
|
||||
Trim_2 trim_2_object() const;
|
||||
|
||||
/*! Obtain an `Approximate_2` functor. */
|
||||
/*! obtains an `Approximate_2` functor. */
|
||||
Approximate_2 approximate_2_object() const;
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_conic_traits_2 */
|
||||
|
||||
} /* end namespace CGAL */
|
||||
|
|
|
|||
|
|
@ -1,30 +1,28 @@
|
|||
|
||||
namespace CGAL {
|
||||
|
||||
/*!
|
||||
\ingroup PkgArrangementOnSurface2TraitsClasses
|
||||
|
||||
The class `Arr_consolidated_curve_data_traits_2` is a model of the concept `ArrangementTraits_2`,
|
||||
and serves as a decorator class that enables the extension of the curve
|
||||
type defined by the `Traits` parameter. The traits class inherits its
|
||||
point type from `Traits::Point_2`, and defines the types
|
||||
`Curve_2` and `X_monotone_curve_2` extended with extraneous data
|
||||
fields of type `Data`.
|
||||
|
||||
Each `Curve_2` object is associated with a single data field of type
|
||||
`Data`, and each `X_monotone_curve_2` object is associated with
|
||||
a set of unique data objects. When a curve is subdivided into \f$ x\f$-monotone
|
||||
subcurves, all resulting subcurves are associated with a list containing
|
||||
a single data object, copied from the inducing curve. When an \f$ x\f$-monotone
|
||||
curve is split, its data set is duplicated, and inserted into the sets of
|
||||
both resulting subcurves. In case two (or more) \f$ x\f$-monotone curves
|
||||
overlap, their data sets are consolidated, and are inserted into the set
|
||||
of the \f$ x\f$-monotone curve that represents the overlap.
|
||||
|
||||
\cgalModels{ArrangementTraits_2}
|
||||
|
||||
*/
|
||||
template< typename Traits, typename Data >
|
||||
/*! \ingroup PkgArrangementOnSurface2TraitsClasses
|
||||
*
|
||||
* The class `Arr_consolidated_curve_data_traits_2` is a model of the concept
|
||||
* `ArrangementTraits_2`, and serves as a decorator class that enables the
|
||||
* extension of the curve type defined by the `Traits` parameter. The traits
|
||||
* class inherits its point type from `Traits::Point_2`, and defines the types
|
||||
* `Curve_2` and `X_monotone_curve_2` extended with extraneous data fields of
|
||||
* type `Data`.
|
||||
*
|
||||
* Each `Curve_2` object is associated with a single data field of type `Data`,
|
||||
* and each `X_monotone_curve_2` object is associated with a set of unique data
|
||||
* objects. When a curve is subdivided into \f$ x\f$-monotone subcurves, all
|
||||
* resulting subcurves are associated with a list containing a single data
|
||||
* object, copied from the inducing curve. When an \f$ x\f$-monotone curve is
|
||||
* split, its data set is duplicated, and inserted into the sets of both
|
||||
* resulting subcurves. In case two (or more) \f$ x\f$-monotone curves overlap,
|
||||
* their data sets are consolidated, and are inserted into the set of the \f$
|
||||
* x\f$-monotone curve that represents the overlap.
|
||||
*
|
||||
* \cgalModels{ArrangementTraits_2}
|
||||
*/
|
||||
template <typename Traits, typename Data>
|
||||
class Arr_consolidated_curve_data_traits_2
|
||||
: public Arr_curve_data_traits_2<Traits, _Unique_list<Data>,
|
||||
_Consolidate_unique_lists<Data>,
|
||||
|
|
@ -32,139 +30,106 @@ class Arr_consolidated_curve_data_traits_2
|
|||
{
|
||||
public:
|
||||
|
||||
/// \name Types
|
||||
/// @{
|
||||
/// \name Types
|
||||
/// @{
|
||||
|
||||
/*!
|
||||
the base traits-class.
|
||||
*/
|
||||
typedef Traits Base_traits_2;
|
||||
//! the base traits-class.
|
||||
typedef Traits Base_traits_2;
|
||||
|
||||
/*!
|
||||
the base curve.
|
||||
*/
|
||||
typedef typename Base_traits_2::Curve_2 Base_curve_2;
|
||||
//! the base curve.
|
||||
typedef typename Base_traits_2::Curve_2 Base_curve_2;
|
||||
|
||||
/*!
|
||||
the base \f$ x\f$-monotone curve curve.
|
||||
*/
|
||||
typedef typename Base_traits_2::X_monotone_curve_2 Base_x_monotone_curve_2;
|
||||
//! the base \f$ x\f$-monotone curve curve.
|
||||
typedef typename Base_traits_2::X_monotone_curve_2 Base_x_monotone_curve_2;
|
||||
|
||||
/*!
|
||||
a set of data objects that is associated with an \f$ x\f$-monotone curve.
|
||||
*/
|
||||
typedef unspecified_type typedef Data_container;
|
||||
//! a set of data objects that is associated with an \f$ x\f$-monotone curve.
|
||||
typedef unspecified_type typedef Data_container;
|
||||
|
||||
/*!
|
||||
a non-mutable iterator for the data objects in the data container.
|
||||
*/
|
||||
typedef unspecified_type typedef Data_iterator;
|
||||
//! a non-mutable iterator for the data objects in the data container.
|
||||
typedef unspecified_type typedef Data_iterator;
|
||||
|
||||
/// @}
|
||||
/// @}
|
||||
|
||||
/*! The `Data_container` class nested within the consolidated
|
||||
* curve-data traits and associated with the `Traits::X_monotone_curve_2` type
|
||||
* is maintained as a list with unique data objects. This representation is
|
||||
* simple and efficient in terms of memory consumption. It also requires that
|
||||
* the `Data` class supports only the equality operator. Note however that
|
||||
* most set operations require linear time.
|
||||
*/
|
||||
class Data_container {
|
||||
public:
|
||||
|
||||
/*!
|
||||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! constructs default */
|
||||
Data_container();
|
||||
|
||||
The `Data_container` class nested within the consolidated
|
||||
curve-data traits and associated with the `Traits::X_monotone_curve_2`
|
||||
type is maintained as a list with unique data objects. This representation is
|
||||
simple and efficient in terms of memory consumption. It also requires that
|
||||
the `Data` class supports only the equality operator. Note however that
|
||||
most set operations require linear time.
|
||||
/*! constructs set containing a single `data` object. */
|
||||
Data_container(const Data& data);
|
||||
|
||||
*/
|
||||
class Data_container {
|
||||
public:
|
||||
/// @}
|
||||
|
||||
/// \name Creation
|
||||
/// @{
|
||||
/// \name Access Functions
|
||||
/// @{
|
||||
|
||||
/*!
|
||||
default constructor.
|
||||
*/
|
||||
Data_container ();
|
||||
/*! returns the number of data objects in the set. */
|
||||
std::size_t size() const;
|
||||
|
||||
/*!
|
||||
constructs set containing a single `data` object.
|
||||
*/
|
||||
Data_container (const Data& data);
|
||||
/*! returns an iterator pointing to the first data object. */
|
||||
Data_iterator begin() const;
|
||||
|
||||
/// @}
|
||||
/*! returns a past-the-end iterator for the data objects. */
|
||||
Data_iterator end() const;
|
||||
|
||||
/// \name Access Functions
|
||||
/// @{
|
||||
/*! returns the first data object inserted into the set.
|
||||
* \pre The number of data objects is not \f$ 0\f$.
|
||||
*/
|
||||
const Data& front() const;
|
||||
|
||||
/*!
|
||||
returns the number of data objects in the set.
|
||||
*/
|
||||
std::size_t size () const;
|
||||
/*! returns the last data object inserted into the set.
|
||||
* \pre The number of data objects is not \f$ 0\f$.
|
||||
*/
|
||||
const Data& back() const;
|
||||
|
||||
/*!
|
||||
returns an iterator pointing to the first data object.
|
||||
*/
|
||||
Data_iterator begin () const;
|
||||
/// @}
|
||||
|
||||
/*!
|
||||
returns a past-the-end iterator for the data objects.
|
||||
*/
|
||||
Data_iterator end () const;
|
||||
/// \name Predicates
|
||||
/// @{
|
||||
|
||||
/*!
|
||||
returns the first data object inserted into the set.
|
||||
\pre The number of data objects is not \f$ 0\f$.
|
||||
*/
|
||||
const Data& front () const;
|
||||
/*! checks whether the two sets contain the same data objects (regardless of
|
||||
* order).
|
||||
*/
|
||||
bool operator==(const Data_container& other) const;
|
||||
|
||||
/*!
|
||||
returns the last data object inserted into the set.
|
||||
\pre The number of data objects is not \f$ 0\f$.
|
||||
*/
|
||||
const Data& back () const;
|
||||
/*! finds the given `data` object in the set and returns an iterator
|
||||
* for this object, or `end()` if it is not found.
|
||||
*/
|
||||
Data_iterator find(const Data& data);
|
||||
|
||||
/// @}
|
||||
/// @}
|
||||
|
||||
/// \name Predicates
|
||||
/// @{
|
||||
/// \name Modifiers
|
||||
/// @{
|
||||
|
||||
/*!
|
||||
check if the two sets contain the same data objects (regardless of order).
|
||||
*/
|
||||
bool operator== (const Data_container& other) const;
|
||||
/*! inserts the given `data` object into the set. Returns `true` on
|
||||
* success, or `false` if the set already contains the object.
|
||||
*/
|
||||
bool insert(const Data& data);
|
||||
|
||||
/*!
|
||||
find the given `data` object in the set and returns an iterator
|
||||
for this object, or `end()` if it is not found.
|
||||
*/
|
||||
Data_iterator find (const Data& data);
|
||||
/*! erases the given `data` object from the set. Returns `true` on
|
||||
* success, or `false` if the set does not contain the object.
|
||||
*/
|
||||
bool erase(const Data& data);
|
||||
|
||||
/// @}
|
||||
|
||||
/// \name Modifiers
|
||||
/// @{
|
||||
|
||||
/*!
|
||||
inserts the given `data` object into the set. Returns `true` on
|
||||
success, or `false` if the set already contains the object.
|
||||
*/
|
||||
bool insert (const Data& data);
|
||||
|
||||
/*!
|
||||
erases the given `data` object from the set. Returns `true` on
|
||||
success, or `false` if the set does not contain the object.
|
||||
*/
|
||||
bool erase (const Data& data);
|
||||
|
||||
/*!
|
||||
clears the set.
|
||||
*/
|
||||
void clear ();
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_consolidated_curve_data_traits_2::Data_container */
|
||||
/*! clears the set. */
|
||||
void clear();
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_consolidated_curve_data_traits_2::Data_container */
|
||||
|
||||
}; /* end Arr_consolidated_curve_data_traits_2 */
|
||||
|
||||
} /* end namespace CGAL */
|
||||
|
|
|
|||
|
|
@ -0,0 +1,145 @@
|
|||
// Copyright (c) 2005,2007,2009,2010,2011 Tel-Aviv University (Israel).
|
||||
// All rights reserved.
|
||||
//
|
||||
// This file is part of CGAL (www.cgal.org).
|
||||
//
|
||||
// $URL$
|
||||
// $Id$
|
||||
// SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-Commercial
|
||||
//
|
||||
// Author(s): Efi Fogel <efif@post.tau.ac.il>
|
||||
// Eric Berberich <ericb@post.tau.ac.il>
|
||||
|
||||
namespace CGAL {
|
||||
|
||||
/*! \ingroup PkgArrangementOnSurface2TraitsClasses
|
||||
*
|
||||
* A metadata traits-class decorator for the arrangement package. It counts the
|
||||
* number of invocations of traits-class functors. It is parameterized with
|
||||
* another traits class and inherits from it. For each traits method it
|
||||
* maintains a counter that counts the number of invocations into the method.
|
||||
*
|
||||
* It models all the concepts that the original traits models.
|
||||
*/
|
||||
|
||||
template <typename BaseTraits>
|
||||
class Arr_counting_traits_2 : public BaseTraits {
|
||||
public:
|
||||
enum Operation_id {
|
||||
COMPARE_X_2_OP = 0,
|
||||
COMPARE_XY_2_OP,
|
||||
CONSTRUCT_MIN_VERTEX_2_OP,
|
||||
CONSTRUCT_MAX_VERTEX_2_OP,
|
||||
IS_VERTICAL_2_OP,
|
||||
COMPARE_Y_AT_X_2_OP,
|
||||
EQUAL_2_POINTS_OP,
|
||||
EQUAL_2_CURVES_OP,
|
||||
COMPARE_Y_AT_X_LEFT_2_OP,
|
||||
COMPARE_Y_AT_X_RIGHT_2_OP,
|
||||
MAKE_X_MONOTONE_2_OP,
|
||||
SPLIT_2_OP,
|
||||
INTERSECT_2_OP,
|
||||
ARE_MERGEABLE_2_OP,
|
||||
MERGE_2_OP,
|
||||
CONSTRUCT_2_OPPOSITE_2_OP,
|
||||
COMPARE_ENDPOINTS_XY_2_OP,
|
||||
APPROXIMATE_2_COORD_OP,
|
||||
APPROXIMATE_2_POINT_OP,
|
||||
APPROXIMATE_2_CURVE_OP,
|
||||
PARAMETER_SPACE_IN_X_2_CURVE_END_OP,
|
||||
PARAMETER_SPACE_IN_X_2_POINT_OP,
|
||||
IS_ON_X_IDENTIFICATION_POINT_2_OP,
|
||||
IS_ON_X_IDENTIFICATION_CURVE_2_OP,
|
||||
COMPARE_Y_ON_BOUNDARY_2_OP,
|
||||
COMPARE_Y_NEAR_BOUNDARY_2_OP,
|
||||
PARAMETER_SPACE_IN_Y_2_CURVE_END_OP,
|
||||
PARAMETER_SPACE_IN_Y_2_POINT_OP,
|
||||
IS_ON_Y_IDENTIFICATION_2_POINT_OP,
|
||||
IS_ON_Y_IDENTIFICATION_2_CURVE_OP,
|
||||
COMPARE_X_ON_BOUNDARY_2_POINTS_OP,
|
||||
COMPARE_X_ON_BOUNDARY_2_POINT_CURVE_END_OP,
|
||||
COMPARE_X_ON_BOUNDARY_2_CURVE_ENDS_OP,
|
||||
COMPARE_X_NEAR_BOUNDARY_2_OP,
|
||||
NUMBER_OF_OPERATIONS
|
||||
};
|
||||
|
||||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! constructs default */
|
||||
template <typename ... Args>
|
||||
Arr_counting_traits_2(Args ... args) : Base(std::forward<Args>(args)...) {}
|
||||
|
||||
/*! disables copy constructor. */
|
||||
Arr_counting_traits_2(const Arr_counting_traits_2&) = delete;
|
||||
|
||||
/// @}
|
||||
|
||||
/*! obtains the counter of the given operation */
|
||||
std::size_t count(Operation_id id) const;
|
||||
|
||||
/*! prints the counter associated with an operation. */
|
||||
template <typename OutStream>
|
||||
OutStream& print(OutStream& os, Operation_id id) const;
|
||||
|
||||
/// \name Types and functors inherited from `BaseTraits`
|
||||
/// @{
|
||||
|
||||
using Has_left_category = typename Base::Has_left_category;
|
||||
using Has_merge_category = typename Base::Has_merge_category;
|
||||
using Has_do_intersect_category = typename Base::Has_do_intersect_category;
|
||||
|
||||
using Left_side_category =
|
||||
typename internal::Arr_complete_left_side_category<Base>::Category;
|
||||
using Bottom_side_category =
|
||||
typename internal::Arr_complete_bottom_side_category<Base>::Category;
|
||||
using Top_side_category =
|
||||
typename internal::Arr_complete_top_side_category<Base>::Category;
|
||||
using Right_side_category =
|
||||
typename internal::Arr_complete_right_side_category<Base>::Category;
|
||||
|
||||
using Point_2 = typename Base::Point_2;
|
||||
using X_monotone_curve_2 = typename Base::X_monotone_curve_2;
|
||||
using Curve_2 = typename Base::Curve_2;
|
||||
|
||||
/// @}
|
||||
|
||||
/// \name Obtain the appropriate functor
|
||||
/// @{
|
||||
|
||||
Compare_x_2 compare_x_2_object() const;
|
||||
Compare_xy_2 compare_xy_2_object() const;
|
||||
Construct_min_vertex_2 construct_min_vertex_2_object() const;
|
||||
Construct_max_vertex_2 construct_max_vertex_2_object() const;
|
||||
Is_vertical_2 is_vertical_2_object() const;
|
||||
Compare_y_at_x_2 compare_y_at_x_2_object() const;
|
||||
Equal_2 equal_2_object() const;
|
||||
Compare_y_at_x_left_2 compare_y_at_x_left_2_object() const;
|
||||
Compare_y_at_x_right_2 compare_y_at_x_right_2_object() const;
|
||||
Make_x_monotone_2 make_x_monotone_2_object() const;
|
||||
Split_2 split_2_object() const;
|
||||
Intersect_2 intersect_2_object() const;
|
||||
Are_mergeable_2 are_mergeable_2_object() const;
|
||||
Merge_2 merge_2_object() const;
|
||||
Construct_opposite_2 construct_opposite_2_object() const;
|
||||
Compare_endpoints_xy_2 compare_endpoints_xy_2_object() const;
|
||||
Approximate_2 approximate_2_object() const;
|
||||
Parameter_space_in_x_2 parameter_space_in_x_2_object() const;
|
||||
Is_on_x_identification_2 is_on_x_identification_2_object() const;
|
||||
Compare_y_on_boundary_2 compare_y_on_boundary_2_object() const;
|
||||
Compare_y_near_boundary_2 compare_y_near_boundary_2_object() const;
|
||||
Parameter_space_in_y_2 parameter_space_in_y_2_object() const;
|
||||
Is_on_y_identification_2 is_on_y_identification_2_object() const;
|
||||
Compare_x_on_boundary_2 compare_x_on_boundary_2_object() const;
|
||||
Compare_x_near_boundary_2 compare_x_near_boundary_2_object() const;
|
||||
|
||||
/// @}
|
||||
|
||||
/*! cleans all operation counters */
|
||||
void clear_counters();
|
||||
};
|
||||
|
||||
template <typename OutStream, class BaseTraits>
|
||||
inline OutStream& operator<<(OutStream& os,
|
||||
const Arr_counting_traits_2<BaseTraits>& traits);
|
||||
} // namespace CGAL
|
||||
|
|
@ -101,8 +101,7 @@ public:
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! default constructor.
|
||||
*/
|
||||
/*! constructs default */
|
||||
Curve_2();
|
||||
|
||||
/*! constructs curve from the given `base` curve with uninitialized
|
||||
|
|
@ -131,49 +130,49 @@ public:
|
|||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_curve_data_traits_2::Curve_2 */
|
||||
}; /* end Arr_curve_data_traits_2::Curve_2 */
|
||||
|
||||
/*! The `X_monotone_curve_2` class nested within the curve-data traits extends
|
||||
* the `Base_traits_2::X_monotone_curve_2` type with an extra data field.
|
||||
*/
|
||||
class X_monotone_curve_2 : public Base_x_monotone_curve_2 {
|
||||
public:
|
||||
|
||||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! default constructor.
|
||||
/*! The `X_monotone_curve_2` class nested within the curve-data traits extends
|
||||
* the `Base_traits_2::X_monotone_curve_2` type with an extra data field.
|
||||
*/
|
||||
X_monotone_curve_2();
|
||||
class X_monotone_curve_2 : public Base_x_monotone_curve_2 {
|
||||
public:
|
||||
|
||||
/*! constructs an \f$ x\f$-monotone curve from the given `base` curve with
|
||||
* uninitialized data field.
|
||||
*/
|
||||
X_monotone_curve_2(const Base_x_monotone_curve_2& base);
|
||||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! constructs an \f$ x\f$-monotone curve from the given `base` \f$
|
||||
* x\f$-monotone curve with an attached `data` field.
|
||||
*/
|
||||
X_monotone_curve_2(const Base_x_monotone_curve_2& base,
|
||||
const X_monotone_curve_data& data);
|
||||
/*! constructs default */
|
||||
X_monotone_curve_2();
|
||||
|
||||
/// @}
|
||||
/*! constructs an \f$ x\f$-monotone curve from the given `base` curve with
|
||||
* uninitialized data field.
|
||||
*/
|
||||
X_monotone_curve_2(const Base_x_monotone_curve_2& base);
|
||||
|
||||
/// \name Access Functions
|
||||
/// @{
|
||||
/*! constructs an \f$ x\f$-monotone curve from the given `base` \f$
|
||||
* x\f$-monotone curve with an attached `data` field.
|
||||
*/
|
||||
X_monotone_curve_2(const Base_x_monotone_curve_2& base,
|
||||
const X_monotone_curve_data& data);
|
||||
|
||||
/*! returns the field (a non-const version, which returns a reference
|
||||
* to the data object, is also available).
|
||||
*/
|
||||
const X_monotone_curve_data& data() const;
|
||||
/// @}
|
||||
|
||||
/*! sets the data field.
|
||||
*/
|
||||
void set_data(const X_monotone_curve_data& data);
|
||||
/// \name Access Functions
|
||||
/// @{
|
||||
|
||||
/// @}
|
||||
/*! returns the field (a non-const version, which returns a reference
|
||||
* to the data object, is also available).
|
||||
*/
|
||||
const X_monotone_curve_data& data() const;
|
||||
|
||||
}; /* end Arr_curve_data_traits_2::X_monotone_curve_2 */
|
||||
/*! sets the data field.
|
||||
*/
|
||||
void set_data(const X_monotone_curve_data& data);
|
||||
|
||||
/// @}
|
||||
|
||||
}; /* end Arr_curve_data_traits_2::X_monotone_curve_2 */
|
||||
|
||||
}; /* end Arr_curve_data_traits_2 */
|
||||
|
||||
} /* end namespace CGAL */
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ namespace CGAL {
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! Constructs a point from a direction and a location.
|
||||
/*! constructs a point from a direction and a location.
|
||||
* \param[in] dir the direction.
|
||||
* \param[in] location indicates the location of the point pre-image
|
||||
* in the parameter space.
|
||||
|
|
@ -94,13 +94,13 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Set the location of the point pre-image in the parameter space.
|
||||
/*! sets the location of the point pre-image in the parameter space.
|
||||
* \param[in] location the updated location of the point pre-image in
|
||||
* the parameter space.
|
||||
*/
|
||||
void set_location(Location_type location);
|
||||
|
||||
/*! Obtain the location of the point.
|
||||
/*! obtains the location of the point.
|
||||
* \return the location of the point pre-image in the parameter space.
|
||||
*/
|
||||
Location_type location() const;
|
||||
|
|
@ -126,7 +126,7 @@ namespace CGAL {
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! Constructs an \f$x\f$-monotone geodesic arc.
|
||||
/*! constructs an \f$x\f$-monotone geodesic arc.
|
||||
* \param[in] source the source point of the arc.
|
||||
* \param[in] target the target point of the arc.
|
||||
* \param[in] normal the normal of the plane that contains the arc.
|
||||
|
|
@ -146,7 +146,7 @@ namespace CGAL {
|
|||
bool is_degenerate = false,
|
||||
bool is_empty = false);
|
||||
|
||||
/*! Construct an \f$x\f$-monotone geodesic arc.
|
||||
/*! construct an \f$x\f$-monotone geodesic arc.
|
||||
* \param[in] normal the normal of the plane containing the arc.
|
||||
* \param[in] source the source-point direction.
|
||||
* \param[in] target the target-point direction.
|
||||
|
|
@ -156,7 +156,7 @@ namespace CGAL {
|
|||
const Point_2& target,
|
||||
const Direction_3& normal);
|
||||
|
||||
/*! Construct a full great-circle.
|
||||
/*! construct a full great-circle.
|
||||
* \param[in] point the endpoint of the full great-circle.
|
||||
* \param[in] normal the normal of the plane containing the arc.
|
||||
* \pre the point lies on the given plane.
|
||||
|
|
@ -171,90 +171,90 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Sets the source endpoint.
|
||||
/*! sets the source endpoint.
|
||||
* \param[in] source the updated source endpoint.
|
||||
*/
|
||||
void set_source(const Point_2& source);
|
||||
|
||||
/*! Sets the target endpoint.
|
||||
/*! sets the target endpoint.
|
||||
* \param[in] target the updated target endpoint.
|
||||
*/
|
||||
void set_target(const Point_2& target);
|
||||
|
||||
/*! Sets the normal of the underlying plane.
|
||||
/*! sets the normal of the underlying plane.
|
||||
* \param[in] normal the updated normal of the underlying plane.
|
||||
*/
|
||||
void set_normal(const Direction_3& normal);
|
||||
|
||||
/*! Sets the flag that indicates whether the arc is vertical.
|
||||
/*! sets the flag that indicates whether the arc is vertical.
|
||||
* \param[in] flag indicates whether the arc pre-image in the parameter
|
||||
* space is vertical.
|
||||
*/
|
||||
void set_is_vertical(bool flag);
|
||||
|
||||
/*! Sets the flag that indicates whether the direction of the arc
|
||||
/*! sets the flag that indicates whether the direction of the arc
|
||||
* pre-image in the parameter space is from left to right.
|
||||
* \param flag indicates whether the arc pre-image in the parameter
|
||||
* space is from left to right.
|
||||
*/
|
||||
void set_is_directed_right(bool flag);
|
||||
|
||||
/*! Sets the flag that indicates whether the arc is a full great circle.
|
||||
/*! sets the flag that indicates whether the arc is a full great circle.
|
||||
* \param[in] flag indicates whether the arc is a full great circle.
|
||||
*/
|
||||
void set_is_full(bool flag);
|
||||
|
||||
/*! Sets the flag that indicates whether the arc degenerates to a point.
|
||||
/*! sets the flag that indicates whether the arc degenerates to a point.
|
||||
* \param[in] flag indicates whether the arc degenerates to a point.
|
||||
*/
|
||||
void set_is_degenerate(bool flag);
|
||||
|
||||
/*! Sets the flag that indicates whether the arc is empty.
|
||||
/*! sets the flag that indicates whether the arc is empty.
|
||||
* \param[in] flag indicates whether the arc is empty.
|
||||
*/
|
||||
void set_is_empty(bool flag);
|
||||
|
||||
/*! Obtains the source point.
|
||||
/*! obtains the source point.
|
||||
*/
|
||||
const Point_2& source() const;
|
||||
|
||||
/*! Obtains the target point.
|
||||
/*! obtains the target point.
|
||||
*/
|
||||
const Point_2& target() const;
|
||||
|
||||
/*! Obtains the normal to the containing plane.
|
||||
/*! obtains the normal to the containing plane.
|
||||
*/
|
||||
const Direction_3& normal() const;
|
||||
|
||||
/*! Obtains the (lexicographically) left endpoint direction.
|
||||
/*! obtains the (lexicographically) left endpoint direction.
|
||||
*/
|
||||
const Point_2& left() const;
|
||||
|
||||
/*! Obtains the (lexicographically) right endpoint.
|
||||
/*! obtains the (lexicographically) right endpoint.
|
||||
*/
|
||||
const Point_2& right() const;
|
||||
|
||||
/*! Determines whether the arc is vertical.
|
||||
/*! determines whether the arc is vertical.
|
||||
*/
|
||||
bool is_vertical() const;
|
||||
|
||||
/*! Determines whether the arc is directed lexicographically from left to
|
||||
/*! determines whether the arc is directed lexicographically from left to
|
||||
* right.
|
||||
*/
|
||||
bool is_directed_right() const;
|
||||
|
||||
/*! Determines whether the arc is a great circle.
|
||||
/*! determines whether the arc is a great circle.
|
||||
*/
|
||||
bool is_full() const;
|
||||
|
||||
/*! Determines whether the arc is degenerate.
|
||||
/*! determines whether the arc is degenerate.
|
||||
*/
|
||||
bool is_degenerate() const;
|
||||
|
||||
/*! Determines whether the arc is empty. */
|
||||
/*! determines whether the arc is empty. */
|
||||
bool is_empty() const;
|
||||
|
||||
/*! Determines whether the arc is a meridian.
|
||||
/*! determines whether the arc is a meridian.
|
||||
*/
|
||||
bool is_meridian() const;
|
||||
|
||||
|
|
@ -283,6 +283,7 @@ namespace CGAL {
|
|||
*
|
||||
* \cgalModels{Assignable,CopyConstructible,AdaptableUnaryFunction,AdaptableTernaryFunction}
|
||||
*/
|
||||
|
||||
/*!
|
||||
*/
|
||||
class Construct_point_2 {
|
||||
|
|
@ -297,7 +298,7 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Construct a point on the sphere from three coordinates, which define
|
||||
/*! constructs a point on the sphere from three coordinates, which define
|
||||
* a (not necessarily normalized) direction.
|
||||
* \param[in] x the x coordinate
|
||||
* \param[in] y the y coordinate
|
||||
|
|
@ -305,7 +306,7 @@ namespace CGAL {
|
|||
*/
|
||||
Point_2 operator()(const FT& x, const FT& y, const FT& z);
|
||||
|
||||
/*! Construct a point on the sphere from a (not necessarily normalized)
|
||||
/*! constructs a point on the sphere from a (not necessarily normalized)
|
||||
* direction.
|
||||
* \param other the other direction
|
||||
*/
|
||||
|
|
@ -331,7 +332,7 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Construct the minor geodesic arc from two endpoints. The minor arc
|
||||
/*! constructs the minor geodesic arc from two endpoints. The minor arc
|
||||
* is the one with the smaller angle among the two geodesic arcs with
|
||||
* the given endpoints.
|
||||
* 1. Find out whether the arc is x-monotone.
|
||||
|
|
@ -351,7 +352,7 @@ namespace CGAL {
|
|||
*/
|
||||
X_monotone_curve_2 operator()(const Point_2& p, const Point_2& q);
|
||||
|
||||
/*! Construct a full great circle from a normal to a plane.
|
||||
/*! constructs a full great circle from a normal to a plane.
|
||||
* Observe that the constructed arc has one endpoint that lies on
|
||||
* the identification curve. This point is considered both the source and
|
||||
* target (and also the left and right) point of the arc.
|
||||
|
|
@ -360,7 +361,7 @@ namespace CGAL {
|
|||
*/
|
||||
X_monotone_curve_2 operator()(const Direction_3& normal);
|
||||
|
||||
/*! Construct a geodesic arc from two endpoints and a normal to the plane
|
||||
/*! constructs a geodesic arc from two endpoints and a normal to the plane
|
||||
* containing the arc. The two endpoints determine the plane. The normal
|
||||
* determines the orientation of the plane and the final arc (whether its
|
||||
* the minor arc or the major arc). The right-hand rule can be used
|
||||
|
|
@ -395,12 +396,12 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Construct a full great circle from a normal to a plane.
|
||||
/*! constructs a full great circle from a normal to a plane.
|
||||
* \param normal the normal to the plane containing the great circle.
|
||||
*/
|
||||
X_monotone_curve_2 operator()(const Direction_3& normal);
|
||||
|
||||
/*! Construct the minor geodesic arc from two endpoints. The minor arc
|
||||
/*! constructs the minor geodesic arc from two endpoints. The minor arc
|
||||
* is the one with the smaller angle among the two geodesic arcs with
|
||||
* the given endpoints.
|
||||
* 1. Find out whether the arc is x-monotone.
|
||||
|
|
@ -419,7 +420,7 @@ namespace CGAL {
|
|||
*/
|
||||
Curve_2 operator()(const Point_2& p, const Point_2& q);
|
||||
|
||||
/*! Construct a geodesic arc from two endpoints and a normal to the plane
|
||||
/*! constructs a geodesic arc from two endpoints and a normal to the plane
|
||||
* containing the arc. The two endpoints determine the plane. The normal
|
||||
* determines the orientation of the plane and the final arc (whether its
|
||||
* the minor arc or the major arc). The right-hand rule can be used
|
||||
|
|
@ -434,15 +435,15 @@ namespace CGAL {
|
|||
/// @}
|
||||
};
|
||||
|
||||
/*! Returns an instance of `Construct_point_2`.
|
||||
/*! returns an instance of `Construct_point_2`.
|
||||
*/
|
||||
Construct_point_2 construct_point_2_object() const;
|
||||
|
||||
/*! Returns an instance of `Construct_x_monotone_curve_2`.
|
||||
/*! returns an instance of `Construct_x_monotone_curve_2`.
|
||||
*/
|
||||
Construct_x_monotone_curve_2 construct_x_monotone_curve_2_object() const;
|
||||
|
||||
/*! Returns an instance of `Construct_curve_2`.
|
||||
/*! returns an instance of `Construct_curve_2`.
|
||||
*/
|
||||
Construct_curve_2 construct_curve_2_object() const;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ namespace CGAL {
|
|||
*
|
||||
* \cgalModels{ArrangementTraits_2,ArrangementLandmarkTraits_2,ArrangementOpenBoundaryTraits_2}
|
||||
*/
|
||||
template< typename Kernel >
|
||||
template <typename Kernel>
|
||||
class Arr_linear_traits_2 {
|
||||
public:
|
||||
|
||||
|
|
@ -147,7 +147,7 @@ public:
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! Trims the given x-monotone curve to an from src to tgt.
|
||||
/*! trims the given x-monotone curve to an from src to tgt.
|
||||
* \ pre `src` and `tgt` lies on the curve
|
||||
*/
|
||||
X_monotone_curve_2 operator()(const X_monotone_curve_2& xcv,
|
||||
|
|
|
|||
|
|
@ -93,6 +93,7 @@ namespace CGAL {
|
|||
|
||||
/// \name Types
|
||||
/// @{
|
||||
|
||||
/*!
|
||||
*/
|
||||
// TODO: Have to turn these into links, so whenever I mention Point_2 it
|
||||
|
|
@ -119,14 +120,14 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Obtain a polycurve that comprises of one given subcurve.
|
||||
/*! obtains a polycurve that comprises of one given subcurve.
|
||||
* \param subcurve input subcurve.
|
||||
* \pre `subcurve` is not degenerated (not tested).
|
||||
* \return A polycurve with one subcurve, namely `subcurve`.
|
||||
*/
|
||||
Curve_2 operator()(const Subcurve_2& subcurve) const;
|
||||
|
||||
/*! Construct a well-oriented polycurve from a range of either
|
||||
/*! constructs a well-oriented polycurve from a range of either
|
||||
* `SubcurveTraits_2::Point_2` or `SubcurveTraits_2::Curve_2`.
|
||||
*
|
||||
* \param begin iterator pointing to the first element in the
|
||||
|
|
@ -169,17 +170,17 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Append a subcurve `subcurve` to an existing polycurve `cv` at the back.
|
||||
* If `cv` is empty, `subcurve` will be its first subcurve.
|
||||
/*! appends a subcurve `subcurve` to an existing polycurve `cv` at the
|
||||
* back. If `cv` is empty, `subcurve` will be its first subcurve.
|
||||
* \param cv a polycurve. Note, `cv` is (not necessarily) \f$x\f$-monotone.
|
||||
* \param subcurve a subcurve (not necessarily \f$x\f$-monotone) to be
|
||||
* appended to `cv`
|
||||
*/
|
||||
void operator()(Curve_2& cv, const Subcurve_2& subcurve) const;
|
||||
|
||||
/*! Append a subcurve `subcurve` to an existing \f$x\f$-monotone polycurve
|
||||
* `xcv` at the back. If `xcv` is empty, `subcurve` will be its first
|
||||
* subcurve.
|
||||
/*! appends a subcurve `subcurve` to an existing \f$x\f$-monotone
|
||||
* polycurve `xcv` at the back. If `xcv` is empty, `subcurve` will be its
|
||||
* first subcurve.
|
||||
* \param xcv existing \f$x\f$-monotone polycurve
|
||||
* \param subcurve the subcurve to be added
|
||||
* \pre If `xcv` is not empty then `subcurve` extends `xcv` to the right
|
||||
|
|
@ -201,7 +202,7 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Append a subcurve `subcurve` to an existing polycurve `cv` at the
|
||||
/*! appends a subcurve `subcurve` to an existing polycurve `cv` at the
|
||||
* front. If `cv` is empty, `subcurve` will be its first subcurve.
|
||||
* \param cv a polycurve. Note, `cv` is (not necessarily) \f$x\f$-monotone.
|
||||
* \param subcurve a subcurve (not necessarily \f$x\f$-monotone) to be
|
||||
|
|
@ -209,9 +210,9 @@ namespace CGAL {
|
|||
*/
|
||||
void operator()(Curve_2& cv, const Subcurve_2& subcurve) const;
|
||||
|
||||
/*! Append a subcurve `subcurve` to an existing \f$x\f$-monotone polycurve
|
||||
* `xcv` at the front. If `xcv` is empty, `subcurve` will be its first
|
||||
* subcurve.
|
||||
/*! appends a subcurve `subcurve` to an existing \f$x\f$-monotone
|
||||
* polycurve `xcv` at the front. If `xcv` is empty, `subcurve` will be its
|
||||
* first subcurve.
|
||||
* \param xcv existing \f$x\f$-monotone polycurve
|
||||
* \param subcurve the subcurve to be added
|
||||
* \pre If `xcv` is not empty then `subcurve` extends `xcv` to the left if
|
||||
|
|
@ -228,7 +229,7 @@ namespace CGAL {
|
|||
|
||||
class Trim_2 {
|
||||
public:
|
||||
/*! Obtain a trimmed version of the polycurve with src and tgt as end
|
||||
/*! obtains a trimmed version of the polycurve with src and tgt as end
|
||||
* vertices.
|
||||
* Src and tgt will be swapped if they do not conform to the direction of
|
||||
* the polycurve.
|
||||
|
|
@ -238,7 +239,7 @@ namespace CGAL {
|
|||
const Point_2& tgt) const;
|
||||
};
|
||||
|
||||
/*! Subdivide a given subcurve into \f$x\f$-monotone subcurves and
|
||||
/*! subdivides a given subcurve into \f$x\f$-monotone subcurves and
|
||||
* isolated points, and insert them into an output container. An object in
|
||||
* the output container is represented by a discriminated union container
|
||||
* that holds either a point or an \f$x\f$-monotone curve.
|
||||
|
|
@ -273,10 +274,10 @@ namespace CGAL {
|
|||
*
|
||||
* The copy and default constructor as well as the assignment operator are
|
||||
* provided for polycurve subcurves. In addition, an \link
|
||||
* PkgArrangementOnSurface2op_left_shift `operator<<` \endlink for the subcurves is
|
||||
* defined for standard output streams, and an \link
|
||||
* PkgArrangementOnSurface2op_right_shift `operator>>` \endlink for the subcurves is
|
||||
* defined for standard input streams.
|
||||
* PkgArrangementOnSurface2op_left_shift `operator<<` \endlink for the
|
||||
* subcurves is defined for standard output streams, and an \link
|
||||
* PkgArrangementOnSurface2op_right_shift `operator>>` \endlink for the
|
||||
* subcurves is defined for standard input streams.
|
||||
*/
|
||||
template <typename SubcurveType_2, typename PointType_2>
|
||||
class Curve_2 {
|
||||
|
|
@ -323,15 +324,15 @@ namespace CGAL {
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! Default constructor that constructs an empty polycurve.
|
||||
/*! constructs Default; constructs an empty polycurve.
|
||||
*/
|
||||
Curve_2();
|
||||
|
||||
/*! Construct a polycurve from one subcurve.
|
||||
/*! constructs a polycurve from one subcurve.
|
||||
*/
|
||||
Curve_2(const Subcurve_2 subcurve);
|
||||
|
||||
/*! Construct a polycurve defined by the given range of subcurves
|
||||
/*! constructs a polycurve defined by the given range of subcurves
|
||||
* `[first, last)` (the value-type of `InputIterator` must be
|
||||
* `SubcurveTraits_2::Curve_2`. In general, the subcurves might not
|
||||
* be \f$x\f$-monotone, furthermore, they might not form a
|
||||
|
|
@ -357,7 +358,7 @@ namespace CGAL {
|
|||
/// @{
|
||||
|
||||
/*! \deprecated
|
||||
* Obtain the number of subcurve end-points that comprise the polycurve.
|
||||
* obtains the number of subcurve end-points that comprise the polycurve.
|
||||
* Note that for a bounded polycurve, if there are \f$ n\f$ points in the
|
||||
* polycurve, it comprises \f$ (n - 1)\f$ subcurves.
|
||||
* Currently, only bounded polycurves are supported.
|
||||
|
|
@ -365,20 +366,21 @@ namespace CGAL {
|
|||
unsigned_int points() const;
|
||||
|
||||
/*! \deprecated
|
||||
* Obtain an iterator pointing at the source point of the polycurve.
|
||||
* obtains an iterator pointing at the source point of the polycurve.
|
||||
*/
|
||||
const_iterator begin() const;
|
||||
|
||||
/*! Obtain an iterator pointing at the first subcurve of the polycurve.
|
||||
/*! obtains an iterator pointing at the first subcurve of the polycurve.
|
||||
*/
|
||||
Subcurve_const_iterator begin_subcurves() const;
|
||||
|
||||
/*! \deprecated
|
||||
* Obtain an iterator pointing after the end of the polycurve.
|
||||
* obtains an iterator pointing after the end of the polycurve.
|
||||
*/
|
||||
const_iterator end() const;
|
||||
|
||||
/*! Get an iterator pointing at the past-the-end subcurve of the polycurve.
|
||||
/*! obtains an iterator pointing at the past-the-end subcurve of the
|
||||
* polycurve.
|
||||
*/
|
||||
Subcurve_const_iterator end_subcurves() const;
|
||||
|
||||
|
|
@ -387,38 +389,38 @@ namespace CGAL {
|
|||
*/
|
||||
const_iterator rbegin() const;
|
||||
|
||||
/*! Obtain an iterator pointing at the last subcurve of the polycurve.
|
||||
/*! obtains an iterator pointing at the last subcurve of the polycurve.
|
||||
*/
|
||||
Subcurve_const_reverse_iterator rbegin_subcurves() const;
|
||||
|
||||
/*! \deprecated
|
||||
* Obtain an iterator pointing before the beginning of the polycurve.
|
||||
* obtains an iterator pointing before the beginning of the polycurve.
|
||||
*/
|
||||
const_iterator rend() const;
|
||||
|
||||
/*! Obtain an iterator pointing at the past-the-end subcurve of
|
||||
/*! obtains an iterator pointing at the past-the-end subcurve of
|
||||
* the polycurve in reverse order.
|
||||
*/
|
||||
Subcurve_const_reverse_iterator rend_subcurves() const;
|
||||
|
||||
/*! \deprecated
|
||||
* Obtain the number of subcurves composing the polycurve
|
||||
* obtains the number of subcurves composing the polycurve
|
||||
* (equivalent to `pi.points() - 1`). Was replaced by number_of_subcurves()
|
||||
*/
|
||||
size_type size() const;
|
||||
|
||||
/*! Obtain the number of subcurves that comprise the polycurve.
|
||||
/*! obtains the number of subcurves that comprise the polycurve.
|
||||
*/
|
||||
size_type number_of_subcurves() const;
|
||||
|
||||
/*! Obtain the \f$ k\f$th subcurve of the polycurve.
|
||||
/*! obtains the \f$ k\f$th subcurve of the polycurve.
|
||||
* \pre \f$k\f$ is not greater than or equal to \f$n-1\f$, where
|
||||
* \f$n\f$ is the number of subcurves.
|
||||
*/
|
||||
typename SubcurveTraits_2::X_monotone_curve_2
|
||||
operator[](size_t k) const;
|
||||
|
||||
/*! Obtain the bounding box of the polycurve.
|
||||
/*! obtains the bounding box of the polycurve.
|
||||
*/
|
||||
Bbox_2 bbox() const;
|
||||
|
||||
|
|
@ -427,7 +429,7 @@ namespace CGAL {
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Append a subcurve to the polycurve at the back.
|
||||
/*! appends a subcurve to the polycurve at the back.
|
||||
* \a Warning: This function does not perform the precondition test
|
||||
* that the `Push_back_2` functor does. Thus, it is
|
||||
* recommended to use the latter.
|
||||
|
|
@ -438,7 +440,7 @@ namespace CGAL {
|
|||
*/
|
||||
inline void push_back(const Subcurve_2& subcurve);
|
||||
|
||||
/*! Append a subcurve to the polycurve at the front.
|
||||
/*! appends a subcurve to the polycurve at the front.
|
||||
* \a Warning: This is a risky function! Don't use it! Prefer the
|
||||
* corresponding functor which is provided in the traits
|
||||
* class.
|
||||
|
|
@ -450,12 +452,12 @@ namespace CGAL {
|
|||
inline void push_front(const Subcurve_2& subcurve);
|
||||
|
||||
/*! \deprecated
|
||||
* Add a new point to the polycurvs, which becomes the new target point
|
||||
* adds a new point to the polycurvs, which becomes the new target point
|
||||
* of `pi`.
|
||||
*/
|
||||
void push_back(const Point_2 & p);
|
||||
|
||||
/*! Reset the polycurve.
|
||||
/*! resets the polycurve.
|
||||
*/
|
||||
void clear();
|
||||
|
||||
|
|
@ -463,7 +465,6 @@ namespace CGAL {
|
|||
|
||||
}; /* end Arr_polycurve_traits_2::Curve_2 */
|
||||
|
||||
|
||||
/*! The `X_monotone_curve_2` class nested within the polycurve
|
||||
* traits is used to represent \f$ x\f$-monotone piecewise linear subcurves.
|
||||
*
|
||||
|
|
@ -518,4 +519,5 @@ namespace CGAL {
|
|||
/// @} /* End Accessing Functor Objects */
|
||||
|
||||
}; /* end Arr_polycurve_traits_2 */
|
||||
|
||||
} /* end namespace CGAL */
|
||||
|
|
|
|||
|
|
@ -149,7 +149,7 @@ public:
|
|||
//! obtains the past-the-end reverse iterator for the polyline points.
|
||||
Segment_const_reverse_iterator rend_segments() const;
|
||||
|
||||
/*! Obtain the number of subcurves that comprise the poyline.
|
||||
/*! obtains the number of subcurves that comprise the poyline.
|
||||
* \return The number of subcurves.
|
||||
*/
|
||||
Segments_size_type number_of_segments() const;
|
||||
|
|
@ -169,13 +169,13 @@ public:
|
|||
typedef std::reverse_iterator<Segment_const_iterator>
|
||||
Segment_const_reverse_iterator;
|
||||
|
||||
/*! Construct default. */
|
||||
/*! constructs default. */
|
||||
X_monotone_curve_2();
|
||||
|
||||
/*! Construct from a subcurve. */
|
||||
/*! constructs from a subcurve. */
|
||||
X_monotone_curve_2(X_monotone_segment_2 seg);
|
||||
|
||||
/*! Construct from a range. Similar to the constructor of a general
|
||||
/*! constructs from a range. Similar to the constructor of a general
|
||||
* polycurve. Like in the case of general polycurve, for the sake of
|
||||
* backwards compatibility we have to keep an implementation of construction
|
||||
* from a range of points. DO NOT USE THIS CONSTRUCTION.
|
||||
|
|
@ -183,23 +183,23 @@ public:
|
|||
template <typename InputIterator>
|
||||
X_monotone_curve_2(InputIterator begin, InputIterator end);
|
||||
|
||||
/*! Obtain the first iterator of the polyline subcurves.
|
||||
/*! obtains the first iterator of the polyline subcurves.
|
||||
*/
|
||||
Segment_const_iterator begin_segments() const;
|
||||
|
||||
/*! Obtain the past-the-end iterator of the polyline subcurves.
|
||||
/*! obtains the past-the-end iterator of the polyline subcurves.
|
||||
*/
|
||||
Segment_const_iterator end_segments() const;
|
||||
|
||||
/*! Obtain the first reverse iterator of the polyline subcurves.
|
||||
/*! obtains the first reverse iterator of the polyline subcurves.
|
||||
*/
|
||||
Segment_const_reverse_iterator rbegin_segments() const;
|
||||
|
||||
/*! Obtain the past-the-end reverse iterator for the polyline points.
|
||||
/*! obtains the past-the-end reverse iterator for the polyline points.
|
||||
*/
|
||||
Segment_const_reverse_iterator rend_segments() const;
|
||||
|
||||
/*! Obtain the number of subcurves that comprise the poyline.
|
||||
/*! obtains the number of subcurves that comprise the poyline.
|
||||
* \return The number of subcurves.
|
||||
*/
|
||||
Segments_size_type number_of_segments() const;
|
||||
|
|
@ -219,7 +219,7 @@ public:
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Obtain a polyline connecting the two given endpoints.
|
||||
/*! obtains a polyline connecting the two given endpoints.
|
||||
* \param p The first point.
|
||||
* \param q The second point.
|
||||
* \pre `p` and `q` are distinct.
|
||||
|
|
@ -227,14 +227,14 @@ public:
|
|||
*/
|
||||
Curve_2 operator()(const Point_2& p, const Point_2& q) const;
|
||||
|
||||
/*! Obtain a polyline that comprises of one given segment.
|
||||
/*! obtains a polyline that comprises of one given segment.
|
||||
* \param seg input segment
|
||||
* \pre `seg` is not degenerated (not tested)
|
||||
* \return A polyline with one segment, namely `seg`.
|
||||
*/
|
||||
Curve_2 operator()(const Segment_2& seg) const;
|
||||
|
||||
/*! Construct a well-oriented polyline from a range of either
|
||||
/*! constructs a well-oriented polyline from a range of either
|
||||
* `SegmentTraits_2::Point_2` or `SegmentTraits_2::Segment_2`.
|
||||
*
|
||||
* \param begin iterator pointing to the first element in the range.
|
||||
|
|
@ -270,7 +270,7 @@ public:
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Append a point `p` to an existing polyline `cv` at the back.
|
||||
/*! appends a point `p` to an existing polyline `cv` at the back.
|
||||
* \param cv a polyline. Note, `cv` is not (necessarily)
|
||||
* \f$ x\f$-monotone.
|
||||
* \param p a point to be appended to `cv` at the back.
|
||||
|
|
@ -278,7 +278,7 @@ public:
|
|||
*/
|
||||
void operator()(Curve_2& cv, const Point_2& p) const;
|
||||
|
||||
/*! Append a segment `seg` to an existing polyline `cv` at the back.
|
||||
/*! appends a segment `seg` to an existing polyline `cv` at the back.
|
||||
* If `cv` is empty, `seg` will be its first segment.
|
||||
* \param cv a polyline. Note, `cv` is (not necessarily) \f$x\f$-monotone.
|
||||
* \param seg a segment (not necessarily \f$x\f$-monotone) to be appended
|
||||
|
|
@ -286,7 +286,7 @@ public:
|
|||
*/
|
||||
void operator()(Curve_2& cv, const Segment_2& seg) const;
|
||||
|
||||
/*! Append a point `p` to an existing \f$x\f$-monotone polyline `xcv` at
|
||||
/*! appends a point `p` to an existing \f$x\f$-monotone polyline `xcv` at
|
||||
* the back.
|
||||
* \param xcv the existing \f$x\f$-monotone polyline
|
||||
* \param p the point to be pushed back.
|
||||
|
|
@ -297,7 +297,7 @@ public:
|
|||
*/
|
||||
void operator()(const X_monotone_curve_2& xcv, Point_2& p) const;
|
||||
|
||||
/*! Append a segment `seg` to an existing \f$x\f$-monotone polyline `xcv`
|
||||
/*! appends a segment `seg` to an existing \f$x\f$-monotone polyline `xcv`
|
||||
* at the back. If `xcv` is empty, `seg` will be its first segment.
|
||||
* \param xcv existing \f$x\f$-monotone polyline
|
||||
* \param seg the segment to be added
|
||||
|
|
@ -320,7 +320,7 @@ public:
|
|||
/// \name Operations
|
||||
/// @{
|
||||
|
||||
/*! Append a point `p` to an existing polyline `cv` at the front.
|
||||
/*! appends a point `p` to an existing polyline `cv` at the front.
|
||||
* \param cv a polyline. Note, `cv` is not (necessarily)
|
||||
* \f$ x\f$-monotone.
|
||||
* \param p a point to be appended to `cv` at the back.
|
||||
|
|
@ -328,7 +328,7 @@ public:
|
|||
*/
|
||||
void operator()(Curve_2& cv, const Point_2& p) const;
|
||||
|
||||
/*! Append a segment `seg` to an existing polyline `cv` at the front.
|
||||
/*! appends a segment `seg` to an existing polyline `cv` at the front.
|
||||
* If `cv` is empty, `seg` will be its first segment.
|
||||
* \param cv a polyline. Note, `cv` is (not necessarily) \f$x\f$-monotone.
|
||||
* \param seg a segment (not necessarily \f$x\f$-monotone) to be appended
|
||||
|
|
@ -336,7 +336,7 @@ public:
|
|||
*/
|
||||
void operator()(Curve_2& cv, const Segment_2& seg) const;
|
||||
|
||||
/*! Append a point `p` to an existing \f$x\f$-monotone polyline `xcv` at
|
||||
/*! appends a point `p` to an existing \f$x\f$-monotone polyline `xcv` at
|
||||
* the front.
|
||||
* \param xcv the existing \f$x\f$-monotone polyline
|
||||
* \param p the point to be pushed back.
|
||||
|
|
@ -347,7 +347,7 @@ public:
|
|||
*/
|
||||
void operator()(const X_monotone_curve_2& xcv, Point_2& p) const;
|
||||
|
||||
/*! Append a segment `seg` to an existing \f$x\f$-monotone polyline `xcv`
|
||||
/*! appends a segment `seg` to an existing \f$x\f$-monotone polyline `xcv`
|
||||
* at the front. If `xcv` is empty, `seg` will be its first segment.
|
||||
* \param xcv existing \f$x\f$-monotone polyline
|
||||
* \param seg the segment to be added
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -121,6 +121,7 @@ public:
|
|||
X_monotone_curve_2(const X_monotone_curve_2& xcv,
|
||||
const Point_2& src, const Point_2& tgt) const;
|
||||
|
||||
//! @}
|
||||
} /* end Arr_segment_traits_2::Trim_2 */
|
||||
|
||||
}; /* end Arr_segment_traits_2 */
|
||||
|
|
|
|||
|
|
@ -49,10 +49,10 @@ public:
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default */
|
||||
Arr_spherical_topology_traits_2();
|
||||
|
||||
/*! Constructor from a geometry-traits object.
|
||||
/*! constructs from a geometry-traits object.
|
||||
* \param traits the traits.
|
||||
*/
|
||||
Arr_spherical_topology_traits_2(const GeometryTraits_2* traits);
|
||||
|
|
@ -62,36 +62,36 @@ public:
|
|||
/// \name Accessors
|
||||
/// @{
|
||||
|
||||
/*! Obtain the DCEL (const version). */
|
||||
/*! obtains the DCEL (const version). */
|
||||
const Dcel& dcel() const;
|
||||
|
||||
/*! Obtain the DCEL (non-const version). */
|
||||
/*! obtains the DCEL (non-const version). */
|
||||
Dcel& dcel();
|
||||
|
||||
/*! Obtain the spherical face (const version). */
|
||||
/*! obtains the spherical face (const version). */
|
||||
const Face* spherical_face() const;
|
||||
|
||||
/*! Obtain the spherical face (non-const version). */
|
||||
/*! obtains the spherical face (non-const version). */
|
||||
Face* spherical_face();
|
||||
|
||||
/*! Obtain the south pole (const version). */
|
||||
/*! obtains the south pole (const version). */
|
||||
const Vertex* south_pole() const;
|
||||
|
||||
/*! Obtain the south pole (non-const version). */
|
||||
/*! obtains the south pole (non-const version). */
|
||||
Vertex* south_pole();
|
||||
|
||||
/*! Obtain the north pole (const version). */
|
||||
/*! obtains the north pole (const version). */
|
||||
const Vertex* north_pole() const;
|
||||
|
||||
/*! Obtain the north pole (non-const version). */
|
||||
/*! obtains the north pole (non-const version). */
|
||||
Vertex* north_pole();
|
||||
|
||||
/*! Obtain a vertex on the line of discontinuity that corresponds to
|
||||
/*! obtains a vertex on the line of discontinuity that corresponds to
|
||||
* the given point (or return NULL if no such vertex exists).
|
||||
*/
|
||||
const Vertex* discontinuity_vertex(const Point_2& pt) const;
|
||||
|
||||
/*! Obtain a vertex on the line of discontinuity that corresponds to
|
||||
/*! obtains a vertex on the line of discontinuity that corresponds to
|
||||
* the given point (or return NULL if no such vertex exists).
|
||||
*/
|
||||
Vertex* discontinuity_vertex(const Point_2& pt);
|
||||
|
|
|
|||
|
|
@ -0,0 +1,145 @@
|
|||
/// Copyright (c) 2007,2009,2010,2011 Tel-Aviv University (Israel).
|
||||
// All rights reserved.
|
||||
//
|
||||
// This file is part of CGAL (www.cgal.org).
|
||||
//
|
||||
// $URL$
|
||||
// $Id$
|
||||
// SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-Commercial
|
||||
//
|
||||
// Author(s): Efi Fogel <efif@post.tau.ac.il>
|
||||
|
||||
namespace CGAL {
|
||||
|
||||
/*! \ingroup PkgArrangementOnSurface2TraitsClasses
|
||||
*
|
||||
* A metadata traits-class decorator for the arrangement package. It traces the
|
||||
* invocations of traits-class functors. It is parameterized with another traits
|
||||
* class and inherits from it. For each traits method it prints out its input
|
||||
* parameters and its output result
|
||||
*
|
||||
* It models all the concepts that the original traits models.
|
||||
*/
|
||||
template <typename BaseTraits>
|
||||
class Arr_tracing_traits_2 : public BaseTraits {
|
||||
public:
|
||||
enum Operation_id {
|
||||
COMPARE_X_2_OP = 0,
|
||||
COMPARE_XY_2_OP,
|
||||
CONSTRUCT_MIN_VERTEX_2_OP,
|
||||
CONSTRUCT_MAX_VERTEX_2_OP,
|
||||
IS_VERTICAL_2_OP,
|
||||
COMPARE_Y_AT_X_2_OP,
|
||||
EQUAL_POINTS_2_OP,
|
||||
EQUAL_CURVES_2_OP,
|
||||
COMPARE_Y_AT_X_LEFT_2_OP,
|
||||
COMPARE_Y_AT_X_RIGHT_2_OP,
|
||||
MAKE_X_MONOTONE_2_OP,
|
||||
SPLIT_2_OP,
|
||||
INTERSECT_2_OP,
|
||||
ARE_MERGEABLE_2_OP,
|
||||
MERGE_2_OP,
|
||||
CONSTRUCT_2_OPPOSITE_2_OP,
|
||||
COMPARE_ENDPOINTS_XY_2_OP,
|
||||
APPROXIMATE_2_OP,
|
||||
PARAMETER_SPACE_IN_X_2_OP,
|
||||
IS_ON_X_IDENTIFICATION_2_OP,
|
||||
COMPARE_Y_ON_BOUNDARY_2_OP,
|
||||
COMPARE_Y_NEAR_BOUNDARY_2_OP,
|
||||
PARAMETER_SPACE_IN_Y_2_OP,
|
||||
IS_ON_Y_IDENTIFICATION_2_OP,
|
||||
COMPARE_X_ON_BOUNDARY_2_OP,
|
||||
COMPARE_X_NEAR_BOUNDARY_2_OP,
|
||||
NUMBER_OF_OPERATIONS
|
||||
};
|
||||
|
||||
public:
|
||||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! constructs default */
|
||||
template<typename ... Args>
|
||||
Arr_tracing_traits_2(Args ... args) : Base(std::forward<Args>(args)...) {}
|
||||
|
||||
/*! disables copy constructor. */
|
||||
Arr_tracing_traits_2(const Arr_tracing_traits_2&) = delete;
|
||||
|
||||
/// @}
|
||||
|
||||
/*! enables the trace of a traits operation
|
||||
* \param id the operation identifier
|
||||
*/
|
||||
void enable_trace(Operation_id id);
|
||||
|
||||
/*! enables the trace of all traits operations
|
||||
*/
|
||||
void enable_all_traces();
|
||||
|
||||
/*! disables the trace of a traits operation
|
||||
* \param id the operation identifier
|
||||
*/
|
||||
void disable_trace(Operation_id id);
|
||||
|
||||
/*! disables the trace of all traits operations
|
||||
*/
|
||||
void disable_all_traces();
|
||||
|
||||
/// \name Types and functors inherited from `BaseTraits`
|
||||
/// @{
|
||||
|
||||
using Has_left_category = typename Base::Has_left_category;
|
||||
using Has_merge_category = typename Base::Has_merge_category;
|
||||
using Has_do_intersect_category = typename Base::Has_do_intersect_category;
|
||||
|
||||
using Left_side_category =
|
||||
typename internal::Arr_complete_left_side_category< Base >::Category;
|
||||
using Bottom_side_category =
|
||||
typename internal::Arr_complete_bottom_side_category< Base >::Category;
|
||||
using Top_side_category =
|
||||
typename internal::Arr_complete_top_side_category< Base >::Category;
|
||||
using Right_side_category =
|
||||
typename internal::Arr_complete_right_side_category< Base >::Category;
|
||||
|
||||
using Point_2 = typename Base::Point_2;
|
||||
using X_monotone_curve_2 = typename Base::X_monotone_curve_2;
|
||||
using Curve_2 = typename Base::Curve_2;
|
||||
using Multiplicity = typename Base::Multiplicity;
|
||||
|
||||
/// @}
|
||||
|
||||
/// \name Obtain the appropriate functor
|
||||
/// @{
|
||||
|
||||
Compare_x_2 compare_x_2_object() const;
|
||||
Compare_xy_2 compare_xy_2_object() const;
|
||||
Construct_min_vertex_2 construct_min_vertex_2_object() const;
|
||||
Construct_max_vertex_2 construct_max_vertex_2_object() const;
|
||||
Is_vertical_2 is_vertical_2_object() const;
|
||||
Compare_y_at_x_2 compare_y_at_x_2_object() const;
|
||||
Equal_2 equal_2_object() const;
|
||||
Compare_y_at_x_left_2 compare_y_at_x_left_2_object() const;
|
||||
Compare_y_at_x_right_2 compare_y_at_x_right_2_object() const;
|
||||
Make_x_monotone_2 make_x_monotone_2_object() const;
|
||||
Split_2 split_2_object() const;
|
||||
Intersect_2 intersect_2_object() const;
|
||||
Are_mergeable_2 are_mergeable_2_object() const;
|
||||
Merge_2 merge_2_object() const;
|
||||
Construct_opposite_2 construct_opposite_2_object() const;
|
||||
Compare_endpoints_xy_2 compare_endpoints_xy_2_object() const;
|
||||
Approximate_2 approximate_2_object() const;
|
||||
Parameter_space_in_x_2 parameter_space_in_x_2_object() const;
|
||||
Is_on_x_identification_2 is_on_x_identification_2_object() const;
|
||||
Compare_y_on_boundary_2 compare_y_on_boundary_2_object() const;
|
||||
Compare_y_near_boundary_2 compare_y_near_boundary_2_object() const;
|
||||
Parameter_space_in_y_2 parameter_space_in_y_2_object() const;
|
||||
Is_on_y_identification_2 is_on_y_identification_2_object() const;
|
||||
Compare_x_on_boundary_2 compare_x_on_boundary_2_object() const;
|
||||
Compare_x_near_boundary_2 compare_x_near_boundary_2_object() const;
|
||||
|
||||
/// @}
|
||||
};
|
||||
|
||||
template <typename OutputStream>
|
||||
OutputStream& operator<<(OutputStream& os, Comparison_result cr);
|
||||
|
||||
} // namespace CGAL
|
||||
|
|
@ -49,10 +49,10 @@ public:
|
|||
/// \name Creation
|
||||
/// @{
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_unb_planar_topology_traits_2();
|
||||
|
||||
/*! Constructor from a geometry-traits object.
|
||||
/*! constructs from a geometry-traits object.
|
||||
* \param traits the traits.
|
||||
*/
|
||||
Arr_unb_planar_topology_traits_2(const GeometryTraits_2* traits);
|
||||
|
|
@ -62,16 +62,16 @@ public:
|
|||
/// \name Accessors
|
||||
/// @{
|
||||
|
||||
/*! Obtain the DCEL (const version). */
|
||||
/*! obtains the DCEL (const version). */
|
||||
const Dcel& dcel() const;
|
||||
|
||||
/*! Obtain the DCEL (non-const version). */
|
||||
/*! obtains the DCEL (non-const version). */
|
||||
Dcel& dcel();
|
||||
|
||||
/*! Obtain the unbounded face (const version). */
|
||||
/*! obtains the unbounded face (const version). */
|
||||
const Face* unbounded_face() const;
|
||||
|
||||
/*! Obtain the unbounded face (non-const version). */
|
||||
/*! obtains the unbounded face (non-const version). */
|
||||
Face* unbounded_face();
|
||||
|
||||
/// @}
|
||||
|
|
|
|||
|
|
@ -16,8 +16,8 @@ public:
|
|||
/// A model of this concept must provide:
|
||||
/// @{
|
||||
|
||||
/*! obtains an approximation of `p`'s \f$x\f$-coordinate (if `i == 0`), or of
|
||||
* `p`'s \f$y\f$-coordinate (if `i == 1`).
|
||||
/*! obtains an approximation of `p`'s \f$x\f$-coordinate (if `i` == 0), or of
|
||||
* `p`'s \f$y\f$-coordinate (if `i` == 1).
|
||||
*/
|
||||
CGAL::Approximate_number_type operator()(ArrTraits::Point_2 p, int i);
|
||||
|
||||
|
|
|
|||
|
|
@ -38,10 +38,10 @@ public:
|
|||
/// \name Access Functions
|
||||
/// @{
|
||||
|
||||
/*! Obtain the DCEL (const version). */
|
||||
/*! obtains the DCEL (const version). */
|
||||
const Dcel& dcel() const;
|
||||
|
||||
/*! Obtain the DCEL (non-const version). */
|
||||
/*! obtains the DCEL (non-const version). */
|
||||
Dcel& dcel();
|
||||
|
||||
/// @}
|
||||
|
|
|
|||
|
|
@ -29,6 +29,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -29,6 +29,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -33,6 +33,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -29,6 +29,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -29,6 +29,7 @@ public:
|
|||
|
||||
/// \name Functor Types
|
||||
/// @{
|
||||
/// @}
|
||||
|
||||
/// \name Accessing Functor Objects
|
||||
/// @{
|
||||
|
|
|
|||
|
|
@ -198,46 +198,48 @@ implemented as peripheral classes or as free (global) functions.
|
|||
- `CGAL::Arrangement_on_surface_with_history_2<GeometryTraits_2,TopologyTraits>`
|
||||
- `CGAL::Arrangement_2<Traits,Dcel>`
|
||||
- `CGAL::Arrangement_with_history_2<Traits,Dcel>`
|
||||
- `CGAL::Arr_accessor<Arrangement>`
|
||||
- `CGAL::Aos_observer<ArrangementOnSurface_2>`
|
||||
- `CGAL::Arr_observer<Arrangement_2>`
|
||||
- `CGAL::Arrangement_2::Vertex`
|
||||
- `CGAL::Arrangement_2::Halfedge`
|
||||
- `CGAL::Arrangement_2::Face`
|
||||
- `CGAL::Arr_accessor<Arrangement>`
|
||||
- `CGAL::Arr_algebraic_segment_traits_2<Coefficient>`
|
||||
- `CGAL::Arr_Bezier_curve_traits_2<RatKernel,AlgKernel,NtTraits>`
|
||||
- `CGAL::Arr_bounded_planar_topology_traits_2<GeometryTraits_2,Dcel>`
|
||||
- `CGAL::Arr_circle_segment_traits_2<Kernel>`
|
||||
- `CGAL::Arr_circular_arc_traits_2<CircularKernel>`
|
||||
- `CGAL::Arr_circular_line_arc_traits_2<CircularKernel>`
|
||||
- `CGAL::Arr_conic_traits_2<RatKernel,AlgKernel,NtTraits>`
|
||||
- `CGAL::Arr_consolidated_curve_data_traits_2<Traits,Data>`
|
||||
- `CGAL::Arr_counting_traits_2<BaseTraits>`
|
||||
- `CGAL::Arr_curve_data_traits_2<Tr,XData,Mrg,CData,Cnv>`
|
||||
- `CGAL::Arr_dcel_base<V,H,F>`
|
||||
- `CGAL::Arr_dcel<Traits,V,H,F>`
|
||||
- `CGAL::Arr_default_dcel<Traits>`
|
||||
- `CGAL::Arr_face_extended_dcel<Traits,FData,V,H,F>`
|
||||
- `CGAL::Arr_extended_dcel<Traits,VData,HData,FData,V,H,F>`
|
||||
- `CGAL::Arr_segment_traits_2<Kernel>`
|
||||
- `CGAL::Arr_non_caching_segment_traits_2<Kernel>`
|
||||
- `CGAL::Arr_linear_traits_2<Kernel>`
|
||||
- `CGAL::Arr_polyline_traits_2<SegmentTraits>`
|
||||
- `CGAL::Arr_circle_segment_traits_2<Kernel>`
|
||||
- `CGAL::Arr_line_arc_traits_2<CircularKernel>`
|
||||
- `CGAL::Arr_circular_arc_traits_2<CircularKernel>`
|
||||
- `CGAL::Arr_circular_line_arc_traits_2<CircularKernel>`
|
||||
- `CGAL::Arr_conic_traits_2<RatKernel,AlgKernel,NtTraits>`
|
||||
- `CGAL::Arr_rational_function_traits_2<AlgebraicKernel_d_1>`
|
||||
- `CGAL::Arr_Bezier_curve_traits_2<RatKernel,AlgKernel,NtTraits>`
|
||||
- `CGAL::Arr_algebraic_segment_traits_2<Coefficient>`
|
||||
- `CGAL::Arr_geodesic_arc_on_sphere_traits_2<Kernel,x,y>`
|
||||
- `CGAL::Arr_curve_data_traits_2<Tr,XData,Mrg,CData,Cnv>`
|
||||
- `CGAL::Arr_consolidated_curve_data_traits_2<Traits,Data>`
|
||||
- `CGAL::Arr_text_formatter<Arrangement>`
|
||||
- `CGAL::Arr_face_extended_text_formatter<Arrangement>`
|
||||
- `CGAL::Arr_extended_dcel_text_formatter<Arrangement>`
|
||||
- `CGAL::Arr_with_history_text_formatter<ArrFormatter>`
|
||||
- `CGAL::Arr_naive_point_location<Arrangement>`
|
||||
- `CGAL::Arr_walk_along_line_point_location<Arrangement>`
|
||||
- `CGAL::Arr_trapezoid_ric_point_location<Arrangement>`
|
||||
- `CGAL::Arr_landmarks_point_location<Arrangement,Generator>`
|
||||
- `CGAL::Arr_vertex_index_map<Arrangement>`
|
||||
- `CGAL::Arr_face_index_map<Arrangement>`
|
||||
- `CGAL::Arr_extended_dcel<Traits,VData,HData,FData,V,H,F>`
|
||||
- `CGAL::Arr_extended_dcel_text_formatter<Arrangement>`
|
||||
- `CGAL::Arr_face_extended_text_formatter<Arrangement>`
|
||||
- `CGAL::Arr_geodesic_arc_on_sphere_traits_2<Kernel,x,y>`
|
||||
- `CGAL::Arr_landmarks_point_location<Arrangement,Generator>`
|
||||
- `CGAL::Arr_line_arc_traits_2<CircularKernel>`
|
||||
- `CGAL::Arr_linear_traits_2<Kernel>`
|
||||
- `CGAL::Arr_naive_point_location<Arrangement>`
|
||||
- `CGAL::Arr_non_caching_segment_traits_2<Kernel>`
|
||||
- `CGAL::Arr_observer<Arrangement_2>`
|
||||
- `CGAL::Arr_polyline_traits_2<SegmentTraits>`
|
||||
- `CGAL::Arr_point_location_result<Arrangement>`
|
||||
- `CGAL::Arr_bounded_planar_topology_traits_2<GeometryTraits_2,Dcel>`
|
||||
- `CGAL::Arr_unb_planar_topology_traits_2<GeometryTraits_2,Dcel>`
|
||||
- `CGAL::Arr_rational_function_traits_2<AlgebraicKernel_d_1>`
|
||||
- `CGAL::Arr_segment_traits_2<Kernel>`
|
||||
- `CGAL::Arr_spherical_topology_traits_2<GeometryTraits_2,Dcel>`
|
||||
- `CGAL::Arr_text_formatter<Arrangement>`
|
||||
- `CGAL::Arr_tracing_traits_2<BaseTraits>`
|
||||
- `CGAL::Arr_trapezoid_ric_point_location<Arrangement>`
|
||||
- `CGAL::Arr_unb_planar_topology_traits_2<GeometryTraits_2,Dcel>`
|
||||
- `CGAL::Arr_vertex_index_map<Arrangement>`
|
||||
- `CGAL::Arr_walk_along_line_point_location<Arrangement>`
|
||||
- `CGAL::Arr_with_history_text_formatter<ArrFormatter>`
|
||||
- `CGAL::Aos_observer<ArrangementOnSurface_2>`
|
||||
- `CGAL::CORE_algebraic_number_traits`
|
||||
|
||||
\cgalCRPSection{Functions}
|
||||
|
|
|
|||
|
|
@ -12,6 +12,7 @@
|
|||
\example Arrangement_on_surface_2/conics.cpp
|
||||
\example Arrangement_on_surface_2/conic_multiplicities.cpp
|
||||
\example Arrangement_on_surface_2/consolidated_curve_data.cpp
|
||||
\example Arrangement_on_surface_2/count_and_trace.cpp
|
||||
\example Arrangement_on_surface_2/curve_history.cpp
|
||||
\example Arrangement_on_surface_2/dcel_extension.cpp
|
||||
\example Arrangement_on_surface_2/dcel_extension_io.cpp
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
# Created by the script cgal_create_cmake_script
|
||||
# This is the CMake script for compiling a CGAL application.
|
||||
|
||||
cmake_minimum_required(VERSION 3.12...3.29)
|
||||
cmake_minimum_required(VERSION 3.12...3.31)
|
||||
project(Arrangement_on_surface_2_Examples)
|
||||
|
||||
find_package(CGAL REQUIRED COMPONENTS Core OPTIONAL_COMPONENTS Qt6)
|
||||
|
|
|
|||
|
|
@ -0,0 +1,80 @@
|
|||
#include <iostream>
|
||||
|
||||
#include <CGAL/Exact_predicates_exact_constructions_kernel.h>
|
||||
#include <CGAL/Arr_segment_traits_2.h>
|
||||
#include <CGAL/Arr_counting_traits_2.h>
|
||||
#include <CGAL/Arr_tracing_traits_2.h>
|
||||
#include <CGAL/Arr_geodesic_arc_on_sphere_traits_2.h>
|
||||
#include <CGAL/Arr_spherical_topology_traits_2.h>
|
||||
#include <CGAL/Arrangement_on_surface_2.h>
|
||||
#include <CGAL/Arrangement_2.h>
|
||||
#include <CGAL/Cartesian.h>
|
||||
#include <CGAL/CORE_algebraic_number_traits.h>
|
||||
#include <CGAL/Arr_Bezier_curve_traits_2.h>
|
||||
|
||||
#include "arr_print.h"
|
||||
|
||||
using Kernel = CGAL::Exact_predicates_exact_constructions_kernel;
|
||||
|
||||
using Segment_base_traits = CGAL::Arr_segment_traits_2<Kernel>;
|
||||
using Segment_cnt_traits = CGAL::Arr_counting_traits_2<Segment_base_traits>;
|
||||
using Segment_traits = CGAL::Arr_tracing_traits_2<Segment_cnt_traits>;
|
||||
using Segment_arrangement = CGAL::Arrangement_2<Segment_traits>;
|
||||
using Point = Segment_traits::Point_2;
|
||||
using Segment = Segment_traits::Curve_2;
|
||||
|
||||
using Geodesic_base_traits = CGAL::Arr_geodesic_arc_on_sphere_traits_2<Kernel>;
|
||||
using Geodesic_cnt_traits = CGAL::Arr_counting_traits_2<Geodesic_base_traits>;
|
||||
using Geodesic_traits = CGAL::Arr_tracing_traits_2<Geodesic_cnt_traits>;
|
||||
using Topol_traits = CGAL::Arr_spherical_topology_traits_2<Geodesic_traits>;
|
||||
using Geodesic_arrangement =
|
||||
CGAL::Arrangement_on_surface_2<Geodesic_traits, Topol_traits>;
|
||||
using Geodesic_point = Geodesic_traits::Point_2;
|
||||
using Geodesic_curve = Geodesic_traits::Curve_2;
|
||||
|
||||
using Nt_traits = CGAL::CORE_algebraic_number_traits;
|
||||
using NT = Nt_traits::Rational;
|
||||
using Rational = Nt_traits::Rational;
|
||||
using Algebraic = Nt_traits::Algebraic;
|
||||
using Rat_kernel = CGAL::Cartesian<Rational>;
|
||||
using Alg_kernel = CGAL::Cartesian<Algebraic>;
|
||||
using Rat_point = Rat_kernel::Point_2;
|
||||
using Bezier_base_traits =
|
||||
CGAL::Arr_Bezier_curve_traits_2<Rat_kernel, Alg_kernel, Nt_traits>;
|
||||
using Bezier_cnt_traits = CGAL::Arr_counting_traits_2<Bezier_base_traits>;
|
||||
using Bezier_traits = CGAL::Arr_tracing_traits_2<Bezier_cnt_traits>;
|
||||
using Bezier_arrangement = CGAL::Arrangement_2<Bezier_traits>;
|
||||
|
||||
int main() {
|
||||
Segment_traits seg_traits;
|
||||
seg_traits.disable_all_traces();
|
||||
seg_traits.enable_trace(Segment_traits::COMPARE_Y_AT_X_2_OP);
|
||||
Segment_arrangement seg_arr(&seg_traits);
|
||||
std::vector<Point> ps = { Point(0,0), Point(1,0), Point(0,1) };
|
||||
std::vector<Segment> segs =
|
||||
{ Segment(ps[0], ps[1]), Segment(ps[1], ps[2]), Segment(ps[2], ps[0]) };
|
||||
CGAL::insert(seg_arr, segs.begin(), segs.end());
|
||||
std::cout << seg_traits;
|
||||
print_arrangement_size(seg_arr);
|
||||
std::cout << std::endl;
|
||||
|
||||
Geodesic_traits geodesic_traits;
|
||||
geodesic_traits.disable_all_traces();
|
||||
geodesic_traits.enable_trace(Geodesic_traits::COMPARE_XY_2_OP);
|
||||
auto ctr_p = geodesic_traits.construct_point_2_object();
|
||||
auto ctr_cv = geodesic_traits.construct_curve_2_object();
|
||||
std::vector<Geodesic_point> gps =
|
||||
{ ctr_p(-1,0,0), ctr_p(0,-1,0), ctr_p(0,0,-1) };
|
||||
std::vector<Geodesic_curve> gas =
|
||||
{ ctr_cv(gps[0], gps[1]), ctr_cv(gps[1], gps[2]), ctr_cv(gps[2], gps[0]) };
|
||||
Geodesic_arrangement geodesic_arr(&geodesic_traits);
|
||||
CGAL::insert(geodesic_arr, gas.begin(), gas.end());
|
||||
std::cout << geodesic_traits;
|
||||
print_arrangement_size(geodesic_arr);
|
||||
|
||||
Bezier_traits bezier_traits;
|
||||
bezier_traits.disable_all_traces();
|
||||
std::cout << bezier_traits;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
@ -36,13 +36,6 @@ using Trap_pl = CGAL::Arr_trapezoid_ric_point_location<Gm>;
|
|||
using Geom_traits = Gm::Geometry_traits_2;
|
||||
using Point_2 = Geom_traits::Point_2;
|
||||
|
||||
using Point_location_result = CGAL::Arr_point_location_result<Gm>;
|
||||
using Query_result = std::pair<Point_2, Point_location_result::Type>;
|
||||
|
||||
using Vertex_const_handle = Gm::Vertex_const_handle;
|
||||
using Halfedge_const_handle = Gm::Halfedge_const_handle;
|
||||
using Face_const_handle = Gm::Face_const_handle;
|
||||
|
||||
int main() {
|
||||
Gm_polyhedron p;
|
||||
p.make_tetrahedron(Point_3(1.0, 0.0, 0.0), Point_3(0.0, 1.0, 0.0),
|
||||
|
|
@ -50,7 +43,7 @@ int main() {
|
|||
Gm gm;
|
||||
|
||||
Naive_pl naive_pl(gm);
|
||||
// Landmarks_pl landmarks_pl(gm);
|
||||
Landmarks_pl landmarks_pl(gm);
|
||||
Walk_pl walk_pl(gm);
|
||||
// Trap_pl trap_pl(gm);
|
||||
|
||||
|
|
@ -70,30 +63,17 @@ int main() {
|
|||
locate_point(naive_pl, points[1]);
|
||||
locate_point(naive_pl, points[2]);
|
||||
|
||||
// locate_point(walk_pl, points[0]);
|
||||
// locate_point(walk_pl, points[1]);
|
||||
// locate_point(walk_pl, points[2]);
|
||||
|
||||
locate_point(landmarks_pl, points[0]);
|
||||
locate_point(landmarks_pl, points[1]);
|
||||
locate_point(landmarks_pl, points[2]);
|
||||
|
||||
// locate_point(trap_pl, points[0]);
|
||||
|
||||
////////
|
||||
std::list<Query_result> results;
|
||||
// The following cause an assertion failure.
|
||||
// CGAL::locate(gm, &points[0], &points[3], std::back_inserter(results));
|
||||
|
||||
// Print the results.
|
||||
for (auto it = results.begin(); it != results.end(); ++it) {
|
||||
std::cout << "The point (" << it->first << ") is located ";
|
||||
if (const Face_const_handle* f =
|
||||
std::get_if<Face_const_handle>(&(it->second))) // inside a face
|
||||
std::cout << "inside "
|
||||
<< (((*f)->is_unbounded()) ? "the unbounded" : "a bounded")
|
||||
<< " face.\n";
|
||||
else if (const Halfedge_const_handle* e =
|
||||
std::get_if<Halfedge_const_handle>(&(it->second))) // on an edge
|
||||
std::cout << "on an edge: " << (*e)->curve() << std::endl;
|
||||
else if (const Vertex_const_handle* v =
|
||||
std::get_if<Vertex_const_handle>(&(it->second))) // on a vertex
|
||||
std::cout << "on "
|
||||
<< (((*v)->is_isolated()) ? "an isolated" : "a")
|
||||
<< " vertex: " << (*v)->point() << std::endl;
|
||||
}
|
||||
// locate_point(trap_pl, points[1]);
|
||||
// locate_point(trap_pl, points[2]);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ int main() {
|
|||
|
||||
Geom_traits traits;
|
||||
traits.disable_all_traces();
|
||||
traits.enable_trace(Tracing_traits::INTERSECT_OP);
|
||||
traits.enable_trace(Tracing_traits::INTERSECT_2_OP);
|
||||
|
||||
// Construct an arrangement using aggregated insertion:
|
||||
My_arrangement arr1(&traits);
|
||||
|
|
|
|||
|
|
@ -48,27 +48,27 @@ public:
|
|||
private:
|
||||
Arrangement_2* p_arr; // The associated arrangement.
|
||||
|
||||
/*! Copy constructor - not supported. */
|
||||
/*! Copy constructor not supported. */
|
||||
Aos_observer(const Self&);
|
||||
|
||||
/*! Assignment operator - not supported. */
|
||||
/*! Assignment operator not supported. */
|
||||
Self& operator=(const Self&);
|
||||
|
||||
public:
|
||||
/// \name Construction and destruction functions.
|
||||
//@{
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs defaults. */
|
||||
Aos_observer() : p_arr(nullptr) {}
|
||||
|
||||
/*! Constructor with an associated arrangement. */
|
||||
/*! constructs with an associated arrangement. */
|
||||
Aos_observer(Arrangement_2& arr) : p_arr(&arr)
|
||||
{
|
||||
// Register the observer object in the arrangement.
|
||||
p_arr->_register_observer(this);
|
||||
}
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
virtual ~Aos_observer()
|
||||
{
|
||||
// Unregister the observer object from the arrangement.
|
||||
|
|
@ -80,13 +80,13 @@ public:
|
|||
/// \name Modifying the associated arrangement.
|
||||
//@{
|
||||
|
||||
/*! Get the associated arrangement (const version). */
|
||||
/*! obtains the associated arrangement (const version). */
|
||||
const Arrangement_2* arrangement() const { return (p_arr); }
|
||||
|
||||
/*! Get the associated arrangement (non-const version). */
|
||||
/*! obtains the associated arrangement (non-const version). */
|
||||
Arrangement_2* arrangement() { return (p_arr); }
|
||||
|
||||
/*! Attach the observer to an arrangement.
|
||||
/*! attaches the observer to an arrangement.
|
||||
* \pre The observer is not already attached to an arrangement.
|
||||
*/
|
||||
void attach(Arrangement_2& arr)
|
||||
|
|
@ -110,7 +110,7 @@ public:
|
|||
after_attach();
|
||||
}
|
||||
|
||||
/*! Detach the observer from the arrangement. */
|
||||
/*! detaches the observer from the arrangement. */
|
||||
void detach()
|
||||
{
|
||||
if (p_arr == nullptr) return;
|
||||
|
|
@ -564,7 +564,7 @@ public:
|
|||
//@}
|
||||
};
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ public:
|
|||
/// \name Construction.
|
||||
//@{
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_Bezier_curve_traits_2 ()
|
||||
{
|
||||
p_cache = new Bezier_cache;
|
||||
|
|
@ -131,14 +131,14 @@ public:
|
|||
m_owner = true;
|
||||
}
|
||||
|
||||
/*! Copy constructor. */
|
||||
/*! constructs copy. */
|
||||
Arr_Bezier_curve_traits_2 (const Self& tr) :
|
||||
p_cache (tr.p_cache),
|
||||
p_inter_map (tr.p_inter_map),
|
||||
m_owner (false)
|
||||
{}
|
||||
|
||||
/*! Assignment operator. */
|
||||
/*! assigns. */
|
||||
Self& operator= (const Self& tr)
|
||||
{
|
||||
if (this == &tr)
|
||||
|
|
@ -150,7 +150,7 @@ public:
|
|||
return (*this);
|
||||
}
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
~Arr_Bezier_curve_traits_2 ()
|
||||
{
|
||||
if (m_owner)
|
||||
|
|
@ -176,13 +176,12 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Compare_x_2 (const Bezier_cache *cache) :
|
||||
p_cache (cache)
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Compare the x-coordinates of two points.
|
||||
/*! compares the x-coordinates of two points.
|
||||
* \param p1 The first point.
|
||||
* \param p2 The second point.
|
||||
* \return LARGER if x(p1) > x(p2);
|
||||
|
|
@ -196,7 +195,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_x_2 functor object. */
|
||||
/*! obtains a `Compare_x_2` functor object. */
|
||||
Compare_x_2 compare_x_2_object () const
|
||||
{
|
||||
return (Compare_x_2 (p_cache));
|
||||
|
|
@ -212,13 +211,12 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Compare_xy_2 (const Bezier_cache *cache) :
|
||||
p_cache (cache)
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Compares two points lexigoraphically: by x, then by y.
|
||||
/*! compares two points lexigoraphically: by x, then by y.
|
||||
* \param p1 The first point.
|
||||
* \param p2 The second point.
|
||||
* \return LARGER if x(p1) > x(p2), or if x(p1) = x(p2) and y(p1) > y(p2);
|
||||
|
|
@ -232,7 +230,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_xy_2 functor object. */
|
||||
/*! obtains a `Compare_xy_2` functor object. */
|
||||
Compare_xy_2 compare_xy_2_object () const
|
||||
{
|
||||
return (Compare_xy_2 (p_cache));
|
||||
|
|
@ -244,8 +242,7 @@ public:
|
|||
class Construct_min_vertex_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Get the left endpoint of the x-monotone curve (segment).
|
||||
/*! obtains the left endpoint of the x-monotone curve (segment).
|
||||
* \param cv The curve.
|
||||
* \return The left endpoint.
|
||||
*/
|
||||
|
|
@ -255,7 +252,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Construct_min_vertex_2 functor object. */
|
||||
/*! obtains a `Construct_min_vertex_2` functor object. */
|
||||
Construct_min_vertex_2 construct_min_vertex_2_object () const
|
||||
{
|
||||
return Construct_min_vertex_2();
|
||||
|
|
@ -267,8 +264,7 @@ public:
|
|||
class Construct_max_vertex_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Get the right endpoint of the x-monotone curve (segment).
|
||||
/*! obtains the right endpoint of the x-monotone curve (segment).
|
||||
* \param cv The curve.
|
||||
* \return The right endpoint.
|
||||
*/
|
||||
|
|
@ -278,7 +274,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Construct_max_vertex_2 functor object. */
|
||||
/*! obtains a `Construct_max_vertex_2` functor object. */
|
||||
Construct_max_vertex_2 construct_max_vertex_2_object () const
|
||||
{
|
||||
return Construct_max_vertex_2();
|
||||
|
|
@ -290,8 +286,7 @@ public:
|
|||
class Is_vertical_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Check whether the given x-monotone curve is a vertical segment.
|
||||
/*! checks whether the given x-monotone curve is a vertical segment.
|
||||
* \param cv The curve.
|
||||
* \return (true) if the curve is a vertical segment; (false) otherwise.
|
||||
*/
|
||||
|
|
@ -301,7 +296,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get an Is_vertical_2 functor object. */
|
||||
/*! obtains an `Is_vertical_2` functor object. */
|
||||
Is_vertical_2 is_vertical_2_object () const
|
||||
{
|
||||
return Is_vertical_2();
|
||||
|
|
@ -317,13 +312,12 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Compare_y_at_x_2 (const Bezier_cache *cache) :
|
||||
p_cache (cache)
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Return the location of the given point with respect to the input curve.
|
||||
/*! returns the location of the given point with respect to the input curve.
|
||||
* \param cv The curve.
|
||||
* \param p The point.
|
||||
* \pre p is in the x-range of cv.
|
||||
|
|
@ -339,7 +333,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_y_at_x_2 functor object. */
|
||||
/*! obtains a `Compare_y_at_x_2` functor object. */
|
||||
Compare_y_at_x_2 compare_y_at_x_2_object () const
|
||||
{
|
||||
return (Compare_y_at_x_2 (p_cache));
|
||||
|
|
@ -355,13 +349,12 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Compare_y_at_x_left_2 (const Bezier_cache *cache) :
|
||||
p_cache (cache)
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Compares the y value of two x-monotone curves immediately to the left
|
||||
/*! compares the y value of two x-monotone curves immediately to the left
|
||||
* of their intersection point.
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
|
|
@ -380,7 +373,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_y_at_x_left_2 functor object. */
|
||||
/*! obtains a `Compare_y_at_x_left_2` functor object. */
|
||||
Compare_y_at_x_left_2 compare_y_at_x_left_2_object () const
|
||||
{
|
||||
return (Compare_y_at_x_left_2 (p_cache));
|
||||
|
|
@ -396,13 +389,12 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Compare_y_at_x_right_2 (const Bezier_cache *cache) :
|
||||
p_cache (cache)
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Compares the y value of two x-monotone curves immediately to the right
|
||||
/*! compares the y value of two x-monotone curves immediately to the right
|
||||
* of their intersection point.
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
|
|
@ -421,7 +413,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_y_at_x_right_2 functor object. */
|
||||
/*! obtains a `Compare_y_at_x_right_2` functor object. */
|
||||
Compare_y_at_x_right_2 compare_y_at_x_right_2_object () const
|
||||
{
|
||||
return (Compare_y_at_x_right_2 (p_cache));
|
||||
|
|
@ -437,13 +429,12 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Equal_2 (const Bezier_cache *cache) :
|
||||
p_cache (cache)
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Check if the two x-monotone curves are the same (have the same graph).
|
||||
/*! checks if the two x-monotone curves are the same (have the same graph).
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
* \return (true) if the two curves are the same; (false) otherwise.
|
||||
|
|
@ -455,8 +446,7 @@ public:
|
|||
const_cast<Bezier_cache&> (*p_cache)));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check if the two points are the same.
|
||||
/*! checks if the two points are the same.
|
||||
* \param p1 The first point.
|
||||
* \param p2 The second point.
|
||||
* \return (true) if the two point are the same; (false) otherwise.
|
||||
|
|
@ -468,7 +458,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get an Equal_2 functor object. */
|
||||
/*! obtains an `Equal_2` functor object. */
|
||||
Equal_2 equal_2_object () const
|
||||
{
|
||||
return (Equal_2 (p_cache));
|
||||
|
|
@ -486,10 +476,10 @@ public:
|
|||
Bezier_cache* p_cache;
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Make_x_monotone_2(Bezier_cache* cache) : p_cache(cache) {}
|
||||
|
||||
/*! Subdivide a given Bezier curve into x-monotone subcurves and insert them
|
||||
/*! subdivides a given Bezier curve into x-monotone subcurves and insert them
|
||||
* into a given output iterator.
|
||||
* \param cv the curve.
|
||||
* \param oi an output iterator for the result. Its value type is a variant
|
||||
|
|
@ -600,7 +590,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Make_x_monotone_2 functor object. */
|
||||
/*! obtains a `Make_x_monotone_2` functor object. */
|
||||
Make_x_monotone_2 make_x_monotone_2_object() const
|
||||
{ return (Make_x_monotone_2 (p_cache)); }
|
||||
|
||||
|
|
@ -610,8 +600,7 @@ public:
|
|||
class Split_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Split a given x-monotone curve at a given point into two sub-curves.
|
||||
/*! splits a given x-monotone curve at a given point into two sub-curves.
|
||||
* \param cv The curve to split
|
||||
* \param p The split point.
|
||||
* \param c1 Output: The left resulting subcurve (p is its right endpoint).
|
||||
|
|
@ -626,7 +615,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Split_2 functor object. */
|
||||
/*! obtains a `Split_2` functor object. */
|
||||
Split_2 split_2_object () const
|
||||
{
|
||||
return Split_2();
|
||||
|
|
@ -643,14 +632,13 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Intersect_2 (Bezier_cache *cache, Intersection_map *imap) :
|
||||
p_cache (cache),
|
||||
p_imap (imap)
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Find the intersections of the two given curves and insert them to the
|
||||
/*! finds the intersections of the two given curves and insert them to the
|
||||
* given output iterator.
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
|
|
@ -666,7 +654,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get an Intersect_2 functor object. */
|
||||
/*! obtains an `Intersect_2` functor object. */
|
||||
Intersect_2 intersect_2_object () const
|
||||
{
|
||||
return (Intersect_2 (p_cache, p_inter_map));
|
||||
|
|
@ -678,8 +666,7 @@ public:
|
|||
class Are_mergeable_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Check whether it is possible to merge two given x-monotone curves.
|
||||
/*! checks whether it is possible to merge two given x-monotone curves.
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
* \return (true) if the two curves are mergeable - if they are supported
|
||||
|
|
@ -692,7 +679,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get an Are_mergeable_2 functor object. */
|
||||
/*! obtains an `Are_mergeable_2` functor object. */
|
||||
Are_mergeable_2 are_mergeable_2_object () const
|
||||
{
|
||||
return Are_mergeable_2();
|
||||
|
|
@ -709,7 +696,7 @@ public:
|
|||
/*! The traits (in case it has state) */
|
||||
const Traits* m_traits;
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Merge_2(const Traits* traits) : m_traits(traits) {}
|
||||
|
|
@ -718,8 +705,7 @@ public:
|
|||
Nt_traits, Bounding_traits>;
|
||||
|
||||
public:
|
||||
/*!
|
||||
* Merge two given x-monotone curves into a single curve (segment).
|
||||
/*! merges two given x-monotone curves into a single curve (segment).
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
* \param c Output: The merged curve.
|
||||
|
|
@ -736,7 +722,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Merge_2 functor object. */
|
||||
/*! obtains a `Merge_2` functor object. */
|
||||
Merge_2 merge_2_object () const
|
||||
{
|
||||
return Merge_2(this);
|
||||
|
|
@ -752,8 +738,7 @@ public:
|
|||
class Compare_endpoints_xy_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Compare the endpoints of an $x$-monotone curve lexicographically.
|
||||
/*! compares the endpoints of an $x$-monotone curve lexicographically.
|
||||
* (assuming the curve has a designated source and target points).
|
||||
* \param cv The curve.
|
||||
* \return SMALLER if the curve is directed right;
|
||||
|
|
@ -768,7 +753,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_endpoints_xy_2 functor object. */
|
||||
/*! obtains a `Compare_endpoints_xy_2` functor object. */
|
||||
Compare_endpoints_xy_2 compare_endpoints_xy_2_object() const
|
||||
{
|
||||
return Compare_endpoints_xy_2();
|
||||
|
|
@ -781,16 +766,14 @@ public:
|
|||
/*! The traits (in case it has state) */
|
||||
const Traits& m_traits;
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Trim_2(const Traits& traits) : m_traits(traits) {}
|
||||
|
||||
friend class Arr_Bezier_curve_traits_2<Rat_kernel, Alg_kernel,
|
||||
Nt_traits, Bounding_traits>;
|
||||
/*!\brief
|
||||
* Returns a trimmed version of an arc
|
||||
*
|
||||
/*! returns a trimmed version of an arc
|
||||
* \param xcv The arc
|
||||
* \param src the new first endpoint
|
||||
* \param tgt the new second endpoint
|
||||
|
|
@ -824,7 +807,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Obtain a Trim_2 functor object. */
|
||||
/*! obtains a `Trim_2` functor object. */
|
||||
Trim_2 trim_2_object() const { return Trim_2(*this); }
|
||||
|
||||
/*! \class Construct_opposite_2
|
||||
|
|
@ -833,9 +816,7 @@ public:
|
|||
class Construct_opposite_2
|
||||
{
|
||||
public:
|
||||
|
||||
/*!
|
||||
* Construct an opposite x-monotone curve (with swapped source and target).
|
||||
/*! constructs an opposite x-monotone curve (with swapped source and target).
|
||||
* \param cv The curve.
|
||||
* \return The opposite curve.
|
||||
*/
|
||||
|
|
@ -845,7 +826,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Construct_opposite_2 functor object. */
|
||||
/*! obtains a `Construct_opposite_2` functor object. */
|
||||
Construct_opposite_2 construct_opposite_2_object() const
|
||||
{
|
||||
return Construct_opposite_2();
|
||||
|
|
@ -854,7 +835,8 @@ public:
|
|||
//@}
|
||||
};
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -69,30 +69,29 @@ private:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor with an associated arrangement. */
|
||||
/*! constructs from an associated arrangement. */
|
||||
Arr_accessor(Arrangement_2& arr) : p_arr(&arr) {}
|
||||
|
||||
/* Get the arrangement. */
|
||||
/*! obtains the arrangement. */
|
||||
Arrangement_2& arrangement() { return (*p_arr); }
|
||||
|
||||
/* Get the arrangement (const version). */
|
||||
/*! obtains the arrangement (const version). */
|
||||
const Arrangement_2& arrangement() const { return (*p_arr); }
|
||||
|
||||
/// \name Accessing the notification functions (for the global functions).
|
||||
//@{
|
||||
|
||||
/*! Notify that a global operation is about to take place. */
|
||||
/*! notifies that a global operation is about to take place. */
|
||||
void notify_before_global_change() { p_arr->_notify_before_global_change(); }
|
||||
|
||||
/*! Notify that a global operation was completed. */
|
||||
/*! notifies that a global operation was completed. */
|
||||
void notify_after_global_change() { p_arr->_notify_after_global_change(); }
|
||||
//@}
|
||||
|
||||
/// \name Local operations and predicates for the arrangement.
|
||||
//@{
|
||||
|
||||
/*!
|
||||
* Locate the arrangement feature that contains the given curve-end.
|
||||
/*! locates the arrangement feature that contains the given curve-end.
|
||||
* \param cv The curve.
|
||||
* \param ind ARR_MIN_END if we refer to cv's minimal end;
|
||||
* ARR_MAX_END if we refer to its maximal end.
|
||||
|
|
@ -128,8 +127,7 @@ public:
|
|||
return Pl_result::make_result(Vertex_const_handle());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Locate the place for the given curve around the given vertex.
|
||||
/*! locates the place for the given curve around the given vertex.
|
||||
* \param vh A handle for the arrangement vertex.
|
||||
* \param cv The given x-monotone curve.
|
||||
* \pre v is one of cv's endpoints.
|
||||
|
|
@ -162,8 +160,7 @@ public:
|
|||
return (p_arr->_handle_for (he));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Locate the place for the given curve-end around the given vertex,
|
||||
/*! locates the place for the given curve-end around the given vertex,
|
||||
* which lies on the boundary.
|
||||
* \param vh A handle for the arrangement vertex.
|
||||
* \param cv The curve.
|
||||
|
|
@ -177,11 +174,11 @@ public:
|
|||
* vertex (in a clockwise order).
|
||||
*/
|
||||
Halfedge_handle
|
||||
locate_around_boundary_vertex(Vertex_handle vh,
|
||||
const X_monotone_curve_2& cv,
|
||||
Arr_curve_end ind,
|
||||
Arr_parameter_space ps_x,
|
||||
Arr_parameter_space ps_y) const
|
||||
locate_around_boundary_vertex(Vertex_handle vh,
|
||||
const X_monotone_curve_2& cv,
|
||||
Arr_curve_end ind,
|
||||
Arr_parameter_space ps_x,
|
||||
Arr_parameter_space ps_y) const
|
||||
{
|
||||
CGAL_precondition((ps_x != ARR_INTERIOR) || (ps_y != ARR_INTERIOR));
|
||||
|
||||
|
|
@ -193,8 +190,7 @@ public:
|
|||
return (p_arr->_handle_for (he));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Compute the distance (in halfedges) between two halfedges.
|
||||
/*! computes the distance (in halfedges) between two halfedges.
|
||||
* \param e1 A handle for the source halfedge.
|
||||
* \param e2 A handle for the destination halfedge.
|
||||
* \return In case e1 and e2 belong to the same connected component, the
|
||||
|
|
@ -222,8 +218,7 @@ public:
|
|||
return (static_cast<int>(dist));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Determine whether a given query halfedge lies in the interior of a new
|
||||
/*! determines whether a given query halfedge lies in the interior of a new
|
||||
* face we are about to create, by connecting it with another halfedge
|
||||
* using a given x-monotone curve.
|
||||
* \param prev1 A handle for the query halfedge.
|
||||
|
|
@ -244,8 +239,7 @@ public:
|
|||
cv));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check if the given vertex represents one of the ends of a given curve.
|
||||
/*! checks if the given vertex represents one of the ends of a given curve.
|
||||
* \param v The vertex.
|
||||
* \param cv The curve.
|
||||
* \param ind ARR_MIN_END if we refer to cv's minimal end;
|
||||
|
|
@ -262,8 +256,7 @@ public:
|
|||
cv, ind, ps_x, ps_y));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check whether the given halfedge lies on the outer boundary of its
|
||||
/*! checks whether the given halfedge lies on the outer boundary of its
|
||||
* incident face.
|
||||
* \param he The given halfedge.
|
||||
* \return (true) in case he lies on the outer boundary of its incident face;
|
||||
|
|
@ -275,8 +268,7 @@ public:
|
|||
return (! p_he->is_on_inner_ccb());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check whether the given halfedge lies on the inner boundary of its
|
||||
/*! checks whether the given halfedge lies on the inner boundary of its
|
||||
* incident face.
|
||||
* \param he The given halfedge.
|
||||
* \return (true) in case he lies on a hole inside its incident face;
|
||||
|
|
@ -288,8 +280,7 @@ public:
|
|||
return (p_he->is_on_inner_ccb());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Create a new vertex and associate it with the given point.
|
||||
/*! creates a new vertex and associate it with the given point.
|
||||
* \param p The point.
|
||||
* \return A handle for the newly created vertex.
|
||||
*/
|
||||
|
|
@ -300,8 +291,7 @@ public:
|
|||
return (p_arr->_handle_for (v));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Create a new boundary vertex.
|
||||
/*! creates a new boundary vertex.
|
||||
* \param pt the point
|
||||
* \param ps_x The parameter space in x.
|
||||
* \param ps_y The parameter space in y.
|
||||
|
|
@ -328,8 +318,7 @@ public:
|
|||
return (p_arr->_handle_for(v));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Create a new boundary vertex.
|
||||
/*! creates a new boundary vertex.
|
||||
* \param cv The curve incident to the boundary.
|
||||
* \param ind The relevant curve-end.
|
||||
* \param ps_x The parameter space in x.
|
||||
|
|
@ -358,8 +347,7 @@ public:
|
|||
return (p_arr->_handle_for(v));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Locate the arrangement features that will be used for inserting the
|
||||
/*! locates the arrangement features that will be used for inserting the
|
||||
* given curve end, which has a boundary condition, and set a proper vertex
|
||||
* there.
|
||||
* \param f The face that contains the curve end.
|
||||
|
|
@ -388,8 +376,7 @@ public:
|
|||
return (std::make_pair(p_arr->_handle_for(v), p_arr->_handle_for(pred)));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Insert an x-monotone curve into the arrangement, where the end vertices
|
||||
/*! inserts an x-monotone curve into the arrangement, where the end vertices
|
||||
* are given by the target points of two given halfedges.
|
||||
* The two halfedges should be given such that in case a new face is formed,
|
||||
* it will be the incident face of the halfedge directed from the first
|
||||
|
|
@ -426,8 +413,7 @@ public:
|
|||
return (p_arr->_handle_for(he));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Insert an x-monotone curve into the arrangement, such that one of its
|
||||
/*! inserts an x-monotone curve into the arrangement, such that one of its
|
||||
* endpoints corresponds to a given arrangement vertex, given the exact
|
||||
* place for the curve in the circular list around this vertex. The other
|
||||
* endpoint corresponds to a free vertex (a newly created vertex or an
|
||||
|
|
@ -463,8 +449,7 @@ public:
|
|||
return (p_arr->_handle_for (he));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Insert an x-monotone curve into the arrangement, such that both its
|
||||
/*! inserts an x-monotone curve into the arrangement, such that both its
|
||||
* endpoints correspond to free arrangement vertices (newly created vertices
|
||||
* or existing isolated vertices), so a new hole is formed in the face
|
||||
* that contains the two vertices.
|
||||
|
|
@ -511,16 +496,14 @@ public:
|
|||
|
||||
}
|
||||
|
||||
/*!
|
||||
* Insert the given vertex as an isolated vertex inside the given face.
|
||||
/*! inserts the given vertex as an isolated vertex inside the given face.
|
||||
* \param f The face that should contain the isolated vertex.
|
||||
* \param v The isolated vertex.
|
||||
*/
|
||||
void insert_isolated_vertex(Face_handle f, Vertex_handle v)
|
||||
{ p_arr->_insert_isolated_vertex(p_arr->_face (f), p_arr->_vertex(v)); }
|
||||
|
||||
/*!
|
||||
* Relocate all holes and isolated vertices to their proper position,
|
||||
/*! relocates all holes and isolated vertices to their proper position,
|
||||
* immediately after a face has split due to the insertion of a new halfedge.
|
||||
* In case insert_at_vertices_ex() was invoked and indicated that a new face
|
||||
* has been created, this function should be called with the halfedge
|
||||
|
|
@ -539,8 +522,7 @@ public:
|
|||
void relocate_holes_in_new_face(Halfedge_handle new_he)
|
||||
{ p_arr->_relocate_holes_in_new_face(p_arr->_halfedge(new_he)); }
|
||||
|
||||
/*!
|
||||
* Move an outer CCB from one face to another.
|
||||
/*! moves an outer CCB from one face to another.
|
||||
* \param from_face The source face.
|
||||
* \param to_face The destination face.
|
||||
* \param ccb A CCB circulator that corresponds to component to move.
|
||||
|
|
@ -552,8 +534,7 @@ public:
|
|||
p_arr->_halfedge (ccb));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Move an inner CCB from one face to another.
|
||||
/*! moves an inner CCB from one face to another.
|
||||
* \param from_face The source face.
|
||||
* \param to_face The destination face.
|
||||
* \param ccb A CCB circulator that corresponds to component to move.
|
||||
|
|
@ -565,8 +546,7 @@ public:
|
|||
p_arr->_halfedge(ccb));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Move an isolated vertex from one face to another.
|
||||
/*! moves an isolated vertex from one face to another.
|
||||
* \param from_face The source face.
|
||||
* \param to_face The destination face.
|
||||
* \param v The isolated vertex to move.
|
||||
|
|
@ -578,8 +558,7 @@ public:
|
|||
p_arr->_face(to_face), p_arr->_vertex(v));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Remove an isolated vertex from its face.
|
||||
/*! removes an isolated vertex from its face.
|
||||
* \param v The isolated vertex to remove.
|
||||
*/
|
||||
void remove_isolated_vertex_ex (Vertex_handle v)
|
||||
|
|
@ -589,8 +568,7 @@ public:
|
|||
p_arr->_remove_isolated_vertex(iso_v);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Modify the point associated with a given vertex. The point may be
|
||||
/*! modifies the point associated with a given vertex. The point may be
|
||||
* geometrically different than the one currently associated with the vertex.
|
||||
* \param v The vertex to modify.
|
||||
* \param p The new point to associate with v.
|
||||
|
|
@ -602,9 +580,8 @@ public:
|
|||
return v;
|
||||
}
|
||||
|
||||
/*!
|
||||
* Modify the x-monotone curve associated with a given edge. The curve may be
|
||||
* geometrically different than the one currently associated with the edge.
|
||||
/*! modifies the x-monotone curve associated with a given edge. The curve may
|
||||
* be geometrically different than the one currently associated with the edge.
|
||||
* \param e The edge to modify.
|
||||
* \param cv The new x-monotone curve to associate with e.
|
||||
* \return A handle for the modified edge (same as e).
|
||||
|
|
@ -616,8 +593,7 @@ public:
|
|||
return e;
|
||||
}
|
||||
|
||||
/*!
|
||||
* Split a given edge into two at a given point, and associate the given
|
||||
/*! splits a given edge into two at a given point, and associate the given
|
||||
* x-monotone curves with the split edges.
|
||||
* \param e The edge to split (one of the pair of twin halfedges).
|
||||
* \param p The split point.
|
||||
|
|
@ -638,8 +614,7 @@ public:
|
|||
return (p_arr->_handle_for(he));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Split a given edge into two at the given vertex, and associate the given
|
||||
/*! splits a given edge into two at the given vertex, and associate the given
|
||||
* x-monotone curves with the split edges.
|
||||
* \param e The edge to split (one of the pair of twin halfedges).
|
||||
* \param v The split vertex.
|
||||
|
|
@ -661,8 +636,7 @@ public:
|
|||
return (p_arr->_handle_for(he));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Split a fictitious edge at the given vertex.
|
||||
/*! splits a fictitious edge at the given vertex.
|
||||
* \param e The edge to split (one of the pair of twin halfedges).
|
||||
* \param v The split vertex.
|
||||
* \return A handle for the first split halfedge, whose source equals the
|
||||
|
|
@ -677,8 +651,7 @@ public:
|
|||
return (p_arr->_handle_for(he));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Remove a pair of twin halfedges from the arrangement.
|
||||
/*! removes a pair of twin halfedges from the arrangement.
|
||||
* \param e A handle for one of the halfedges to be removed.
|
||||
* \param remove_source Should the source vertex of e be removed if it
|
||||
* becomes isolated (true by default).
|
||||
|
|
@ -698,8 +671,7 @@ public:
|
|||
return (p_arr->_handle_for(f));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check if the two given halfedges lie on the same inner component.
|
||||
/*! checks if the two given halfedges lie on the same inner component.
|
||||
* \param e1 A handle for the first halfedge.
|
||||
* \param e2 A handle for the second halfedge.
|
||||
* \return Whether e1 and e2 lie on the same inner component.
|
||||
|
|
@ -714,8 +686,7 @@ public:
|
|||
return (ic1 == ic2);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check if the two given halfedges lie on the same outer component.
|
||||
/*! checks if the two given halfedges lie on the same outer component.
|
||||
* \param e1 A handle for the first halfedge.
|
||||
* \param e2 A handle for the second halfedge.
|
||||
* \return Whether e1 and e2 lie on the same outer component.
|
||||
|
|
@ -741,7 +712,7 @@ public:
|
|||
typedef typename Arrangement_2::_Is_valid_vertex Is_valid_vertex;
|
||||
typedef typename Arrangement_2::_Valid_vertex_iterator Valid_vertex_iterator;
|
||||
|
||||
/*! Get an iterator for the first valid arrangement vertex. */
|
||||
/*! obtains an iterator for the first valid arrangement vertex. */
|
||||
Valid_vertex_iterator valid_vertices_begin()
|
||||
{
|
||||
return (Valid_vertex_iterator
|
||||
|
|
@ -750,7 +721,7 @@ public:
|
|||
Is_valid_vertex (p_arr->topology_traits())));
|
||||
}
|
||||
|
||||
/*! Get a past-the-end iterator for the valid arrangement vertices. */
|
||||
/*! obtains a past-the-end iterator for the valid arrangement vertices. */
|
||||
Valid_vertex_iterator valid_vertices_end()
|
||||
{
|
||||
return (Valid_vertex_iterator
|
||||
|
|
@ -759,7 +730,7 @@ public:
|
|||
Is_valid_vertex (p_arr->topology_traits())));
|
||||
}
|
||||
|
||||
/*! Get the number of valid arrangement vertices. */
|
||||
/*! obtains the number of valid arrangement vertices. */
|
||||
Size number_of_valid_vertices() const
|
||||
{
|
||||
return (p_arr->topology_traits()->number_of_valid_vertices());
|
||||
|
|
@ -786,13 +757,11 @@ public:
|
|||
typedef DInner_ccb Dcel_inner_ccb;
|
||||
typedef DIso_vertex Dcel_isolated_vertex;
|
||||
|
||||
/*!
|
||||
* Get the arrangement DCEL.
|
||||
/*! obtains the arrangement DCEL.
|
||||
*/
|
||||
const Dcel& dcel() const { return (p_arr->_dcel()); }
|
||||
|
||||
/*!
|
||||
* Clear the entire arrangement.
|
||||
/*! clears the entire arrangement.
|
||||
*/
|
||||
void clear_all()
|
||||
{
|
||||
|
|
@ -800,8 +769,7 @@ public:
|
|||
p_arr->_dcel().delete_all();
|
||||
}
|
||||
|
||||
/*!
|
||||
* Set the boundary of a vertex
|
||||
/*! sets the boundary of a vertex
|
||||
* \param p A vertex
|
||||
* \param ps_x The boundary condition at x.
|
||||
* \param ps_y The boundary condition at y.
|
||||
|
|
@ -816,8 +784,7 @@ public:
|
|||
return (v_to_set);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Create a new vertex.
|
||||
/*! creates a new vertex.
|
||||
* \param p A pointer to the point (may be nullptr in case of a vertex at
|
||||
* infinity).
|
||||
* \param ps_x The boundary condition at x.
|
||||
|
|
@ -842,8 +809,7 @@ public:
|
|||
return (new_v);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Create a new edge (halfedge pair), associated with the given curve.
|
||||
/*! creates a new edge (halfedge pair), associated with the given curve.
|
||||
* \param cv A pointer to the x-monotone curve (may be nullptr in case of
|
||||
* a fictitious edge).
|
||||
* \return A pointer to one of the created DCEL halfedge.
|
||||
|
|
@ -860,34 +826,29 @@ public:
|
|||
return new_he;
|
||||
}
|
||||
|
||||
/*!
|
||||
* Create a new face.
|
||||
/*! creates a new face.
|
||||
* \return A pointer to the created DCEL face.
|
||||
*/
|
||||
Dcel_face* new_face() { return (p_arr->_dcel().new_face()); }
|
||||
|
||||
/*!
|
||||
* Create a new outer CCB.
|
||||
/*! creates a new outer CCB.
|
||||
* \return A pointer to the created DCEL outer CCB.
|
||||
*/
|
||||
Dcel_outer_ccb* new_outer_ccb() { return (p_arr->_dcel().new_outer_ccb()); }
|
||||
|
||||
/*!
|
||||
* Create a new inner CCB.
|
||||
/*! creates a new inner CCB.
|
||||
* \return A pointer to the created DCEL inner CCB.
|
||||
*/
|
||||
Dcel_inner_ccb* new_inner_ccb()
|
||||
{ return (p_arr->_dcel().new_inner_ccb()); }
|
||||
|
||||
/*!
|
||||
* Create a new isolated vertex.
|
||||
/*! creates a new isolated vertex.
|
||||
* \return A pointer to the created DCEL isolated vertex.
|
||||
*/
|
||||
Dcel_isolated_vertex* new_isolated_vertex()
|
||||
{ return (p_arr->_dcel().new_isolated_vertex()); }
|
||||
|
||||
/*!
|
||||
* Remove a range of vertices
|
||||
/*! removes a range of vertices
|
||||
*/
|
||||
template <typename VertexRange>
|
||||
void delete_vertices(const VertexRange& range)
|
||||
|
|
@ -902,8 +863,7 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
/*!
|
||||
* Remove a range of edges
|
||||
/*! removes a range of edges
|
||||
*/
|
||||
template <typename EdgeRange>
|
||||
void delete_edges(const EdgeRange& range)
|
||||
|
|
@ -918,8 +878,7 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
/*!
|
||||
* Remove a range of faces
|
||||
/*! removes a range of faces
|
||||
*/
|
||||
template <typename FaceRange>
|
||||
void delete_faces(const FaceRange& range)
|
||||
|
|
@ -932,8 +891,7 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
/*!
|
||||
* Remove a range of outer ccbs
|
||||
/*! removes a range of outer ccbs
|
||||
*/
|
||||
template <typename CcbRange>
|
||||
void delete_outer_ccbs(const CcbRange& range)
|
||||
|
|
@ -946,8 +904,7 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
/*!
|
||||
* Remove a range of inner ccbs
|
||||
/*! removes a range of inner ccbs
|
||||
*/
|
||||
template <typename CcbRange>
|
||||
void delete_inner_ccbs(const CcbRange& range)
|
||||
|
|
@ -960,14 +917,13 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
/*!
|
||||
* Update the topology traits after the DCEL has been updated.
|
||||
/*! updates the topology traits after the DCEL has been updated.
|
||||
*/
|
||||
void dcel_updated() { p_arr->topology_traits()->dcel_updated(); }
|
||||
//@}
|
||||
|
||||
};
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -33,11 +33,10 @@
|
|||
|
||||
namespace CGAL {
|
||||
|
||||
template< class Coefficient_ >
|
||||
template <class Coefficient_>
|
||||
class Arr_algebraic_segment_traits_2 {
|
||||
|
||||
public:
|
||||
|
||||
enum Site_of_point {
|
||||
POINT_IN_INTERIOR = 0,
|
||||
MIN_ENDPOINT = -1,
|
||||
|
|
@ -57,16 +56,15 @@ public:
|
|||
|
||||
typedef CGAL::Arr_algebraic_segment_traits_2<Coefficient> Self;
|
||||
|
||||
// Default constructor
|
||||
// constructs default
|
||||
Arr_algebraic_segment_traits_2 () {}
|
||||
|
||||
|
||||
// Copy constructor
|
||||
// constructs copy
|
||||
Arr_algebraic_segment_traits_2 (const Self& /* s */) { /* No state...*/}
|
||||
|
||||
// Assignment operator
|
||||
const Self& operator= (const Self& s)
|
||||
{return s;}
|
||||
// assigns
|
||||
const Self& operator= (const Self& s) { return s; }
|
||||
|
||||
// public types
|
||||
|
||||
|
|
@ -613,11 +611,7 @@ public:
|
|||
return Construct_curve_2(&CKvA_2::instance());
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
/*
|
||||
|
||||
// additional functionality (for not introducing a "general" arc)
|
||||
|
||||
|
|
@ -650,12 +644,12 @@ public:
|
|||
|
||||
};
|
||||
|
||||
*/
|
||||
*/
|
||||
|
||||
};
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
#endif // CGAL_ARR_ALGEBRAIC_SEGMENT_TRAITS_H
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -118,26 +118,26 @@ public:
|
|||
///! \name Construction methods.
|
||||
//@{
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_bounded_planar_topology_traits_2() :
|
||||
Base(),
|
||||
unb_face(nullptr)
|
||||
{}
|
||||
|
||||
/*! Constructor from a geometry-traits object. */
|
||||
/*! constructs from a geometry-traits object. */
|
||||
Arr_bounded_planar_topology_traits_2(const Gt2* traits) :
|
||||
Base(traits),
|
||||
unb_face(nullptr)
|
||||
{}
|
||||
|
||||
/*! Assign the contents of another topology-traits class. */
|
||||
/*! assigns the contents of another topology-traits class. */
|
||||
void assign(const Self& other);
|
||||
//@}
|
||||
|
||||
///! \name Accessing the DCEL and constructing iterators.
|
||||
//@{
|
||||
|
||||
/*! Determine whether the DCEL reprsenets an empty structure. */
|
||||
/*! determines whether the DCEL reprsenets an empty structure. */
|
||||
bool is_empty_dcel() const
|
||||
{
|
||||
// An empty bounded arrangement has no edges or vertices.
|
||||
|
|
@ -145,40 +145,40 @@ public:
|
|||
this->m_dcel.size_of_halfedges() == 0);
|
||||
}
|
||||
|
||||
/*! Check if the given vertex is concrete (associated with a point). */
|
||||
/*! checks if the given vertex is concrete (associated with a point). */
|
||||
inline bool is_concrete_vertex(const Vertex*) const { return true; }
|
||||
|
||||
/*! Get the number of concrete vertices. */
|
||||
/*! obtains the number of concrete vertices. */
|
||||
Size number_of_concrete_vertices() const
|
||||
{
|
||||
// All vertices are concrete.
|
||||
return (this->m_dcel.size_of_vertices());
|
||||
}
|
||||
|
||||
/*! Check if the given vertex is valid (not a fictitious one). */
|
||||
/*! checks if the given vertex is valid (not a fictitious one). */
|
||||
inline bool is_valid_vertex(const Vertex*) const { return true; }
|
||||
|
||||
/*! Get the number of valid vertices. */
|
||||
/*! obtains the number of valid vertices. */
|
||||
Size number_of_valid_vertices() const
|
||||
{
|
||||
// All vertices are valid.
|
||||
return (this->m_dcel.size_of_vertices());
|
||||
}
|
||||
|
||||
/*! Check if the given halfedge is valid (not a fictitious one). */
|
||||
/*! checks if the given halfedge is valid (not a fictitious one). */
|
||||
inline bool is_valid_halfedge(const Halfedge*) const { return true; }
|
||||
|
||||
/*! Get the number of valid halfedges. */
|
||||
/*! obtains the number of valid halfedges. */
|
||||
Size number_of_valid_halfedges() const
|
||||
{
|
||||
// All halfedges are valid.
|
||||
return (this->m_dcel.size_of_halfedges());
|
||||
}
|
||||
|
||||
/*! Check if the given face is valid (not a fictitious one). */
|
||||
/*! checks if the given face is valid (not a fictitious one). */
|
||||
inline bool is_valid_face (const Face*) const { return true; }
|
||||
|
||||
/*! Get the number of valid faces. */
|
||||
/*! obtains the number of valid faces. */
|
||||
Size number_of_valid_faces() const
|
||||
{
|
||||
// All faces are valid.
|
||||
|
|
@ -255,15 +255,15 @@ public:
|
|||
///! \name Topology-traits methods.
|
||||
//@{
|
||||
|
||||
/*! Initialize an empty DCEL structure.
|
||||
/*! initializes an empty DCEL structure.
|
||||
*/
|
||||
void init_dcel();
|
||||
|
||||
/*! Make the necessary updates after the DCEL structure have been updated.
|
||||
/*! makes the necessary updates after the DCEL structure have been updated.
|
||||
*/
|
||||
void dcel_updated();
|
||||
|
||||
/*! Check if the given vertex is associated with the given curve end.
|
||||
/*! checks if the given vertex is associated with the given curve end.
|
||||
* \param v The vertex.
|
||||
* \param cv The x-monotone curve.
|
||||
* \param ind The curve end.
|
||||
|
|
@ -295,8 +295,8 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
/*! Given a curve end with boundary conditions and a face that contains the
|
||||
* interior of the curve, find a place for a boundary vertex that will
|
||||
/*! given a curve end with boundary conditions and a face that contains the
|
||||
* interior of the curve, finds a place for a boundary vertex that will
|
||||
* represent the curve end along the face boundary.
|
||||
* \param f The face.
|
||||
* \param cv The x-monotone curve.
|
||||
|
|
@ -318,7 +318,7 @@ public:
|
|||
return std::nullopt;
|
||||
}
|
||||
|
||||
/*! Locate the predecessor halfedge for the given curve around a given
|
||||
/*! locates the predecessor halfedge for the given curve around a given
|
||||
* vertex with boundary conditions.
|
||||
* \param v The vertex.
|
||||
* \param cv The x-monotone curve.
|
||||
|
|
@ -340,7 +340,7 @@ public:
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
/*! Locate a DCEL feature that contains the given curve end.
|
||||
/*! locates a DCEL feature that contains the given curve end.
|
||||
* \param cv The x-monotone curve.
|
||||
* \param ind The curve end.
|
||||
* \param ps_x The boundary condition of the curve end in x.
|
||||
|
|
@ -361,7 +361,7 @@ public:
|
|||
return Result(v);
|
||||
}
|
||||
|
||||
/*! Split a fictitious edge using the given vertex.
|
||||
/*! splits a fictitious edge using the given vertex.
|
||||
* \param e The edge to split (one of the pair of halfedges).
|
||||
* \param v The split vertex.
|
||||
* \pre e is a fictitious halfedge.
|
||||
|
|
@ -375,21 +375,21 @@ public:
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
/*! Determine whether the given face is unbounded.
|
||||
/*! determines whether the given face is unbounded.
|
||||
* \param f The face.
|
||||
* \return Whether f is unbounded.
|
||||
* There is only one unbounded face in the arrangement:
|
||||
*/
|
||||
bool is_unbounded(const Face* f) const { return (f == unb_face); }
|
||||
|
||||
/*! Determine whether the given boundary vertex is redundant.
|
||||
/*! determines whether the given boundary vertex is redundant.
|
||||
* \param v The vertex.
|
||||
* \return Whether v is redundant, and should be erased.
|
||||
* There are no redundant vertices.
|
||||
*/
|
||||
bool is_redundant(const Vertex*) const { return false; }
|
||||
|
||||
/*! Erase the given redundant vertex by merging a fictitious edge.
|
||||
/*! erases the given redundant vertex by merging a fictitious edge.
|
||||
* The function does not free the vertex v itself.
|
||||
* \param v The vertex.
|
||||
* \pre v is a redundant vertex.
|
||||
|
|
@ -402,20 +402,20 @@ public:
|
|||
return nullptr;
|
||||
}
|
||||
|
||||
//! reference_face (const version).
|
||||
/*! The function returns a reference face of the arrangement.
|
||||
All reference faces of arrangements of the same type have a common
|
||||
point.
|
||||
\return A pointer to the reference face.
|
||||
*/
|
||||
//! reference_face (const version).
|
||||
/*! returns a reference face of the arrangement. All reference faces of
|
||||
* arrangements of the same type have a common point.
|
||||
*
|
||||
* \return A pointer to the reference face.
|
||||
*/
|
||||
const Face* reference_face() const { return unbounded_face(); }
|
||||
|
||||
//! reference_face (non-const version).
|
||||
/*! The function returns a reference face of the arrangement.
|
||||
All reference faces of arrangements of the same type have a common
|
||||
point.
|
||||
\return A pointer to the reference face.
|
||||
*/
|
||||
/*! returns a reference face of the arrangement. All reference faces of
|
||||
* arrangements of the same type have a common point.
|
||||
*
|
||||
* \return A pointer to the reference face.
|
||||
*/
|
||||
Face* reference_face() { return unbounded_face(); }
|
||||
|
||||
//@}
|
||||
|
|
@ -426,17 +426,17 @@ public:
|
|||
/*! This function is used by the "walk" point-location strategy. */
|
||||
const Face* initial_face() const { return (unb_face); }
|
||||
|
||||
/*! Get the unbounded face (const version). */
|
||||
/*! obtains the unbounded face (const version). */
|
||||
const Face* unbounded_face() const { return (unb_face); }
|
||||
|
||||
/*! Get the unbounded face (non-const version). */
|
||||
/*! obtains the unbounded face (non-const version). */
|
||||
Face* unbounded_face() { return (unb_face); }
|
||||
//@}
|
||||
|
||||
/// \name Additional predicates, specialized for this topology-traits class.
|
||||
//@{
|
||||
|
||||
/*! Compare the given vertex and the given point.
|
||||
/*! compares the given vertex and the given point.
|
||||
* \param p The point.
|
||||
* \param v The vertex.
|
||||
* \return The result of the comparison of the x-coordinates of p and v.
|
||||
|
|
@ -444,7 +444,7 @@ public:
|
|||
virtual Comparison_result compare_x(const Point_2& p, const Vertex* v) const
|
||||
{ return (this->m_geom_traits->compare_x_2_object()(p, v->point())); }
|
||||
|
||||
/*! Compare the given vertex and the given point.
|
||||
/*! compares the given vertex and the given point.
|
||||
* \param p The point.
|
||||
* \param v The vertex.
|
||||
* \return The result of the xy-lexicographic comparison of p and v.
|
||||
|
|
@ -452,7 +452,7 @@ public:
|
|||
virtual Comparison_result compare_xy(const Point_2& p, const Vertex* v) const
|
||||
{ return (this->m_geom_traits->compare_xy_2_object()(p, v->point())); }
|
||||
|
||||
/*! Compare the relative y-position of the given point and the given edge
|
||||
/*! compares the relative y-position of the given point and the given edge
|
||||
* (which may be fictitious).
|
||||
* \param p The point.
|
||||
* \param he The edge (one of the pair of halfedges).
|
||||
|
|
|
|||
|
|
@ -72,12 +72,12 @@ protected:
|
|||
bool m_use_cache;
|
||||
|
||||
public:
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_circle_segment_traits_2 (bool use_intersection_caching = false) :
|
||||
m_use_cache(use_intersection_caching)
|
||||
{}
|
||||
|
||||
/*! Get the next curve index. */
|
||||
/*! obtains the next curve index. */
|
||||
static unsigned int get_index ()
|
||||
{
|
||||
#ifdef CGAL_NO_ATOMIC
|
||||
|
|
@ -94,8 +94,7 @@ public:
|
|||
class Compare_x_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Compare the x-coordinates of two points.
|
||||
/*! compares the \f$x\f$-coordinates of two points.
|
||||
* \param p1 The first point.
|
||||
* \param p2 The second point.
|
||||
* \return LARGER if x(p1) > x(p2);
|
||||
|
|
@ -111,7 +110,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_x_2 functor object. */
|
||||
/*! obtains a `Compare_x_2` functor object. */
|
||||
Compare_x_2 compare_x_2_object () const
|
||||
{
|
||||
return Compare_x_2();
|
||||
|
|
@ -120,8 +119,7 @@ public:
|
|||
class Compare_xy_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Compares two points lexigoraphically: by x, then by y.
|
||||
/*! compares two points lexigoraphically: by x, then by y.
|
||||
* \param p1 The first point.
|
||||
* \param p2 The second point.
|
||||
* \return LARGER if x(p1) > x(p2), or if x(p1) = x(p2) and y(p1) > y(p2);
|
||||
|
|
@ -142,7 +140,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_xy_2 functor object. */
|
||||
/*! obtains a Compare_xy_2 functor object. */
|
||||
Compare_xy_2 compare_xy_2_object () const
|
||||
{
|
||||
return Compare_xy_2();
|
||||
|
|
@ -151,8 +149,7 @@ public:
|
|||
class Construct_min_vertex_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Get the left endpoint of the x-monotone curve (segment).
|
||||
/*! obtains the left endpoint of the \f$x\f$-monotone curve (segment).
|
||||
* \param cv The curve.
|
||||
* \return The left endpoint.
|
||||
*/
|
||||
|
|
@ -162,7 +159,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Construct_min_vertex_2 functor object. */
|
||||
/*! obtains a `Construct_min_vertex_2` functor object. */
|
||||
Construct_min_vertex_2 construct_min_vertex_2_object () const
|
||||
{
|
||||
return Construct_min_vertex_2();
|
||||
|
|
@ -171,8 +168,7 @@ public:
|
|||
class Construct_max_vertex_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Get the right endpoint of the x-monotone curve (segment).
|
||||
/*! obtains the right endpoint of the \f$x\f$-monotone curve (segment).
|
||||
* \param cv The curve.
|
||||
* \return The right endpoint.
|
||||
*/
|
||||
|
|
@ -182,7 +178,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Construct_max_vertex_2 functor object. */
|
||||
/*! obtains a Construct_max_vertex_2 functor object. */
|
||||
Construct_max_vertex_2 construct_max_vertex_2_object () const
|
||||
{
|
||||
return Construct_max_vertex_2();
|
||||
|
|
@ -191,8 +187,7 @@ public:
|
|||
class Is_vertical_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Check whether the given x-monotone curve is a vertical segment.
|
||||
/*! checks whether the given \f$x\f$-monotone curve is a vertical segment.
|
||||
* \param cv The curve.
|
||||
* \return (true) if the curve is a vertical segment; (false) otherwise.
|
||||
*/
|
||||
|
|
@ -202,7 +197,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get an Is_vertical_2 functor object. */
|
||||
/*! obtains an `Is_vertical_2` functor object. */
|
||||
Is_vertical_2 is_vertical_2_object () const
|
||||
{
|
||||
return Is_vertical_2();
|
||||
|
|
@ -211,11 +206,10 @@ public:
|
|||
class Compare_y_at_x_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Return the location of the given point with respect to the input curve.
|
||||
/*! returns the location of the given point with respect to the input curve.
|
||||
* \param cv The curve.
|
||||
* \param p The point.
|
||||
* \pre p is in the x-range of cv.
|
||||
* \pre p is in the \f$x\f$-range of `cv`.
|
||||
* \return SMALLER if y(p) < cv(x(p)), i.e. the point is below the curve;
|
||||
* LARGER if y(p) > cv(x(p)), i.e. the point is above the curve;
|
||||
* EQUAL if p lies on the curve.
|
||||
|
|
@ -229,7 +223,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_y_at_x_2 functor object. */
|
||||
/*! obtains a `Compare_y_at_x_2` functor object. */
|
||||
Compare_y_at_x_2 compare_y_at_x_2_object () const
|
||||
{
|
||||
return Compare_y_at_x_2();
|
||||
|
|
@ -238,9 +232,8 @@ public:
|
|||
class Compare_y_at_x_right_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Compares the y value of two x-monotone curves immediately to the right
|
||||
* of their intersection point.
|
||||
/*! compares the y value of two \f$x\f$-monotone curves immediately to the
|
||||
* right of their intersection point.
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
* \param p The intersection point.
|
||||
|
|
@ -283,7 +276,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_y_at_x_right_2 functor object. */
|
||||
/*! obtains a `Compare_y_at_x_right_2` functor object. */
|
||||
Compare_y_at_x_right_2 compare_y_at_x_right_2_object () const
|
||||
{
|
||||
return Compare_y_at_x_right_2();
|
||||
|
|
@ -292,16 +285,15 @@ public:
|
|||
class Compare_y_at_x_left_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Compares the y value of two x-monotone curves immediately to the left
|
||||
* of their intersection point.
|
||||
/*! compares the \f$y\f$-value of two \f$x\f$-monotone curves immediately to
|
||||
* the left of their intersection point.
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
* \param p The intersection point.
|
||||
* \pre The point p lies on both curves, and both of them must be also be
|
||||
* \pre The point `p` lies on both curves, and both of them must be also be
|
||||
* defined (lexicographically) to its left.
|
||||
* \return The relative position of cv1 with respect to cv2 immdiately to
|
||||
* the left of p: SMALLER, LARGER or EQUAL.
|
||||
* \return The relative position of `cv1` with respect to `cv2` immdiately
|
||||
* to the left of `p`: `SMALLER`, `LARGER`, or `EQUAL`.
|
||||
*/
|
||||
Comparison_result operator() (const X_monotone_curve_2& cv1,
|
||||
const X_monotone_curve_2& cv2,
|
||||
|
|
@ -338,7 +330,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_y_at_x_left_2 functor object. */
|
||||
/*! obtains a `Compare_y_at_x_left_2` functor object. */
|
||||
Compare_y_at_x_left_2 compare_y_at_x_left_2_object () const
|
||||
{
|
||||
return Compare_y_at_x_left_2();
|
||||
|
|
@ -347,8 +339,8 @@ public:
|
|||
class Equal_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Check if the two x-monotone curves are the same (have the same graph).
|
||||
/*! checks if the two \f$x\f$-monotone curves are the same (have the same
|
||||
* graph).
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
* \return (true) if the two curves are the same; (false) otherwise.
|
||||
|
|
@ -362,8 +354,7 @@ public:
|
|||
return (cv1.equals (cv2));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check if the two points are the same.
|
||||
/*! checks if the two points are the same.
|
||||
* \param p1 The first point.
|
||||
* \param p2 The second point.
|
||||
* \return (true) if the two point are the same; (false) otherwise.
|
||||
|
|
@ -374,7 +365,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get an Equal_2 functor object. */
|
||||
/*! obtains an `Equal_2` functor object. */
|
||||
Equal_2 equal_2_object () const
|
||||
{
|
||||
return Equal_2();
|
||||
|
|
@ -395,7 +386,7 @@ public:
|
|||
/*! The traits (in case it has state) */
|
||||
const Traits& m_traits;
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits.
|
||||
*/
|
||||
Approximate_2(const Traits& traits) : m_traits(traits) {}
|
||||
|
|
@ -403,24 +394,24 @@ public:
|
|||
friend class Arr_circle_segment_traits_2<Kernel, Filter>;
|
||||
|
||||
public:
|
||||
/*! Obtain an approximation of a point coordinate.
|
||||
/*! obtains an approximation of a point coordinate.
|
||||
* \param p the exact point.
|
||||
* \param i the coordinate index (either 0 or 1).
|
||||
* \pre i is either 0 or 1.
|
||||
* \return An approximation of p's x-coordinate (if i == 0), or an
|
||||
* approximation of p's y-coordinate (if i == 1).
|
||||
* \pre `i` is either 0 or 1.
|
||||
* \return An approximation of `p`'s \f$x\f$-coordinate (if `i` == 0), or an
|
||||
* approximation of `p`'s \f$y\f$-coordinate (if `i` == 1).
|
||||
*/
|
||||
Approximate_number_type operator()(const Point_2& p, int i) const {
|
||||
CGAL_precondition((i == 0) || (i == 1));
|
||||
return (i == 0) ? (CGAL::to_double(p.x())) : (CGAL::to_double(p.y()));
|
||||
}
|
||||
|
||||
/*! Obtain an approximation of a point.
|
||||
/*! obtains an approximation of a point.
|
||||
*/
|
||||
Approximate_point_2 operator()(const Point_2& p) const
|
||||
{ return Approximate_point_2(operator()(p, 0), operator()(p, 1)); }
|
||||
|
||||
/*! Obtain an approximation of an \f$x\f$-monotone curve.
|
||||
/*! obtains an approximation of an \f$x\f$-monotone curve.
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator operator()(const X_monotone_curve_2& xcv, double error,
|
||||
|
|
@ -430,7 +421,7 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
/*! Handle segments.
|
||||
/*! handles segments.
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator approximate_segment(const X_monotone_curve_2& xcv,
|
||||
|
|
@ -477,7 +468,7 @@ public:
|
|||
return oi;
|
||||
}
|
||||
|
||||
/*! Compute the circular point given the parameter t and the transform
|
||||
/*! computes the circular point given the parameter t and the transform
|
||||
* data, that is, the center (translation) and the sin and cos of the
|
||||
* rotation angle.
|
||||
*/
|
||||
|
|
@ -486,7 +477,7 @@ public:
|
|||
y = r * std::sin(t);
|
||||
}
|
||||
|
||||
/*! Transform a point. In particular, rotate the canonical point
|
||||
/*! transforms a point. In particular, rotate the canonical point
|
||||
* (`xc`,`yc`) by an angle, the sine and cosine of which are `sint` and
|
||||
* `cost`, respectively, and translate by (`cx`,`cy`).
|
||||
*/
|
||||
|
|
@ -496,7 +487,7 @@ public:
|
|||
y = yc + cy;
|
||||
}
|
||||
|
||||
/*! Handle circular arcs.
|
||||
/*! handles circular arcs.
|
||||
*/
|
||||
template <typename OutputIterator>
|
||||
OutputIterator approximate_arc(const X_monotone_curve_2& xcv,
|
||||
|
|
@ -554,7 +545,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Obtain an Approximate_2 functor object. */
|
||||
/*! obtains an `Approximate_2` functor object. */
|
||||
Approximate_2 approximate_2_object() const { return Approximate_2(*this); }
|
||||
//@}
|
||||
|
||||
|
|
@ -562,7 +553,7 @@ public:
|
|||
//@{
|
||||
|
||||
/*! \class
|
||||
* A functor for subdividing a curve into x-monotone curves.
|
||||
* A functor for subdividing a curve into \f$x\f$-monotone curves.
|
||||
*/
|
||||
class Make_x_monotone_2 {
|
||||
private:
|
||||
|
|
@ -573,8 +564,8 @@ public:
|
|||
public:
|
||||
Make_x_monotone_2(bool use_cache = false) : m_use_cache(use_cache) {}
|
||||
|
||||
/*! Subdivide a given circular arc or line segment into x-monotone subcurves
|
||||
* and insert them to a given output iterator.
|
||||
/*! subdivides a given circular arc or line segment into \f$x\f$-monotone
|
||||
* subcurves and insert them to a given output iterator.
|
||||
* \param cv the curve.
|
||||
* \param oi the output iterator for the result. Its dereference type is a
|
||||
* variant that wraps a \c Point_2 or an \c X_monotone_curve_2
|
||||
|
|
@ -632,7 +623,7 @@ public:
|
|||
else {
|
||||
// Act according to the number of vertical tangency points.
|
||||
if (n_vpts == 2) {
|
||||
// Subdivide the circular arc into three x-monotone arcs.
|
||||
// Subdivide the circular arc into three \f$x\f$-monotone arcs.
|
||||
*oi++ = X_monotone_curve_2(circ,
|
||||
cv.source(), vpts[0],
|
||||
cv.orientation(),
|
||||
|
|
@ -650,7 +641,7 @@ public:
|
|||
index);
|
||||
}
|
||||
else if (n_vpts == 1) {
|
||||
// Subdivide the circular arc into two x-monotone arcs.
|
||||
// Subdivide the circular arc into two \f$x\f$-monotone arcs.
|
||||
*oi++ = X_monotone_curve_2(circ,
|
||||
cv.source(),
|
||||
vpts[0],
|
||||
|
|
@ -666,7 +657,7 @@ public:
|
|||
else {
|
||||
CGAL_assertion(n_vpts == 0);
|
||||
|
||||
// The arc is already x-monotone:
|
||||
// The arc is already \f$x\f$-monotone:
|
||||
*oi++ = X_monotone_curve_2(circ,
|
||||
cv.source(),
|
||||
cv.target(),
|
||||
|
|
@ -679,7 +670,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Make_x_monotone_2 functor object. */
|
||||
/*! obtains a `Make_x_monotone_2` functor object. */
|
||||
Make_x_monotone_2 make_x_monotone_2_object() const
|
||||
{ return Make_x_monotone_2(m_use_cache); }
|
||||
|
||||
|
|
@ -687,13 +678,13 @@ public:
|
|||
{
|
||||
public:
|
||||
|
||||
/*!
|
||||
* Split a given x-monotone curve at a given point into two sub-curves.
|
||||
/*! splits a given \f$x\f$-monotone curve at a given point into two
|
||||
* sub-curves.
|
||||
* \param cv The curve to split
|
||||
* \param p The split point.
|
||||
* \param c1 Output: The left resulting subcurve (p is its right endpoint).
|
||||
* \param c2 Output: The right resulting subcurve (p is its left endpoint).
|
||||
* \pre p lies on cv but is not one of its end-points.
|
||||
* \param c1 Output: The left resulting subcurve (`p` is its right endpoint).
|
||||
* \param c2 Output: The right resulting subcurve (`p` is its left endpoint).
|
||||
* \pre `p` lies on cv but is not one of its end-points.
|
||||
*/
|
||||
void operator() (const X_monotone_curve_2& cv, const Point_2& p,
|
||||
X_monotone_curve_2& c1, X_monotone_curve_2& c2) const
|
||||
|
|
@ -707,7 +698,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Split_2 functor object. */
|
||||
/*! obtains a `Split_2` functor object. */
|
||||
Split_2 split_2_object () const
|
||||
{
|
||||
return Split_2();
|
||||
|
|
@ -718,10 +709,10 @@ public:
|
|||
Intersection_map& _inter_map; // The map of intersection points.
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Intersect_2(Intersection_map& map) : _inter_map(map) {}
|
||||
|
||||
/*! Find the intersections of the two given curves and insert them to the
|
||||
/*! finds the intersections of the two given curves and insert them to the
|
||||
* given output iterator. As two segments may itersect only once, only a
|
||||
* single will be contained in the iterator.
|
||||
* \param cv1 The first curve.
|
||||
|
|
@ -736,18 +727,18 @@ public:
|
|||
{ return (cv1.intersect(cv2, oi, &_inter_map)); }
|
||||
};
|
||||
|
||||
/*! Get an Intersect_2 functor object. */
|
||||
/*! obtains an `Intersect_2` functor object. */
|
||||
Intersect_2 intersect_2_object() const { return (Intersect_2(inter_map)); }
|
||||
|
||||
class Are_mergeable_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* Check whether it is possible to merge two given x-monotone curves.
|
||||
/*! checks whether it is possible to merge two given \f$x\f$-monotone curves.
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
* \return (true) if the two curves are mergeable - if they are supported
|
||||
* by the same line and share a common endpoint; (false) otherwise.
|
||||
* \return (true) if `cv1` and `cv2` are mergeable, that is, if they are
|
||||
* supported by the same line and share a common endpoint; (false)
|
||||
* otherwise.
|
||||
*/
|
||||
bool operator() (const X_monotone_curve_2& cv1,
|
||||
const X_monotone_curve_2& cv2) const
|
||||
|
|
@ -756,14 +747,14 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get an Are_mergeable_2 functor object. */
|
||||
/*! obtains an `Are_mergeable_2` functor object. */
|
||||
Are_mergeable_2 are_mergeable_2_object () const
|
||||
{
|
||||
return Are_mergeable_2();
|
||||
}
|
||||
|
||||
/*! \class Merge_2
|
||||
* A functor that merges two x-monotone arcs into one.
|
||||
* A functor that merges two \f$x\f$-monotone arcs into one.
|
||||
*/
|
||||
class Merge_2
|
||||
{
|
||||
|
|
@ -773,7 +764,7 @@ public:
|
|||
/*! The traits (in case it has state) */
|
||||
const Traits* m_traits;
|
||||
|
||||
/*! Constructor
|
||||
/*! Constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Merge_2(const Traits* traits) : m_traits(traits) {}
|
||||
|
|
@ -781,8 +772,7 @@ public:
|
|||
friend class Arr_circle_segment_traits_2<Kernel, Filter>;
|
||||
|
||||
public:
|
||||
/*!
|
||||
* Merge two given x-monotone curves into a single curve.
|
||||
/*! merges two given \f$x\f$-monotone curves into a single curve.
|
||||
* \param cv1 The first curve.
|
||||
* \param cv2 The second curve.
|
||||
* \param c Output: The merged curve.
|
||||
|
|
@ -799,7 +789,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Merge_2 functor object. */
|
||||
/*! obtains a `Merge_2` functor object. */
|
||||
Merge_2 merge_2_object () const
|
||||
{
|
||||
return Merge_2(this);
|
||||
|
|
@ -808,10 +798,9 @@ public:
|
|||
class Compare_endpoints_xy_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* compare lexicogrphic the endpoints of a x-monotone curve.
|
||||
/*! compares lexicogrphic the endpoints of a \f$x\f$-monotone curve.
|
||||
* \param cv the curve
|
||||
* \return SMALLER if the curve is directed right, else return SMALLER
|
||||
* \return `SMALLER` if the curve is directed right, else return `LARGER`.
|
||||
*/
|
||||
Comparison_result operator()(const X_monotone_curve_2& cv) const
|
||||
{
|
||||
|
|
@ -821,7 +810,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Compare_endpoints_xy_2 functor object. */
|
||||
/*! obtains a `Compare_endpoints_xy_2` functor object. */
|
||||
Compare_endpoints_xy_2 compare_endpoints_xy_2_object() const
|
||||
{
|
||||
return Compare_endpoints_xy_2();
|
||||
|
|
@ -830,10 +819,9 @@ public:
|
|||
class Construct_opposite_2
|
||||
{
|
||||
public:
|
||||
/*!
|
||||
* construct an opposite x-monotone curve.
|
||||
/*! constructs an opposite \f$x\f$-monotone curve.
|
||||
* \param cv the curve
|
||||
* \return an opposite x-monotone curve.
|
||||
* \return an opposite \f$x\f$-monotone curve.
|
||||
*/
|
||||
X_monotone_curve_2 operator()(const X_monotone_curve_2& cv) const
|
||||
{
|
||||
|
|
@ -841,7 +829,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get a Construct_opposite_2 functor object. */
|
||||
/*! obtains a `Construct_opposite_2` functor object. */
|
||||
Construct_opposite_2 construct_opposite_2_object() const
|
||||
{
|
||||
return Construct_opposite_2();
|
||||
|
|
@ -854,7 +842,7 @@ public:
|
|||
/*! The traits (in case it has state) */
|
||||
const Traits& m_traits;
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Trim_2(const Traits& traits) : m_traits(traits) {}
|
||||
|
|
@ -862,7 +850,7 @@ public:
|
|||
friend class Arr_circle_segment_traits_2<Kernel, Filter>;
|
||||
|
||||
public:
|
||||
/*! Obtain a trimmed version of an arc
|
||||
/*! obtains a trimmed version of an arc
|
||||
* \param xcv The arc
|
||||
* \param src the new first endpoint
|
||||
* \param tgt the new second endpoint
|
||||
|
|
@ -893,14 +881,14 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Obtain a Trim_2 functor object. */
|
||||
/*! obtains a `Trim_2` functor object. */
|
||||
Trim_2 trim_2_object() const { return Trim_2(*this); }
|
||||
|
||||
// @}
|
||||
|
||||
};
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -206,4 +206,4 @@ public:
|
|||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
#endif // CGAL_CIRCULAR_KERNEL_CIRCULAR_ARC_TRAITS_H
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -380,8 +380,7 @@ namespace CGAL {
|
|||
typedef typename CircularKernel::Circular_arc_point_2
|
||||
Circular_arc_point_2;
|
||||
|
||||
public :
|
||||
|
||||
public:
|
||||
typedef Circular_arc_point_2 result_type;
|
||||
//typedef const result_type& qualified_result_type;
|
||||
|
||||
|
|
@ -395,14 +394,13 @@ namespace CGAL {
|
|||
}
|
||||
};
|
||||
|
||||
|
||||
template <class CircularKernel, class Arc1, class Arc2>
|
||||
class Construct_max_vertex_2//: public Has_qrt
|
||||
{
|
||||
typedef typename CircularKernel::Circular_arc_point_2 Point_2;
|
||||
|
||||
public:
|
||||
/*!
|
||||
* Get the right endpoint of the x-monotone curve (segment).
|
||||
/*! obtains the right endpoint of the x-monotone curve (segment).
|
||||
* \param cv The curve.
|
||||
* \return The right endpoint.
|
||||
*/
|
||||
|
|
@ -418,10 +416,10 @@ namespace CGAL {
|
|||
}
|
||||
};
|
||||
|
||||
template <class CircularKernel>
|
||||
template <class CircularKernel>
|
||||
class Variant_Is_vertical_2
|
||||
{
|
||||
public :
|
||||
public:
|
||||
|
||||
template < typename T >
|
||||
bool
|
||||
|
|
@ -449,7 +447,7 @@ namespace CGAL {
|
|||
|
||||
// an empty class used to have different types between Curve_2 and X_monotone_curve_2
|
||||
// in Arr_circular_line_arc_traits_2.
|
||||
namespace internal_Argt_traits{
|
||||
namespace internal_Argt_traits {
|
||||
struct Not_X_Monotone{};
|
||||
inline std::ostream& operator << (std::ostream& os, const Not_X_Monotone&)
|
||||
{return os;}
|
||||
|
|
@ -520,45 +518,42 @@ namespace CGAL {
|
|||
typedef VariantFunctors::Intersect_2<CircularKernel, Arc1, Arc2>
|
||||
Intersect_2;
|
||||
|
||||
Compare_x_2 compare_x_2_object() const
|
||||
{ return ck.compare_x_2_object(); }
|
||||
|
||||
Compare_x_2 compare_x_2_object() const
|
||||
{ return ck.compare_x_2_object(); }
|
||||
Compare_xy_2 compare_xy_2_object() const
|
||||
{ return ck.compare_xy_2_object(); }
|
||||
|
||||
Compare_xy_2 compare_xy_2_object() const
|
||||
{ return ck.compare_xy_2_object(); }
|
||||
Compare_y_at_x_2 compare_y_at_x_2_object() const
|
||||
{ return Compare_y_at_x_2(); }
|
||||
|
||||
Compare_y_at_x_2 compare_y_at_x_2_object() const
|
||||
{ return Compare_y_at_x_2(); }
|
||||
Compare_y_at_x_right_2 compare_y_at_x_right_2_object() const
|
||||
{ return Compare_y_at_x_right_2(); }
|
||||
|
||||
Compare_y_at_x_right_2 compare_y_at_x_right_2_object() const
|
||||
{ return Compare_y_at_x_right_2(); }
|
||||
Equal_2 equal_2_object() const
|
||||
{ return Equal_2(); }
|
||||
|
||||
Equal_2 equal_2_object() const
|
||||
{ return Equal_2(); }
|
||||
Make_x_monotone_2 make_x_monotone_2_object() const
|
||||
{ return Make_x_monotone_2(); }
|
||||
|
||||
Make_x_monotone_2 make_x_monotone_2_object() const
|
||||
{ return Make_x_monotone_2(); }
|
||||
Split_2 split_2_object() const
|
||||
{ return Split_2(); }
|
||||
|
||||
Split_2 split_2_object() const
|
||||
{ return Split_2(); }
|
||||
|
||||
Intersect_2 intersect_2_object() const
|
||||
Intersect_2 intersect_2_object() const
|
||||
{ return Intersect_2(); }
|
||||
|
||||
Construct_min_vertex_2 construct_min_vertex_2_object() const
|
||||
Construct_min_vertex_2 construct_min_vertex_2_object() const
|
||||
{ return Construct_min_vertex_2(); }
|
||||
|
||||
Construct_max_vertex_2 construct_max_vertex_2_object() const
|
||||
Construct_max_vertex_2 construct_max_vertex_2_object() const
|
||||
{ return Construct_max_vertex_2(); }
|
||||
|
||||
Is_vertical_2 is_vertical_2_object() const
|
||||
Is_vertical_2 is_vertical_2_object() const
|
||||
{ return Is_vertical_2();}
|
||||
|
||||
|
||||
};
|
||||
|
||||
} // namespace CGAL
|
||||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
#endif // CGAL_CIRCULAR_KERNEL_VARIANT_TRAITS_H
|
||||
#endif
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -92,10 +92,10 @@ public:
|
|||
/// \name Construction.
|
||||
//@{
|
||||
|
||||
/*! Construct default. */
|
||||
/*! constructs default. */
|
||||
Arr_curve_data_traits_2() {}
|
||||
|
||||
/*! Construct from a base-traits class. */
|
||||
/*! constructs from a base-traits class. */
|
||||
Arr_curve_data_traits_2(const Base_traits_2& traits) : Base_traits_2(traits) {}
|
||||
//@}
|
||||
|
||||
|
|
@ -113,10 +113,10 @@ public:
|
|||
const Base_traits_2& m_base;
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Make_x_monotone_2(const Base_traits_2& base) : m_base(base) {}
|
||||
|
||||
/*! Subdivide a given curve into x-monotone subcurves and insert them into
|
||||
/*! subdivides a given curve into x-monotone subcurves and insert them into
|
||||
* a given output iterator.
|
||||
* \param cv the curve.
|
||||
* \param oi the output iterator for the result. Its value type is a variant
|
||||
|
|
@ -152,7 +152,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Obtain a Make_x_monotone_2 functor object. */
|
||||
/*! obtains a Make_x_monotone_2 functor object. */
|
||||
Make_x_monotone_2 make_x_monotone_2_object() const
|
||||
{ return Make_x_monotone_2(*this); }
|
||||
|
||||
|
|
@ -161,10 +161,10 @@ public:
|
|||
const Base_traits_2& m_base;
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Split_2(const Base_traits_2& base) : m_base(base) {}
|
||||
|
||||
/*! Split a given x-monotone curve at a given point into two sub-curves.
|
||||
/*! splits a given x-monotone curve at a given point into two sub-curves.
|
||||
* \param cv[in] The curve to split
|
||||
* \param p[in] The split point.
|
||||
* \param c1[out] The left resulting subcurve (p is its right endpoint).
|
||||
|
|
@ -183,7 +183,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Obtain a Split_2 functor object. */
|
||||
/*! obtains a Split_2 functor object. */
|
||||
Split_2 split_2_object() const { return Split_2(*this); }
|
||||
|
||||
class Intersect_2 {
|
||||
|
|
@ -191,10 +191,10 @@ public:
|
|||
const Base_traits_2& m_base;
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Intersect_2(const Base_traits_2& base) : m_base(base) {}
|
||||
|
||||
/*! Find the intersections of the two given curves and insert them to the
|
||||
/*! finds the intersections of the two given curves and insert them to the
|
||||
* given output iterator. As two segments may itersect only once, only a
|
||||
* single will be contained in the iterator.
|
||||
* \param cv1 The first curve.
|
||||
|
|
@ -240,7 +240,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Obtain an Intersect_2 functor object. */
|
||||
/*! obtains an `Intersect_2` functor object. */
|
||||
Intersect_2 intersect_2_object() const { return Intersect_2(*this); }
|
||||
|
||||
class Are_mergeable_2 {
|
||||
|
|
@ -288,10 +288,10 @@ public:
|
|||
}
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Are_mergeable_2(const Base_traits_2& base) : m_base(base) {}
|
||||
|
||||
/*! Check whether it is possible to merge two given x-monotone curves.
|
||||
/*! checks whether it is possible to merge two given x-monotone curves.
|
||||
* \param cv1[in] The first curve.
|
||||
* \param cv2[in] The second curve.
|
||||
* \return (true) if the two curves are mergeable; (false) otherwise.
|
||||
|
|
@ -301,7 +301,7 @@ public:
|
|||
{ return are_mergeable<Base_traits_2>(cv1, cv2, m_base, 0); }
|
||||
};
|
||||
|
||||
/*! Obtain an Are_mergeable_2 functor object. */
|
||||
/*! obtains an Are_mergeable_2 functor object. */
|
||||
Are_mergeable_2 are_mergeable_2_object() const
|
||||
{ return Are_mergeable_2(*this); }
|
||||
|
||||
|
|
@ -312,7 +312,7 @@ public:
|
|||
private:
|
||||
const Base_traits_2& m_base;
|
||||
|
||||
/*! Generate a helper class template to find out whether the base geometry
|
||||
/*! generates a helper class template to find out whether the base geometry
|
||||
* traits has a nested type named Merge_2.
|
||||
*/
|
||||
BOOST_MPL_HAS_XXX_TRAIT_NAMED_DEF(has_merge_2, Are_mergeable_2, false)
|
||||
|
|
@ -348,10 +348,10 @@ public:
|
|||
{ CGAL_error_msg("Merging curves is not supported."); }
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Merge_2(const Base_traits_2& base) : m_base(base) {}
|
||||
|
||||
/*! Merge two given x-monotone curves into a single curve (segment).
|
||||
/*! merges two given x-monotone curves into a single curve (segment).
|
||||
* \param[in] cv1 The first curve.
|
||||
* \param[in] cv2 The second curve.
|
||||
* \param[out] c The merged curve.
|
||||
|
|
@ -363,7 +363,7 @@ public:
|
|||
{ merge<Base_traits_2>(cv1, cv2, c); }
|
||||
};
|
||||
|
||||
/*! Obtain a Merge_2 functor object. */
|
||||
/*! obtains a `Merge_2` functor object. */
|
||||
Merge_2 merge_2_object() const { return Merge_2(*this); }
|
||||
|
||||
//@}
|
||||
|
|
@ -373,10 +373,10 @@ public:
|
|||
const Base_traits_2& m_base;
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Construct_x_monotone_curve_2(const Base_traits_2& base) : m_base(base) {}
|
||||
|
||||
/*! Obtain an x-monotone curve connecting the two given endpoints.
|
||||
/*! obtains an x-monotone curve connecting the two given endpoints.
|
||||
* \param p The first point.
|
||||
* \param q The second point.
|
||||
* \pre p and q must not be the same.
|
||||
|
|
@ -390,7 +390,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Obtain a Construct_x_monotone_curve_2 functor object. */
|
||||
/*! obtains a Construct_x_monotone_curve_2 functor object. */
|
||||
Construct_x_monotone_curve_2 construct_x_monotone_curve_2_object() const
|
||||
{ return Construct_x_monotone_curve_2(*this); }
|
||||
|
||||
|
|
@ -398,7 +398,7 @@ public:
|
|||
private:
|
||||
const Base_traits_2& m_base;
|
||||
|
||||
/*! Generate a helper class template to find out whether the base geometry
|
||||
/*! generates a helper class template to find out whether the base geometry
|
||||
* traits has a nested type named Construct_opposite_2.
|
||||
*/
|
||||
BOOST_MPL_HAS_XXX_TRAIT_NAMED_DEF(has_construct_opposite_2,
|
||||
|
|
@ -431,10 +431,10 @@ public:
|
|||
}
|
||||
|
||||
public:
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Construct_opposite_2(const Base_traits_2& base) : m_base(base) {}
|
||||
|
||||
/*! Construct an opposite x-monotone (with swapped source and target).
|
||||
/*! constructs an opposite x-monotone (with swapped source and target).
|
||||
* \param cv The curve.
|
||||
* \return The opposite curve.
|
||||
*/
|
||||
|
|
@ -442,7 +442,7 @@ public:
|
|||
{ return construct_opposite<Base_traits_2>(cv); }
|
||||
};
|
||||
|
||||
/*! Obtain a Construct_opposite_2 functor object. */
|
||||
/*! obtains a Construct_opposite_2 functor object. */
|
||||
Construct_opposite_2 construct_opposite_2_object() const
|
||||
{ return Construct_opposite_2(*this); }
|
||||
//@}
|
||||
|
|
|
|||
|
|
@ -82,13 +82,13 @@ protected:
|
|||
char pss[2]; // The x and y parameter spaces (condensed in two bytes).
|
||||
|
||||
public:
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_vertex_base() :
|
||||
p_inc(nullptr),
|
||||
p_pt(nullptr)
|
||||
{ pss[0] = pss[1] = static_cast<char>(CGAL::ARR_INTERIOR); }
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
virtual ~Arr_vertex_base() {}
|
||||
|
||||
// Access/modification for pointer squatting
|
||||
|
|
@ -96,35 +96,35 @@ public:
|
|||
void set_inc(void * inc) const
|
||||
{ const_cast<Arr_vertex_base&>(*this).p_inc = inc; }
|
||||
|
||||
/*! Check if the point pointer is nullptr. */
|
||||
/*! checks if the point pointer is nullptr. */
|
||||
bool has_null_point() const { return (p_pt == nullptr); }
|
||||
|
||||
/*! Obtain the point (const version). */
|
||||
/*! obtains the point (const version). */
|
||||
const Point& point() const
|
||||
{
|
||||
CGAL_assertion(p_pt != nullptr);
|
||||
return (*p_pt);
|
||||
}
|
||||
|
||||
/*! Obtain the point (non-const version). */
|
||||
/*! obtains the point (non-const version). */
|
||||
Point& point()
|
||||
{
|
||||
CGAL_assertion(p_pt != nullptr);
|
||||
return (*p_pt);
|
||||
}
|
||||
|
||||
/*! Set the point (may be a nullptr point). */
|
||||
/*! sets the point (may be a nullptr point). */
|
||||
void set_point(Point* p) { p_pt = p; }
|
||||
|
||||
/*! Obtain the boundary type in x. */
|
||||
/*! obtains the boundary type in x. */
|
||||
Arr_parameter_space parameter_space_in_x() const
|
||||
{ return (Arr_parameter_space(pss[0])); }
|
||||
|
||||
/*! Obtain the boundary type in y. */
|
||||
/*! obtains the boundary type in y. */
|
||||
Arr_parameter_space parameter_space_in_y() const
|
||||
{ return (Arr_parameter_space(pss[1])); }
|
||||
|
||||
/*! Set the boundary conditions of the vertex. */
|
||||
/*! sets the boundary conditions of the vertex. */
|
||||
void set_boundary(Arr_parameter_space ps_x, Arr_parameter_space ps_y)
|
||||
{
|
||||
pss[0] = static_cast<char>(ps_x);
|
||||
|
|
@ -132,7 +132,7 @@ public:
|
|||
return;
|
||||
}
|
||||
|
||||
/*! Assign from another vertex. */
|
||||
/*! assigns from another vertex. */
|
||||
virtual void assign(const Arr_vertex_base<Point>& v)
|
||||
{
|
||||
p_pt = v.p_pt;
|
||||
|
|
@ -170,7 +170,7 @@ protected:
|
|||
X_monotone_curve* p_cv; // The associated x-monotone curve.
|
||||
|
||||
public:
|
||||
/*! Default constructor */
|
||||
/*! constructs default */
|
||||
Arr_halfedge_base() :
|
||||
p_opp(nullptr),
|
||||
p_prev(nullptr),
|
||||
|
|
@ -180,27 +180,27 @@ public:
|
|||
p_cv(nullptr)
|
||||
{}
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
virtual ~Arr_halfedge_base() {}
|
||||
|
||||
/*! Check if the curve pointer is nullptr. */
|
||||
/*! checks if the curve pointer is nullptr. */
|
||||
bool has_null_curve() const { return (p_cv == nullptr); }
|
||||
|
||||
/*! Obtain the x-monotone curve (const version). */
|
||||
/*! obtains the x-monotone curve (const version). */
|
||||
const X_monotone_curve& curve() const
|
||||
{
|
||||
CGAL_precondition(p_cv != nullptr);
|
||||
return (*p_cv);
|
||||
}
|
||||
|
||||
/*! Obtain the x-monotone curve (non-const version). */
|
||||
/*! obtains the x-monotone curve (non-const version). */
|
||||
X_monotone_curve& curve()
|
||||
{
|
||||
CGAL_precondition(p_cv != nullptr);
|
||||
return (*p_cv);
|
||||
}
|
||||
|
||||
/*! Set the x-monotone curve. */
|
||||
/*! sets the x-monotone curve. */
|
||||
void set_curve(X_monotone_curve* c)
|
||||
{
|
||||
p_cv = c;
|
||||
|
|
@ -212,13 +212,12 @@ public:
|
|||
opp->p_cv = c;
|
||||
}
|
||||
|
||||
/*! Assign from another halfedge. */
|
||||
/*! assigns from another halfedge. */
|
||||
virtual void assign(const Arr_halfedge_base<X_monotone_curve>& he)
|
||||
{ p_cv = he.p_cv; }
|
||||
};
|
||||
|
||||
/*!
|
||||
* Base face class.
|
||||
/*! Base face class.
|
||||
*/
|
||||
class Arr_face_base
|
||||
{
|
||||
|
|
@ -248,27 +247,27 @@ protected:
|
|||
Isolated_vertices_container iso_verts; // The isolated vertices inside
|
||||
// the face.
|
||||
public:
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_face_base() : flags(0) {}
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
virtual ~Arr_face_base() {}
|
||||
|
||||
/*! Check if the face is unbounded. */
|
||||
/*! checks if the face is unbounded. */
|
||||
bool is_unbounded() const { return ((flags & IS_UNBOUNDED) != 0); }
|
||||
|
||||
/*! Set the face as bounded or unbounded. */
|
||||
/*! sets the face as bounded or unbounded. */
|
||||
void set_unbounded(bool unbounded)
|
||||
{ flags = (unbounded) ? (flags | IS_UNBOUNDED) : (flags & ~IS_UNBOUNDED); }
|
||||
|
||||
/*! Check if the face is fictitious. */
|
||||
/*! checks if the face is fictitious. */
|
||||
bool is_fictitious() const { return ((flags & IS_FICTITIOUS) != 0); }
|
||||
|
||||
/*! Set the face as fictitious or valid. */
|
||||
/*! sets the face as fictitious or valid. */
|
||||
void set_fictitious(bool fictitious)
|
||||
{ flags = (fictitious) ? (flags | IS_FICTITIOUS) : (flags & ~IS_FICTITIOUS); }
|
||||
|
||||
/*! Assign from another face. */
|
||||
/*! assigns from another face. */
|
||||
virtual void assign(const Arr_face_base& f) { flags = f.flags; }
|
||||
};
|
||||
|
||||
|
|
@ -293,38 +292,38 @@ public:
|
|||
typedef Arr_halfedge<V,H,F> Halfedge;
|
||||
typedef Arr_isolated_vertex<V,H,F> Isolated_vertex;
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_vertex() {}
|
||||
|
||||
/*! Check if the vertex is isolated. */
|
||||
/*! checks if the vertex is isolated. */
|
||||
bool is_isolated() const
|
||||
{
|
||||
// Note that we use the LSB of the p_inc pointer as a Boolean flag.
|
||||
return (_is_lsb_set(this->p_inc));
|
||||
}
|
||||
|
||||
/*! Obtain an incident halfedge (const version). */
|
||||
/*! obtains an incident halfedge (const version). */
|
||||
const Halfedge* halfedge() const
|
||||
{
|
||||
CGAL_precondition(! is_isolated());
|
||||
return (reinterpret_cast<const Halfedge*>(this->p_inc));
|
||||
}
|
||||
|
||||
/*! Obtain an incident halfedge (non-const version). */
|
||||
/*! obtains an incident halfedge (non-const version). */
|
||||
Halfedge* halfedge()
|
||||
{
|
||||
CGAL_precondition(! is_isolated());
|
||||
return (reinterpret_cast<Halfedge*>(this->p_inc));
|
||||
}
|
||||
|
||||
/*! Set an incident halfedge (for non-isolated vertices). */
|
||||
/*! sets an incident halfedge (for non-isolated vertices). */
|
||||
void set_halfedge(Halfedge* he)
|
||||
{
|
||||
// Set the halfedge pointer and reset the LSB.
|
||||
this->p_inc = he;
|
||||
}
|
||||
|
||||
/*! Obtain the isolated vertex information (const version). */
|
||||
/*! obtains the isolated vertex information (const version). */
|
||||
const Isolated_vertex* isolated_vertex() const
|
||||
{
|
||||
CGAL_precondition(is_isolated());
|
||||
|
|
@ -332,14 +331,14 @@ public:
|
|||
(this->p_inc)));
|
||||
}
|
||||
|
||||
/*! Obtain the isolated vertex information (non-const version). */
|
||||
/*! obtains the isolated vertex information (non-const version). */
|
||||
Isolated_vertex* isolated_vertex()
|
||||
{
|
||||
CGAL_precondition(is_isolated());
|
||||
return (reinterpret_cast<Isolated_vertex*>(_clean_pointer(this->p_inc)));
|
||||
}
|
||||
|
||||
/*! Set the isolated vertex information. */
|
||||
/*! sets the isolated vertex information. */
|
||||
void set_isolated_vertex(Isolated_vertex* iv)
|
||||
{
|
||||
// Set the isolated vertex-information pointer and set its LSB.
|
||||
|
|
@ -362,20 +361,20 @@ public:
|
|||
typedef Arr_outer_ccb<V,H,F> Outer_ccb;
|
||||
typedef Arr_inner_ccb<V,H,F> Inner_ccb;
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_halfedge() {}
|
||||
|
||||
/*! Obtain the opposite halfedge (const version). */
|
||||
/*! obtains the opposite halfedge (const version). */
|
||||
const Halfedge* opposite () const
|
||||
{ return (reinterpret_cast<const Halfedge*>(this->p_opp)); }
|
||||
|
||||
/*! Obtain the opposite halfedge (non-const version). */
|
||||
/*! obtains the opposite halfedge (non-const version). */
|
||||
Halfedge* opposite() { return (reinterpret_cast<Halfedge*>(this->p_opp)); }
|
||||
|
||||
/*! Sets the opposite halfedge. */
|
||||
void set_opposite(Halfedge* he) { this->p_opp = he; }
|
||||
|
||||
/*! Obtain the direction of the halfedge. */
|
||||
/*! obtains the direction of the halfedge. */
|
||||
Arr_halfedge_direction direction() const
|
||||
{
|
||||
// Note that we use the LSB of the p_v pointer as a Boolean flag.
|
||||
|
|
@ -383,7 +382,7 @@ public:
|
|||
else return (ARR_RIGHT_TO_LEFT);
|
||||
}
|
||||
|
||||
/*! Set the direction of the edge (and of its opposite halfedge). */
|
||||
/*! sets the direction of the edge (and of its opposite halfedge). */
|
||||
void set_direction(Arr_halfedge_direction dir)
|
||||
{
|
||||
Halfedge* opp = reinterpret_cast<Halfedge*>(this->p_opp);
|
||||
|
|
@ -398,43 +397,43 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
/*! Obtain the previous halfedge along the chain (const version). */
|
||||
/*! obtains the previous halfedge along the chain (const version). */
|
||||
const Halfedge* prev() const
|
||||
{ return (reinterpret_cast<const Halfedge*>(this->p_prev)); }
|
||||
|
||||
/*! Obtain the previous halfedge along the chain (const version). */
|
||||
/*! obtains the previous halfedge along the chain (const version). */
|
||||
Halfedge* prev() { return (reinterpret_cast<Halfedge*>(this->p_prev)); }
|
||||
|
||||
/*! Set the previous halfedge along the chain. */
|
||||
/*! sets the previous halfedge along the chain. */
|
||||
void set_prev(Halfedge* he)
|
||||
{
|
||||
this->p_prev = he;
|
||||
he->p_next = this;
|
||||
}
|
||||
|
||||
/*! Obtain the next halfedge along the chain (const version). */
|
||||
/*! obtains the next halfedge along the chain (const version). */
|
||||
const Halfedge* next() const
|
||||
{ return (reinterpret_cast<const Halfedge*>(this->p_next)); }
|
||||
|
||||
/*! Obtain the next halfedge along the chain (const version). */
|
||||
/*! obtains the next halfedge along the chain (const version). */
|
||||
Halfedge* next() { return (reinterpret_cast<Halfedge*>(this->p_next)); }
|
||||
|
||||
/*! Set the next halfedge along the chain. */
|
||||
/*! sets the next halfedge along the chain. */
|
||||
void set_next(Halfedge* he)
|
||||
{
|
||||
this->p_next = he;
|
||||
he->p_prev = this;
|
||||
}
|
||||
|
||||
/*! Obtain the target vertex (const version). */
|
||||
/*! obtains the target vertex (const version). */
|
||||
const Vertex* vertex() const
|
||||
{ return (reinterpret_cast<const Vertex*>(_clean_pointer(this->p_v))); }
|
||||
|
||||
/*! Obtain the target vertex (non-const version). */
|
||||
/*! obtains the target vertex (non-const version). */
|
||||
Vertex* vertex()
|
||||
{ return (reinterpret_cast<Vertex*>(_clean_pointer(this->p_v))); }
|
||||
|
||||
/*! Set the target vertex. */
|
||||
/*! sets the target vertex. */
|
||||
void set_vertex(Vertex* v)
|
||||
{
|
||||
// Set the vertex pointer, preserving the content of the LSB.
|
||||
|
|
@ -442,10 +441,10 @@ public:
|
|||
else this->p_v = v;
|
||||
}
|
||||
|
||||
/*! Check whether the halfedge lies on the boundary of an outer CCB. */
|
||||
/*! checks whether the halfedge lies on the boundary of an outer CCB. */
|
||||
bool is_on_outer_ccb() const { return (!_is_lsb_set(this->p_comp)); }
|
||||
|
||||
/*! Obtain an incident outer CCB (const version).
|
||||
/*! obtains an incident outer CCB (const version).
|
||||
* \pre The edge does not lie on an inner CCB.
|
||||
*/
|
||||
const Outer_ccb* outer_ccb() const
|
||||
|
|
@ -454,7 +453,7 @@ public:
|
|||
return (reinterpret_cast<const Outer_ccb*>(this->p_comp));
|
||||
}
|
||||
|
||||
/*! Obtain an incident outer CCB (non-const version).
|
||||
/*! obtains an incident outer CCB (non-const version).
|
||||
* \pre The edge does not lie on an inner CCB.
|
||||
*/
|
||||
Outer_ccb* outer_ccb()
|
||||
|
|
@ -463,17 +462,17 @@ public:
|
|||
return (reinterpret_cast<Outer_ccb*>(this->p_comp));
|
||||
}
|
||||
|
||||
/*! Set the incident outer CCB. */
|
||||
/*! sets the incident outer CCB. */
|
||||
void set_outer_ccb(Outer_ccb *oc)
|
||||
{
|
||||
// Set the component pointer and reset its LSB.
|
||||
this->p_comp = oc;
|
||||
}
|
||||
|
||||
/*! Check whether the halfedge lies on the boundary of an inner CCB. */
|
||||
/*! checks whether the halfedge lies on the boundary of an inner CCB. */
|
||||
bool is_on_inner_ccb() const { return (_is_lsb_set(this->p_comp)); }
|
||||
|
||||
/*! Obtain an incident inner CCB (const version).
|
||||
/*! obtains an incident inner CCB (const version).
|
||||
* \pre The edge lies on an inner CCB.
|
||||
*/
|
||||
const Inner_ccb* inner_ccb() const
|
||||
|
|
@ -493,7 +492,7 @@ public:
|
|||
return valid;
|
||||
}
|
||||
|
||||
/*! Obtain an incident inner CCB (non-const version).
|
||||
/*! obtains an incident inner CCB (non-const version).
|
||||
* \pre The edge lies on an inner CCB.
|
||||
*/
|
||||
Inner_ccb* inner_ccb()
|
||||
|
|
@ -519,7 +518,7 @@ public:
|
|||
return reinterpret_cast<Inner_ccb*>(_clean_pointer(this->p_comp));
|
||||
}
|
||||
|
||||
/*! Set the incident inner CCB. */
|
||||
/*! sets the incident inner CCB. */
|
||||
void set_inner_ccb(const Inner_ccb *ic)
|
||||
{
|
||||
// Set the component pointer and set its LSB.
|
||||
|
|
@ -553,7 +552,7 @@ private:
|
|||
|
||||
public:
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_face()
|
||||
{}
|
||||
|
||||
|
|
@ -565,20 +564,20 @@ public:
|
|||
_Const_ccb_to_halfedge_cast>
|
||||
Outer_ccb_const_iterator;
|
||||
|
||||
/*! Obtain the number of outer CCBs the face has. */
|
||||
/*! obtains the number of outer CCBs the face has. */
|
||||
size_t number_of_outer_ccbs() const { return (this->outer_ccbs.size()); }
|
||||
|
||||
/*! Obtain an iterator for the first outer CCB of the face. */
|
||||
/*! obtains an iterator for the first outer CCB of the face. */
|
||||
Outer_ccb_iterator outer_ccbs_begin() { return (this->outer_ccbs.begin()); }
|
||||
|
||||
/*! Obtain a past-the-end iterator for the outer CCBs inside the face. */
|
||||
/*! obtains a past-the-end iterator for the outer CCBs inside the face. */
|
||||
Outer_ccb_iterator outer_ccbs_end() { return (this->outer_ccbs.end()); }
|
||||
|
||||
/*! Obtain an const iterator for the first outer CCB inside the face. */
|
||||
/*! obtains an const iterator for the first outer CCB inside the face. */
|
||||
Outer_ccb_const_iterator outer_ccbs_begin() const
|
||||
{ return (this->outer_ccbs.begin()); }
|
||||
|
||||
/*! Obtain a const past-the-end iterator for the outer CCBs inside the face. */
|
||||
/*! obtains a const past-the-end iterator for the outer CCBs inside the face. */
|
||||
Outer_ccb_const_iterator outer_ccbs_end() const
|
||||
{ return (this->outer_ccbs.end()); }
|
||||
|
||||
|
|
@ -601,20 +600,20 @@ public:
|
|||
typedef Inner_ccb_iterator Hole_iterator;
|
||||
typedef Inner_ccb_const_iterator Hole_const_iterator;
|
||||
|
||||
/*! Obtain the number of inner CCBs the face has. */
|
||||
/*! obtains the number of inner CCBs the face has. */
|
||||
size_t number_of_inner_ccbs() const { return (this->inner_ccbs.size()); }
|
||||
|
||||
/*! Obtain an iterator for the first inner CCB of the face. */
|
||||
/*! obtains an iterator for the first inner CCB of the face. */
|
||||
Inner_ccb_iterator inner_ccbs_begin() { return (this->inner_ccbs.begin()); }
|
||||
|
||||
/*! Obtain a past-the-end iterator for the inner CCBs inside the face. */
|
||||
/*! obtains a past-the-end iterator for the inner CCBs inside the face. */
|
||||
Inner_ccb_iterator inner_ccbs_end() { return (this->inner_ccbs.end()); }
|
||||
|
||||
/*! Obtain an const iterator for the first inner CCB inside the face. */
|
||||
/*! obtains an const iterator for the first inner CCB inside the face. */
|
||||
Inner_ccb_const_iterator inner_ccbs_begin() const
|
||||
{ return (this->inner_ccbs.begin()); }
|
||||
|
||||
/*! Obtain a const past-the-end iterator for the inner CCBs inside the face. */
|
||||
/*! obtains a const past-the-end iterator for the inner CCBs inside the face. */
|
||||
Inner_ccb_const_iterator inner_ccbs_end() const
|
||||
{ return (this->inner_ccbs.end()); }
|
||||
|
||||
|
|
@ -669,23 +668,23 @@ public:
|
|||
typename F::Isolated_vertex_iterator::iterator_category>
|
||||
Isolated_vertex_const_iterator;
|
||||
|
||||
/*! Obtain the number of isloated vertices inside the face. */
|
||||
/*! obtains the number of isloated vertices inside the face. */
|
||||
size_t number_of_isolated_vertices() const
|
||||
{ return (this->iso_verts.size()); }
|
||||
|
||||
/*! Obtain an iterator for the first isloated vertex inside the face. */
|
||||
/*! obtains an iterator for the first isloated vertex inside the face. */
|
||||
Isolated_vertex_iterator isolated_vertices_begin()
|
||||
{ return (this->iso_verts.begin()); }
|
||||
|
||||
/*! Obtain a past-the-end iterator for the isloated vertices inside the face. */
|
||||
/*! obtains a past-the-end iterator for the isloated vertices inside the face. */
|
||||
Isolated_vertex_iterator isolated_vertices_end()
|
||||
{ return (this->iso_verts.end()); }
|
||||
|
||||
/*! Obtain an const iterator for the first isloated vertex inside the face. */
|
||||
/*! obtains an const iterator for the first isloated vertex inside the face. */
|
||||
Isolated_vertex_const_iterator isolated_vertices_begin() const
|
||||
{ return (this->iso_verts.begin()); }
|
||||
|
||||
/*! Obtain a const past-the-end iterator for the isloated vertices inside the
|
||||
/*! obtains a const past-the-end iterator for the isloated vertices inside the
|
||||
* face. */
|
||||
Isolated_vertex_const_iterator isolated_vertices_end() const
|
||||
{ return (this->iso_verts.end()); }
|
||||
|
|
@ -736,47 +735,47 @@ private:
|
|||
bool iter_is_not_singular;
|
||||
|
||||
public:
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_outer_ccb() : p_f(nullptr), iter_is_not_singular(false) {}
|
||||
|
||||
/*! Copy constructor. */
|
||||
/*! constructs copy. */
|
||||
Arr_outer_ccb(const Arr_outer_ccb& other) :
|
||||
p_f(other.p_f), iter_is_not_singular(other.iter_is_not_singular)
|
||||
{ if (other.iter_is_not_singular) iter = other.iter; }
|
||||
|
||||
/*! Obtain a halfedge along the component (const version). */
|
||||
/*! obtains a halfedge along the component (const version). */
|
||||
const Halfedge* halfedge() const { return (*iter); }
|
||||
|
||||
/*! Obtain a halfedge along the component (non-const version). */
|
||||
/*! obtains a halfedge along the component (non-const version). */
|
||||
Halfedge* halfedge() { return (*iter); }
|
||||
|
||||
/*! Set a representative halfedge for the component. */
|
||||
/*! sets a representative halfedge for the component. */
|
||||
void set_halfedge(Halfedge* he) { *iter = he; }
|
||||
|
||||
/*! Obtain the incident face (const version). */
|
||||
/*! obtains the incident face (const version). */
|
||||
const Face* face() const { return (p_f); }
|
||||
|
||||
/*! Obtain the incident face (non-const version). */
|
||||
/*! obtains the incident face (non-const version). */
|
||||
Face* face() { return (p_f); }
|
||||
|
||||
/*! Set the incident face. */
|
||||
/*! sets the incident face. */
|
||||
void set_face(Face* f) { p_f = f; }
|
||||
|
||||
/*! Obtain the iterator (const version). */
|
||||
/*! obtains the iterator (const version). */
|
||||
Outer_ccb_iterator iterator() const
|
||||
{
|
||||
CGAL_assertion(iter_is_not_singular);
|
||||
return (iter);
|
||||
}
|
||||
|
||||
/*! Obtain the iterator (non-const version). */
|
||||
/*! obtains the iterator (non-const version). */
|
||||
Outer_ccb_iterator iterator()
|
||||
{
|
||||
CGAL_assertion(iter_is_not_singular);
|
||||
return (iter);
|
||||
}
|
||||
|
||||
/*! Set the outer CCB iterator. */
|
||||
/*! sets the outer CCB iterator. */
|
||||
void set_iterator(Outer_ccb_iterator it)
|
||||
{
|
||||
iter = it;
|
||||
|
|
@ -813,71 +812,71 @@ private:
|
|||
} status;
|
||||
|
||||
public:
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_inner_ccb() : status(ITER_IS_SINGULAR) { f_or_icc.f = nullptr; }
|
||||
|
||||
/*! Copy constructor. */
|
||||
/*! constructs copy. */
|
||||
Arr_inner_ccb(const Arr_inner_ccb& other) :
|
||||
f_or_icc(other.f_or_icc), status(other.status)
|
||||
{ if (other.status == ITER_IS_NOT_SINGULAR) iter = other.iter; }
|
||||
|
||||
/*! Obtain a halfedge along the component (const version). */
|
||||
/*! obtains a halfedge along the component (const version). */
|
||||
const Halfedge* halfedge() const
|
||||
{
|
||||
CGAL_assertion(is_valid());
|
||||
return (*iter);
|
||||
}
|
||||
|
||||
/*! Obtain a halfedge along the component (non-const version). */
|
||||
/*! obtains a halfedge along the component (non-const version). */
|
||||
Halfedge* halfedge()
|
||||
{
|
||||
CGAL_assertion(is_valid());
|
||||
return (*iter);
|
||||
}
|
||||
|
||||
/*! Set a representative halfedge for the component. */
|
||||
/*! sets a representative halfedge for the component. */
|
||||
void set_halfedge(Halfedge *he)
|
||||
{
|
||||
CGAL_assertion(is_valid());
|
||||
*iter = he;
|
||||
}
|
||||
|
||||
/*! Obtain the incident face (const version). */
|
||||
/*! obtains the incident face (const version). */
|
||||
const Face* face() const
|
||||
{
|
||||
CGAL_assertion(status != INVALID);
|
||||
return f_or_icc.f;
|
||||
}
|
||||
|
||||
/*! Obtain the incident face (non-const version). */
|
||||
/*! obtains the incident face (non-const version). */
|
||||
Face* face()
|
||||
{
|
||||
CGAL_assertion(status != INVALID);
|
||||
return f_or_icc.f;
|
||||
}
|
||||
|
||||
/*! Set the incident face. */
|
||||
/*! sets the incident face. */
|
||||
void set_face(Face* f)
|
||||
{
|
||||
CGAL_assertion(status != INVALID);
|
||||
f_or_icc.f = f;
|
||||
}
|
||||
|
||||
/*! Obtain the iterator (const version). */
|
||||
/*! obtains the iterator (const version). */
|
||||
Inner_ccb_iterator iterator() const
|
||||
{
|
||||
CGAL_assertion(status == ITER_IS_NOT_SINGULAR);
|
||||
return (iter);
|
||||
}
|
||||
|
||||
/*! Obtain the iterator (non-const version). */
|
||||
/*! obtains the iterator (non-const version). */
|
||||
Inner_ccb_iterator iterator()
|
||||
{
|
||||
CGAL_assertion(status == ITER_IS_NOT_SINGULAR);
|
||||
return (iter);
|
||||
}
|
||||
|
||||
/*! Set the inner CCB iterator. */
|
||||
/*! sets the inner CCB iterator. */
|
||||
void set_iterator(Inner_ccb_iterator it)
|
||||
{
|
||||
CGAL_assertion(is_valid());
|
||||
|
|
@ -885,17 +884,17 @@ public:
|
|||
status = ITER_IS_NOT_SINGULAR;
|
||||
}
|
||||
|
||||
/*! Check validity */
|
||||
/*! checks validity */
|
||||
bool is_valid() const { return (status != INVALID); }
|
||||
|
||||
/*! Obtain the next CCB to primary chain. */
|
||||
/*! obtains the next CCB to primary chain. */
|
||||
Arr_inner_ccb* next() const
|
||||
{
|
||||
CGAL_assertion(status == INVALID);
|
||||
return f_or_icc.icc;
|
||||
}
|
||||
|
||||
/*! Set the next CCB to primary chain. */
|
||||
/*! sets the next CCB to primary chain. */
|
||||
void set_next(Arr_inner_ccb* next)
|
||||
{
|
||||
status = INVALID;
|
||||
|
|
@ -921,38 +920,38 @@ private:
|
|||
bool iter_is_not_singular;
|
||||
|
||||
public:
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_isolated_vertex() : p_f(nullptr), iter_is_not_singular(false) {}
|
||||
|
||||
/*! Copy constructor. */
|
||||
/*! constructs copy. */
|
||||
Arr_isolated_vertex(const Arr_isolated_vertex& other) :
|
||||
p_f(other.p_f), iter_is_not_singular(other.iter_is_not_singular)
|
||||
{ if (other.iter_is_not_singular) iv_it = other.iv_it; }
|
||||
|
||||
/*! Obtain the containing face (const version). */
|
||||
/*! obtains the containing face (const version). */
|
||||
const Face* face() const { return (p_f); }
|
||||
|
||||
/*! Obtain the containing face (non-const version). */
|
||||
/*! obtains the containing face (non-const version). */
|
||||
Face* face() { return (p_f); }
|
||||
|
||||
/*! Set the incident face, the one that contains the isolated vertex. */
|
||||
/*! sets the incident face, the one that contains the isolated vertex. */
|
||||
void set_face(Face* f) { p_f = f; }
|
||||
|
||||
/*! Obtain the isolated vertex iterator (const version). */
|
||||
/*! obtains the isolated vertex iterator (const version). */
|
||||
Isolated_vertex_iterator iterator() const
|
||||
{
|
||||
CGAL_assertion(iter_is_not_singular);
|
||||
return (iv_it);
|
||||
}
|
||||
|
||||
/*! Obtain the isolated vertex iterator (non-const version). */
|
||||
/*! obtains the isolated vertex iterator (non-const version). */
|
||||
Isolated_vertex_iterator iterator()
|
||||
{
|
||||
CGAL_assertion(iter_is_not_singular);
|
||||
return (iv_it);
|
||||
}
|
||||
|
||||
/*! Set the isolated vertex iterator. */
|
||||
/*! sets the isolated vertex iterator. */
|
||||
void set_iterator(Isolated_vertex_iterator iv)
|
||||
{
|
||||
iv_it = iv;
|
||||
|
|
@ -1035,40 +1034,40 @@ public:
|
|||
Edge_const_iterator;
|
||||
|
||||
private:
|
||||
// Copy constructor - not supported.
|
||||
// Copy constructor not supported.
|
||||
Arr_dcel_base(const Self&);
|
||||
|
||||
// Assignment operator - not supported.
|
||||
// Assignment operator not supported.
|
||||
Self& operator=(const Self&);
|
||||
|
||||
public:
|
||||
/// \name Construction and destruction.
|
||||
//@{
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_dcel_base() {}
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
~Arr_dcel_base() { delete_all(); }
|
||||
//@}
|
||||
|
||||
/// \name The DCEL size.
|
||||
//@{
|
||||
/*! Obtain the number of DCEL vertices. */
|
||||
/*! obtains the number of DCEL vertices. */
|
||||
Size size_of_vertices() const { return (vertices.size()); }
|
||||
|
||||
/*! Obtain the number of DCEL halfedges (twice the number of edges). */
|
||||
/*! obtains the number of DCEL halfedges (twice the number of edges). */
|
||||
Size size_of_halfedges() const { return (halfedges.size()); }
|
||||
|
||||
/*! Obtain the number of DCEL faces. */
|
||||
/*! obtains the number of DCEL faces. */
|
||||
Size size_of_faces() const { return (faces.size()); }
|
||||
|
||||
/*! Obtain the number of outer CCBs. */
|
||||
/*! obtains the number of outer CCBs. */
|
||||
Size size_of_outer_ccbs() const { return (out_ccbs.size()); }
|
||||
|
||||
/*! Obtain the number of inner CCBs. */
|
||||
/*! obtains the number of inner CCBs. */
|
||||
Size size_of_inner_ccbs() const { return (in_ccbs.size()); }
|
||||
|
||||
/*! Obtain the number of isolated vertices. */
|
||||
/*! obtains the number of isolated vertices. */
|
||||
Size size_of_isolated_vertices() const { return (iso_verts.size()); }
|
||||
//@}
|
||||
|
||||
|
|
@ -1141,7 +1140,7 @@ public:
|
|||
|
||||
// \name Creation of new DCEL features.
|
||||
//@{
|
||||
/*! Create a new vertex. */
|
||||
/*! creates a new vertex. */
|
||||
Vertex* new_vertex()
|
||||
{
|
||||
Vertex* v = vertex_alloc.allocate(1);
|
||||
|
|
@ -1150,7 +1149,7 @@ public:
|
|||
return v;
|
||||
}
|
||||
|
||||
/*! Create a new pair of opposite halfedges. */
|
||||
/*! creates a new pair of opposite halfedges. */
|
||||
Halfedge* new_edge()
|
||||
{
|
||||
// Create two new halfedges.
|
||||
|
|
@ -1164,7 +1163,7 @@ public:
|
|||
return (h1);
|
||||
}
|
||||
|
||||
/*! Create a new face. */
|
||||
/*! creates a new face. */
|
||||
Face* new_face()
|
||||
{
|
||||
Face* f = face_alloc.allocate(1);
|
||||
|
|
@ -1173,7 +1172,7 @@ public:
|
|||
return(f);
|
||||
}
|
||||
|
||||
/*! Create a new outer CCB. */
|
||||
/*! creates a new outer CCB. */
|
||||
Outer_ccb* new_outer_ccb()
|
||||
{
|
||||
Outer_ccb* oc = out_ccb_alloc.allocate(1);
|
||||
|
|
@ -1182,7 +1181,7 @@ public:
|
|||
return (oc);
|
||||
}
|
||||
|
||||
/*! Create a new inner CCB. */
|
||||
/*! creates a new inner CCB. */
|
||||
Inner_ccb* new_inner_ccb()
|
||||
{
|
||||
Inner_ccb* ic = in_ccb_alloc.allocate(1);
|
||||
|
|
@ -1191,7 +1190,7 @@ public:
|
|||
return (ic);
|
||||
}
|
||||
|
||||
/*! Create a new isolated vertex. */
|
||||
/*! creates a new isolated vertex. */
|
||||
Isolated_vertex* new_isolated_vertex()
|
||||
{
|
||||
Isolated_vertex* iv = iso_vert_alloc.allocate(1);
|
||||
|
|
@ -1304,7 +1303,7 @@ public:
|
|||
}
|
||||
//@}
|
||||
|
||||
/*! Assign our DCEL the contents of another DCEL.
|
||||
/*! assigns our DCEL the contents of another DCEL.
|
||||
*/
|
||||
void assign(const Self& dcel)
|
||||
{
|
||||
|
|
@ -1504,7 +1503,7 @@ public:
|
|||
}
|
||||
|
||||
protected:
|
||||
/*! Create a new halfedge. */
|
||||
/*! creates a new halfedge. */
|
||||
Halfedge* _new_halfedge()
|
||||
{
|
||||
Halfedge* h = halfedge_alloc.allocate(1);
|
||||
|
|
@ -1513,7 +1512,7 @@ protected:
|
|||
return (h);
|
||||
}
|
||||
|
||||
/*! Delete an existing halfedge. */
|
||||
/*! deletes an existing halfedge. */
|
||||
void _delete_halfedge(Halfedge* h)
|
||||
{
|
||||
halfedges.erase(h);
|
||||
|
|
@ -1522,7 +1521,7 @@ protected:
|
|||
}
|
||||
};
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ public:
|
|||
typedef typename Base::Segment_assertions Segment_assertions;
|
||||
typedef typename Base::Has_exact_division Has_exact_division;
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_directional_non_caching_segment_basic_traits_2() : Base() {}
|
||||
|
||||
/// \name Types and functors inherited from the base, required by the
|
||||
|
|
@ -103,7 +103,7 @@ public:
|
|||
//@{
|
||||
typedef typename Kernel::Construct_opposite_segment_2 Construct_opposite_2;
|
||||
|
||||
/*! Obtain a Construct_opposite_2 functor object. */
|
||||
/*! obtains a Construct_opposite_2 functor object. */
|
||||
Construct_opposite_2 construct_opposite_2_object() const
|
||||
{ return Construct_opposite_2(); }
|
||||
|
||||
|
|
@ -114,7 +114,7 @@ public:
|
|||
/*! The traits (in case it has state). */
|
||||
const Traits& m_traits;
|
||||
|
||||
/*! Constructor
|
||||
/*! Constructs
|
||||
* \param traits the traits (in case it has state).
|
||||
*/
|
||||
Compare_endpoints_xy_2(const Traits& traits) : m_traits(traits) {}
|
||||
|
|
@ -122,7 +122,7 @@ public:
|
|||
friend class Arr_directional_non_caching_segment_basic_traits_2<Kernel>;
|
||||
|
||||
public:
|
||||
/*! Compare the two endpoints of a given curve lexigoraphically.
|
||||
/*! compares the two endpoints of a given curve lexigoraphically.
|
||||
* \param cv The curve.
|
||||
* \return SMALLER if cv is directed from left to right and LARGER
|
||||
* otherwise.
|
||||
|
|
@ -138,7 +138,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Obtain a Compare_endpoints_xy_2 functor object. */
|
||||
/*! obtains a Compare_endpoints_xy_2 functor object. */
|
||||
Compare_endpoints_xy_2 compare_endpoints_xy_2_object() const
|
||||
{ return Compare_endpoints_xy_2(*this); }
|
||||
//@}
|
||||
|
|
|
|||
|
|
@ -43,16 +43,16 @@ private:
|
|||
Data m_data; // The auxiliary data field.
|
||||
|
||||
public:
|
||||
/*! Get the auxiliary data (const version). */
|
||||
/*! obtains the auxiliary data (const version). */
|
||||
const Data& data() const { return m_data; }
|
||||
|
||||
/*! Get the auxiliary data (non-const version). */
|
||||
/*! obtains the auxiliary data (non-const version). */
|
||||
Data& data() { return m_data; }
|
||||
|
||||
/*! Set the auxiliary data. */
|
||||
/*! sets the auxiliary data. */
|
||||
void set_data(const Data& data) { m_data = data; }
|
||||
|
||||
/*! Assign from another vertex. */
|
||||
/*! assigns from another vertex. */
|
||||
virtual void assign(const Vertex_base& v) {
|
||||
Vertex_base::assign(v);
|
||||
const Self& ex_v = static_cast<const Self&>(v);
|
||||
|
|
@ -83,16 +83,16 @@ private:
|
|||
Data m_data; // The auxiliary data field.
|
||||
|
||||
public:
|
||||
/*! Get the auxiliary data (const version). */
|
||||
/*! obtains the auxiliary data (const version). */
|
||||
const Data& data() const { return m_data; }
|
||||
|
||||
/*! Get the auxiliary data (non-const version). */
|
||||
/*! obtains the auxiliary data (non-const version). */
|
||||
Data& data() { return m_data; }
|
||||
|
||||
/*! Set the auxiliary data. */
|
||||
/*! sets the auxiliary data. */
|
||||
void set_data(const Data& data) { m_data = data; }
|
||||
|
||||
/*! Assign from another halfedge. */
|
||||
/*! assigns from another halfedge. */
|
||||
virtual void assign(const Halfedge_base& he) {
|
||||
Halfedge_base::assign(he);
|
||||
const Self& ex_he = static_cast<const Self&>(he);
|
||||
|
|
@ -123,16 +123,16 @@ private:
|
|||
Data m_data; // The auxiliary data field.
|
||||
|
||||
public:
|
||||
/*! Get the auxiliary data (const version). */
|
||||
/*! obtains the auxiliary data (const version). */
|
||||
const Data& data() const { return m_data; }
|
||||
|
||||
/*! Get the auxiliary data (non-const version). */
|
||||
/*! obtains the auxiliary data (non-const version). */
|
||||
Data& data() { return m_data; }
|
||||
|
||||
/*! Set the auxiliary data. */
|
||||
/*! sets the auxiliary data. */
|
||||
void set_data(const Data& data) { m_data = data; }
|
||||
|
||||
/*! Assign from another face. */
|
||||
/*! assigns from another face. */
|
||||
virtual void assign(const Face_base& f) {
|
||||
Face_base::assign(f);
|
||||
const Self& ex_f = static_cast<const Self&>(f);
|
||||
|
|
@ -176,10 +176,10 @@ public:
|
|||
Halfedge_other, Face_base>;
|
||||
};
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_face_extended_dcel() {}
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
virtual ~Arr_face_extended_dcel() {}
|
||||
};
|
||||
|
||||
|
|
@ -227,14 +227,14 @@ public:
|
|||
Vertex_other, Halfedge_other, Face_base>;
|
||||
};
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_extended_dcel() {}
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
virtual ~Arr_extended_dcel() {}
|
||||
};
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -62,24 +62,24 @@ private:
|
|||
enum {MIN_REV_MAP_SIZE = 32};
|
||||
|
||||
public:
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
Arr_face_index_map() :
|
||||
Base(),
|
||||
n_faces(0),
|
||||
rev_map(MIN_REV_MAP_SIZE)
|
||||
{}
|
||||
|
||||
/*! Constructor with an associated arrangement. */
|
||||
/*! constructs from an associated arrangement. */
|
||||
Arr_face_index_map(const Base_aos& arr) :
|
||||
Base(const_cast<Base_aos&>(arr))
|
||||
{ _init(); }
|
||||
|
||||
/*! Copy constructor. */
|
||||
/*! constructs copy. */
|
||||
Arr_face_index_map(const Self& other) :
|
||||
Base(const_cast<Base_aos&>(*(other.arrangement())))
|
||||
{ _init(); }
|
||||
|
||||
/*! Assignment operator. */
|
||||
/*! assigns. */
|
||||
Self& operator= (const Self& other) {
|
||||
if (this == &other) return (*this);
|
||||
|
||||
|
|
@ -89,13 +89,13 @@ public:
|
|||
return (*this);
|
||||
}
|
||||
|
||||
/*! Get the index of a given face.
|
||||
/*! obtains the index of a given face.
|
||||
* \param f A handle to the face.
|
||||
* \pre f is a valid face in the arrangement.
|
||||
*/
|
||||
unsigned int operator[](Face_handle f) const { return (index_map[f]); }
|
||||
|
||||
/*! Get the face given its index.
|
||||
/*! obtains the face given its index.
|
||||
* \param i The index of the face.
|
||||
* \pre i is less than the number of faces in the arrangement.
|
||||
*/
|
||||
|
|
@ -107,27 +107,27 @@ public:
|
|||
/// \name Notification functions, to keep the mapping up-to-date.
|
||||
//@{
|
||||
|
||||
/*! Update the mapping after the arrangement has been assigned with another
|
||||
/*! updates the mapping after the arrangement has been assigned with another
|
||||
* arrangement.
|
||||
*/
|
||||
virtual void after_assign() override { _init(); }
|
||||
|
||||
/*! Update the mapping after the arrangement is cleared.
|
||||
/*! updates the mapping after the arrangement is cleared.
|
||||
*/
|
||||
virtual void after_clear() override { _init(); }
|
||||
|
||||
/*! Update the mapping after attaching to a new arrangement.
|
||||
/*! updates the mapping after attaching to a new arrangement.
|
||||
*/
|
||||
virtual void after_attach() override { _init(); }
|
||||
|
||||
/*! Update the mapping after detaching the arrangement.
|
||||
/*! updates the mapping after detaching the arrangement.
|
||||
*/
|
||||
virtual void after_detach() override {
|
||||
n_faces = 0;
|
||||
index_map.clear();
|
||||
}
|
||||
|
||||
/*! Update the mapping after the creation of a new face is split from another
|
||||
/*! updates the mapping after the creation of a new face is split from another
|
||||
* face.
|
||||
* \param f A handle to the existing face.
|
||||
* \param new_f A handle to the newly created face.
|
||||
|
|
@ -147,7 +147,7 @@ public:
|
|||
rev_map[n_faces - 1] = new_f;
|
||||
}
|
||||
|
||||
/*! Update the mapping before the merge of two faces.
|
||||
/*! updates the mapping before the merge of two faces.
|
||||
* \param f1 A handle to the face that is going to remain.
|
||||
* \param f2 A handle to the face that is about to be removed.
|
||||
*/
|
||||
|
|
@ -181,7 +181,7 @@ public:
|
|||
//@}
|
||||
|
||||
private:
|
||||
/*! Initialize the map for the given arrangement. */
|
||||
/*! initializes the map for the given arrangement. */
|
||||
void _init() {
|
||||
// Get the number of faces and allocate the reverse map accordingly.
|
||||
n_faces = static_cast<unsigned int>(this->arrangement()->number_of_faces());
|
||||
|
|
@ -206,7 +206,7 @@ private:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Get the index property-map function. Provided so that boost is able to
|
||||
/*! obtains the index property-map function. Provided so that boost is able to
|
||||
* access the Arr_face_index_map above.
|
||||
* \param index_map The index map.
|
||||
* \param f A face handle.
|
||||
|
|
@ -217,7 +217,7 @@ unsigned int get(const CGAL::Arr_face_index_map<Arrangement>& index_map,
|
|||
typename Arrangement::Face_handle f)
|
||||
{ return (index_map[f]); }
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#include <CGAL/enable_warnings.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -80,12 +80,12 @@ public:
|
|||
const Self * m_traits;
|
||||
|
||||
public:
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Less_xy_2(const Self * traits) : m_traits(traits) {}
|
||||
|
||||
/*! Compare two points lexigoraphically: by x, then by y.
|
||||
/*! compares two points lexigoraphically: by x, then by y.
|
||||
* We actually reversing the order, so x <--> y.
|
||||
* \param p1 the first endpoint directional point.
|
||||
* \param p2 the second endpoint directional point.
|
||||
|
|
@ -120,14 +120,12 @@ public:
|
|||
const Self * m_traits;
|
||||
|
||||
public:
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Less_yx_2(const Self * traits) : m_traits(traits) {}
|
||||
|
||||
|
||||
/*! Compare two points lexigoraphically: by y, then by x.
|
||||
/*! compares two points lexigoraphically: by y, then by x.
|
||||
* We actually reversing the order, so x <--> y.
|
||||
* \param p1 the first endpoint directional point.
|
||||
* \param p2 the second endpoint directional point.
|
||||
|
|
@ -160,12 +158,12 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Orientation_2 (const Self * traits) : m_traits(traits) {}
|
||||
|
||||
/*! Checks the orientation between three points.
|
||||
/*! checks the orientation between three points.
|
||||
* We actually reversing the order, so x <--> y.
|
||||
* \param p
|
||||
* \param q
|
||||
|
|
@ -231,7 +229,6 @@ public:
|
|||
|
||||
Compare_y_2 compare_y_2_object() const {return Base::compare_x_2_object(); }
|
||||
|
||||
|
||||
/*! A functor that compares two points by x coordinate.
|
||||
*/
|
||||
class Compare_x_2
|
||||
|
|
@ -241,14 +238,12 @@ public:
|
|||
const Self * m_traits;
|
||||
|
||||
public:
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Compare_x_2(const Self * traits) : m_traits(traits) {}
|
||||
|
||||
|
||||
/*! Compare two points by y coordinate.
|
||||
/*! compares two points by y coordinate.
|
||||
* We actually reversing the order, so x <--> y.
|
||||
* \param p1 the first endpoint directional point.
|
||||
* \param p2 the second endpoint directional point.
|
||||
|
|
@ -388,7 +383,7 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Less_xy_2(const Self * traits) : m_traits(traits) {}
|
||||
|
|
@ -429,7 +424,7 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Less_yx_2(const Self * traits) : m_traits(traits) {}
|
||||
|
|
@ -467,7 +462,7 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Orientation_2 (const Self * traits) : m_traits(traits) {}
|
||||
|
|
@ -549,7 +544,7 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor
|
||||
/*! constructs
|
||||
* \param traits the traits (in case it has state)
|
||||
*/
|
||||
Compare_x_2(const Self * traits) : m_traits(traits) {}
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -55,13 +55,13 @@ private:
|
|||
FT m_c;
|
||||
|
||||
public:
|
||||
/*! Default Constructor */
|
||||
/*! constructs default */
|
||||
Arr_plane_3() : m_a(0), m_b(0), m_c(0) {}
|
||||
|
||||
/*! Constructor */
|
||||
/*! constructs */
|
||||
Arr_plane_3(int a, int b, int c) : m_a(a), m_b(b), m_c(c) {}
|
||||
|
||||
/*! Constructor */
|
||||
/*! constructs */
|
||||
Arr_plane_3(typename Kernel::Plane_3 p)
|
||||
{
|
||||
CGAL_precondition_code(Kernel kernel;);
|
||||
|
|
@ -71,7 +71,7 @@ public:
|
|||
m_a = p.a(); m_b = p.b(); m_c = p.c() ;
|
||||
}
|
||||
|
||||
/*! Constructor */
|
||||
/*! constructs */
|
||||
Arr_plane_3(const Point_3 & p, const Point_3 & r)
|
||||
{
|
||||
FT prx = r.x() - p.x();
|
||||
|
|
@ -82,16 +82,16 @@ public:
|
|||
m_c = r.x() * pry - prx * r.y();
|
||||
}
|
||||
|
||||
/*! Obtain the x coefficient */
|
||||
/*! obtains the x coefficient */
|
||||
const FT & a() const { return m_a; }
|
||||
|
||||
/*! Obtain the y coefficient */
|
||||
/*! obtains the y coefficient */
|
||||
const FT & b() const { return m_b; }
|
||||
|
||||
/*! Obtain the z coefficient */
|
||||
/*! obtains the z coefficient */
|
||||
const FT & c() const { return m_c; }
|
||||
|
||||
/*! Obtain the i-th coefficient of the plane
|
||||
/*! obtains the i-th coefficient of the plane
|
||||
* \param i the index of the coefficient
|
||||
* \return the i-th coefficient
|
||||
*/
|
||||
|
|
@ -108,14 +108,14 @@ public:
|
|||
(c() == plane.c()));
|
||||
}
|
||||
|
||||
/*! Convert to kernel's plane */
|
||||
/*! converts to kernel's plane */
|
||||
operator typename Kernel::Plane_3 () const
|
||||
{
|
||||
Kernel kernel;
|
||||
return kernel.construct_plane_3_object() (m_a, m_b, m_c, 0);
|
||||
}
|
||||
|
||||
/*! Compute the image point of the projection of p under an affine
|
||||
/*! computes the image point of the projection of p under an affine
|
||||
* transformation, which maps the plane onto the xy-plane, with the
|
||||
* z-coordinate removed.
|
||||
* \param p the point
|
||||
|
|
@ -139,7 +139,7 @@ public:
|
|||
return Point_2(x, y);
|
||||
}
|
||||
|
||||
/*! Compute a 3d point p_3 coincident to the plane, such that the image point
|
||||
/*! computes a 3d point p_3 coincident to the plane, such that the image point
|
||||
* of the projection of p_3 under an affine transformation, which maps the
|
||||
* plane onto the a given axis-parallel plane is a given 2d point.
|
||||
* \param p_2 the image point
|
||||
|
|
@ -183,7 +183,7 @@ public:
|
|||
return p_3;
|
||||
}
|
||||
|
||||
/*! Determine the relative position of a point and the plane
|
||||
/*! determines the relative position of a point and the plane
|
||||
* \param p the point
|
||||
* \return ON_ORIENTED_BOUNDARY, ON_POSITIVE_SIDE, or ON_NEGATIVE_SIDE,
|
||||
* determined by the position of p relative to the oriented plane.
|
||||
|
|
@ -194,7 +194,7 @@ public:
|
|||
}
|
||||
};
|
||||
|
||||
/*! Intersect 2 planes
|
||||
/*! intersects 2 planes
|
||||
* \param plane1 the first plane
|
||||
* \param plane2 the second plane
|
||||
* \return a variant that represents the intersection. It wraps a line of
|
||||
|
|
@ -244,7 +244,7 @@ intersect(const Arr_plane_3<Kernel> & plane1,
|
|||
return Intersection_result(plane1);
|
||||
}
|
||||
|
||||
/*! Compute the image point of the projection of p under an affine
|
||||
/*! computes the image point of the projection of p under an affine
|
||||
* transformation, which maps the plane onto the xy-plane, with the
|
||||
* z-coordinate removed.
|
||||
* \param plane the plane
|
||||
|
|
@ -259,7 +259,7 @@ construct_projected_xy_point(const Arr_plane_3<Kernel> & plane,
|
|||
return plane.to_2d(p);
|
||||
}
|
||||
|
||||
/*! Export a plane to an output stream
|
||||
/*! exports a plane to an output stream
|
||||
* \param os the output stream
|
||||
* \param plane the plane
|
||||
* \return the output stream
|
||||
|
|
@ -272,6 +272,6 @@ inline std::ostream & operator<<(std::ostream & os,
|
|||
return os;
|
||||
}
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ public:
|
|||
Algebraic x; // The x-coordinate.
|
||||
Algebraic y; // The y-coordinate.
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
Intersection_point (const Algebraic& _s, const Algebraic& _t,
|
||||
const Algebraic& _x, const Algebraic& _y) :
|
||||
s(_s), t(_t),
|
||||
|
|
@ -124,7 +124,7 @@ private:
|
|||
app_y (0)
|
||||
{}
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
My_point_2 (typename Parameter_list::const_iterator it,
|
||||
const Algebraic& _x, const Algebraic& _y) :
|
||||
prm_it (it),
|
||||
|
|
@ -134,7 +134,7 @@ private:
|
|||
app_y (CGAL::to_double(_y))
|
||||
{}
|
||||
|
||||
/*! Get the parameter value. */
|
||||
/*! obtains the parameter value. */
|
||||
const Algebraic& parameter () const
|
||||
{
|
||||
return (*prm_it);
|
||||
|
|
@ -177,7 +177,7 @@ private:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor. */
|
||||
/*! constructs. */
|
||||
_Bezier_cache ()
|
||||
{}
|
||||
|
||||
|
|
@ -869,6 +869,6 @@ _Bezier_cache<NtTraits>::_compute_resultant
|
|||
return (det);
|
||||
}
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -105,7 +105,7 @@ private:
|
|||
|
||||
public:
|
||||
|
||||
/*! Default constructor. */
|
||||
/*! constructs default. */
|
||||
_Bezier_curve_2_rep () :
|
||||
_no_self_inter (true),
|
||||
p_polyX(nullptr),
|
||||
|
|
@ -114,7 +114,7 @@ public:
|
|||
p_normY(nullptr)
|
||||
{}
|
||||
|
||||
/*! Copy constructor (isn't really used). */
|
||||
/*! constructs copy (isn't really used). */
|
||||
_Bezier_curve_2_rep (const _Bezier_curve_2_rep& other) :
|
||||
_ctrl_pts(other._ctrl_pts),
|
||||
_bbox(other._bbox),
|
||||
|
|
@ -134,8 +134,7 @@ public:
|
|||
p_normY = new Integer(*(other.p_normY));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Constructor from a given range of control points.
|
||||
/*! constructs from a given range of control points.
|
||||
* \param pts_begin An iterator pointing to the first point in the range.
|
||||
* \param pts_end A past-the-end iterator for the range.
|
||||
* \pre The value-type of the input iterator must be Rat_kernel::Point_2.
|
||||
|
|
@ -206,7 +205,7 @@ public:
|
|||
_no_self_inter = ! bound_tr.may_have_self_intersections (_ctrl_pts);
|
||||
}
|
||||
|
||||
/*! Destructor. */
|
||||
/*! destructs. */
|
||||
~_Bezier_curve_2_rep ()
|
||||
{
|
||||
if (p_polyX != nullptr)
|
||||
|
|
@ -222,14 +221,14 @@ public:
|
|||
/// \name Access the polynomials (lazily evaluated).
|
||||
//@{
|
||||
|
||||
/*! Check if the polynomials are already constructed. */
|
||||
/*! checks if the polynomials are already constructed. */
|
||||
bool has_polynomials () const
|
||||
{
|
||||
return (p_polyX != nullptr && p_normX != nullptr &&
|
||||
p_polyY != nullptr && p_normY != nullptr);
|
||||
}
|
||||
|
||||
/*! Get the polynomial X(t). */
|
||||
/*! obtains the polynomial X(t). */
|
||||
const Polynomial& x_polynomial () const
|
||||
{
|
||||
if (p_polyX == nullptr)
|
||||
|
|
@ -238,7 +237,7 @@ public:
|
|||
return (*p_polyX);
|
||||
}
|
||||
|
||||
/*! Get the normalizing factor for X(t). */
|
||||
/*! obtains the normalizing factor for X(t). */
|
||||
const Integer& x_norm () const
|
||||
{
|
||||
if (p_normX == nullptr)
|
||||
|
|
@ -247,7 +246,7 @@ public:
|
|||
return (*p_normX);
|
||||
}
|
||||
|
||||
/*! Get the polynomial Y(t). */
|
||||
/*! obtains the polynomial Y(t). */
|
||||
const Polynomial& y_polynomial () const
|
||||
{
|
||||
if (p_polyY == nullptr)
|
||||
|
|
@ -256,7 +255,7 @@ public:
|
|||
return (*p_polyY);
|
||||
}
|
||||
|
||||
/*! Get the normalizing factor for Y(t). */
|
||||
/*! obtains the normalizing factor for Y(t). */
|
||||
const Integer& y_norm () const
|
||||
{
|
||||
if (p_normY == nullptr)
|
||||
|
|
@ -268,14 +267,12 @@ public:
|
|||
|
||||
private:
|
||||
|
||||
/*!
|
||||
* Construct the representation of X(t) and Y(t).
|
||||
/*! construct the representation of X(t) and Y(t).
|
||||
* The function is declared as "const" as it changes only mutable members.
|
||||
*/
|
||||
void _construct_polynomials () const;
|
||||
|
||||
/*!
|
||||
* Compute the value of n! / (j! k! (n-k-j)!).
|
||||
/*! computes the value of n! / (j! k! (n-k-j)!).
|
||||
*/
|
||||
Integer _choose (int n, int j, int k) const;
|
||||
|
||||
|
|
@ -324,22 +321,19 @@ public:
|
|||
|
||||
public:
|
||||
|
||||
/*!
|
||||
* Default constructor.
|
||||
/*!constructs default.
|
||||
*/
|
||||
_Bezier_curve_2 () :
|
||||
Bcv_handle (Bcv_rep())
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Copy constructor.
|
||||
/*! constructs copy.
|
||||
*/
|
||||
_Bezier_curve_2 (const Self& bc) :
|
||||
Bcv_handle (bc)
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Constructor from a given range of control points.
|
||||
/*! constructs from a given range of control points.
|
||||
* \param pts_begin An iterator pointing to the first point in the range.
|
||||
* \param pts_end A past-the-end iterator for the range.
|
||||
* \pre The value-type of the input iterator must be Rat_kernel::Point_2.
|
||||
|
|
@ -350,8 +344,7 @@ public:
|
|||
Bcv_handle (Bcv_rep (pts_begin, pts_end))
|
||||
{}
|
||||
|
||||
/*!
|
||||
* Assignment operator.
|
||||
/*! assigns.
|
||||
*/
|
||||
Self& operator= (const Self& bc)
|
||||
{
|
||||
|
|
@ -362,56 +355,49 @@ public:
|
|||
return (*this);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get a unique curve ID (based on the actual representation pointer).
|
||||
/*! obtains a unique curve ID (based on the actual representation pointer).
|
||||
*/
|
||||
size_t id () const
|
||||
{
|
||||
return (reinterpret_cast<size_t> (this->ptr()));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get the polynomial for the x-coordinates of the curve.
|
||||
/*! obtains the polynomial for the x-coordinates of the curve.
|
||||
*/
|
||||
const Polynomial& x_polynomial () const
|
||||
{
|
||||
return (this->_rep().x_polynomial());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get the normalizing factor for the x-coordinates.
|
||||
/*! obtains the normalizing factor for the x-coordinates.
|
||||
*/
|
||||
const Integer& x_norm () const
|
||||
{
|
||||
return (this->_rep().x_norm());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get the polynomial for the y-coordinates of the curve.
|
||||
/*! obtains the polynomial for the y-coordinates of the curve.
|
||||
*/
|
||||
const Polynomial& y_polynomial () const
|
||||
{
|
||||
return (this->_rep().y_polynomial());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get the normalizing factor for the y-coordinates.
|
||||
/*! obtains the normalizing factor for the y-coordinates.
|
||||
*/
|
||||
const Integer& y_norm () const
|
||||
{
|
||||
return (this->_rep().y_norm());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get the number of control points inducing the Bezier curve.
|
||||
/*! obtains the number of control points inducing the Bezier curve.
|
||||
*/
|
||||
unsigned int number_of_control_points () const
|
||||
{
|
||||
return static_cast<unsigned int>((this->_rep()._ctrl_pts.size()));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get the i'th control point.
|
||||
/*! obtains the i'th control point.
|
||||
* \pre i must be between 0 and n - 1, where n is the number of control
|
||||
* points.
|
||||
*/
|
||||
|
|
@ -422,46 +408,40 @@ public:
|
|||
return ((this->_rep()._ctrl_pts)[i]);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get an iterator for the first control point.
|
||||
/*! obtains an iterator for the first control point.
|
||||
*/
|
||||
Control_point_iterator control_points_begin () const
|
||||
{
|
||||
return (this->_rep()._ctrl_pts.begin());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Get a past-the-end iterator for control points.
|
||||
/*! obtains a past-the-end iterator for control points.
|
||||
*/
|
||||
Control_point_iterator control_points_end () const
|
||||
{
|
||||
return (this->_rep()._ctrl_pts.end());
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check if both curve handles refer to the same object.
|
||||
/*! checks if both curve handles refer to the same object.
|
||||
*/
|
||||
bool is_same (const Self& bc) const
|
||||
{
|
||||
return (this->identical (bc));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Compute a point of the Bezier curve given a rational t-value.
|
||||
/*! computes a point of the Bezier curve given a rational t-value.
|
||||
* \param t The given t-value.
|
||||
* \return The point B(t).
|
||||
*/
|
||||
Rat_point_2 operator() (const Rational& t) const;
|
||||
|
||||
/*!
|
||||
* Compute a point of the Bezier curve given an algebraic t-value.
|
||||
/*! computes a point of the Bezier curve given an algebraic t-value.
|
||||
* \param t The given t-value.
|
||||
* \return The point B(t).
|
||||
*/
|
||||
Alg_point_2 operator() (const Algebraic& t) const;
|
||||
|
||||
/*!
|
||||
* Sample a portion of the curve (for drawing purposes, etc.).
|
||||
/*! samples a portion of the curve (for drawing purposes, etc.).
|
||||
* \param t_start The t-value to start with.
|
||||
* \param t_end The t-value to end at.
|
||||
* \param n_samples The required number of samples.
|
||||
|
|
@ -507,8 +487,7 @@ public:
|
|||
return (oi);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Compute all parameter values t such that the x-coordinate of B(t) is x0.
|
||||
/*! computes all parameter values t such that the x-coordinate of B(t) is x0.
|
||||
* Note that the function does not return only values between 0 and 1, so
|
||||
* the output t-values may belong to the imaginary continuation of the curve.
|
||||
* \param x0 The given x-coordinate.
|
||||
|
|
@ -525,8 +504,7 @@ public:
|
|||
oi));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Compute all parameter values t such that the y-coordinate of B(t) is y0.
|
||||
/*! computes all parameter values t such that the y-coordinate of B(t) is y0.
|
||||
* Note that the function does not return only values between 0 and 1, so
|
||||
* the output t-values may belong to the imaginary continuation of the curve.
|
||||
* \param y0 The given y-coordinate.
|
||||
|
|
@ -542,21 +520,18 @@ public:
|
|||
oi));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check if the two curves have the same support.
|
||||
/*! checks if the two curves have the same support.
|
||||
*/
|
||||
bool has_same_support (const Self& bc) const;
|
||||
|
||||
/*!
|
||||
* Get the bounding box of the curve.
|
||||
/*! obtains the bounding box of the curve.
|
||||
*/
|
||||
const Bbox_2& bbox () const
|
||||
{
|
||||
return (this->_rep()._bbox);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Check if the curve contains not self intersections.
|
||||
/*! checks if the curve contains not self intersections.
|
||||
* Note that there may not be any self intersections even if the
|
||||
* function returns true (but not vice versa).
|
||||
*/
|
||||
|
|
@ -578,8 +553,7 @@ private:
|
|||
return (*(this->ptr()));
|
||||
}
|
||||
|
||||
/*!
|
||||
* Compute all parameter values t, such that P(t) = val.
|
||||
/*! computes all parameter values t, such that P(t) = val.
|
||||
* \param poly The polynomial.
|
||||
* \param norm Its normalizing factor.
|
||||
* \param val The required value.
|
||||
|
|
@ -618,8 +592,7 @@ private:
|
|||
}
|
||||
};
|
||||
|
||||
/*!
|
||||
* Exporter for Bezier curves.
|
||||
/*! exports a Bezier curves.
|
||||
*/
|
||||
template <class Rat_kernel, class Alg_kernel, class Nt_traits,
|
||||
class Bounding_traits>
|
||||
|
|
@ -638,8 +611,7 @@ operator<< (std::ostream& os,
|
|||
return (os);
|
||||
}
|
||||
|
||||
/*!
|
||||
* Importer for Bezier curves.
|
||||
/*! imports a Bezier curves.
|
||||
*/
|
||||
template <class Rat_kernel, class Alg_kernel, class Nt_traits,
|
||||
class Bounding_traits>
|
||||
|
|
@ -947,6 +919,6 @@ bool _Bezier_curve_2<RatKer, AlgKer, NtTrt, BndTrt>::has_same_support
|
|||
return (true);
|
||||
}
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ private:
|
|||
|
||||
public:
|
||||
|
||||
/*! Constructor, given an exact algebraic representation. */
|
||||
/*! constructs, given an exact algebraic representation. */
|
||||
Originator (const Curve_2& c, const Algebraic& t) :
|
||||
_curve (c),
|
||||
_xid (0),
|
||||
|
|
@ -104,7 +104,7 @@ private:
|
|||
set_parameter (t);
|
||||
}
|
||||
|
||||
/*! Constructor, given an exact algebraic representation. */
|
||||
/*! constructs, given an exact algebraic representation. */
|
||||
Originator (const Curve_2& c, unsigned int xid,
|
||||
const Algebraic& t) :
|
||||
_curve (c),
|
||||
|
|
@ -114,7 +114,7 @@ private:
|
|||
set_parameter (t);
|
||||
}
|
||||
|
||||
/*! Constructor with bounding information and no exact representation. */
|
||||
/*! constructs with bounding information and no exact representation. */
|
||||
Originator (const Curve_2& c, const Bez_point_bound& bpb) :
|
||||
_curve (c),
|
||||
_xid (0),
|
||||
|
|
@ -122,7 +122,7 @@ private:
|
|||
p_t (nullptr)
|
||||
{}
|
||||
|
||||
/*! Constructor with bounding information and no exact representation. */
|
||||
/*! constructs with bounding information and no exact representation. */
|
||||
Originator (const Curve_2& c, unsigned int xid,
|
||||
const Bez_point_bound& bpb) :
|
||||
_curve (c),
|
||||
|
|
@ -174,19 +174,19 @@ private:
|
|||
return (*this);
|
||||
}
|
||||
|
||||
/*! Get the originating curve. */
|
||||
/*! obtains the originating curve. */
|
||||
const Curve_2& curve () const
|
||||
{
|
||||
return (_curve);
|
||||
}
|
||||
|
||||
/*! Get the serial number of the originating x-monotone curve. */
|
||||
/*! obtains the serial number of the originating x-monotone curve. */
|
||||
unsigned int xid () const
|
||||
{
|
||||
return (_xid);
|
||||
}
|
||||
|
||||
/*! Get the bounding information. */
|
||||
/*! obtains the bounding information. */
|
||||
const Bez_point_bound& point_bound () const
|
||||
{
|
||||
return (_bpb);
|
||||
|
|
@ -264,7 +264,7 @@ private:
|
|||
BoundNT t_min; /*!< Minimal parameter value. */
|
||||
BoundNT t_max; /*!< Maximal parameter value. */
|
||||
|
||||
/*! Constructor given control points an a t-range. */
|
||||
/*! constructs given control points an a t-range. */
|
||||
Subcurve (const Control_points& _ctrl,
|
||||
const BoundNT& _tmin,
|
||||
const BoundNT& _tmax) :
|
||||
|
|
@ -273,7 +273,7 @@ private:
|
|||
t_max (_tmax)
|
||||
{}
|
||||
|
||||
/*! Constructor given a t-range. */
|
||||
/*! constructs given a t-range. */
|
||||
Subcurve (const BoundNT& _tmin,
|
||||
const BoundNT& _tmax) :
|
||||
t_min (_tmin),
|
||||
|
|
@ -924,7 +924,7 @@ public:
|
|||
_rep()._bbox = bbox;
|
||||
}
|
||||
|
||||
/*! Get the bounding box of the point. */
|
||||
/*! obtains the bounding box of the point. */
|
||||
void get_bbox (typename Bounding_traits::NT& min_x,
|
||||
typename Bounding_traits::NT& min_y,
|
||||
typename Bounding_traits::NT& max_x,
|
||||
|
|
@ -938,13 +938,13 @@ public:
|
|||
|
||||
private:
|
||||
|
||||
/*! Get the representation (const version). */
|
||||
/*! obtains the representation (const version). */
|
||||
inline const Bpt_rep& _rep () const
|
||||
{
|
||||
return (*(this->ptr()));
|
||||
}
|
||||
|
||||
/*! Get the representation (non-const version). */
|
||||
/*! obtains the representation (non-const version). */
|
||||
inline Bpt_rep& _rep ()
|
||||
{
|
||||
return (*(this->ptr()));
|
||||
|
|
@ -1701,6 +1701,6 @@ void _Bezier_point_2_rep<RatKer, AlgKer, NtTrt, BndTrt>::_make_exact
|
|||
CGAL_error();
|
||||
}
|
||||
|
||||
} //namespace CGAL
|
||||
} // namespace CGAL
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue