Skip to content

Commit

Permalink
Changed how shapes are broken up
Browse files Browse the repository at this point in the history
The output now minimizes hole count and maximizes shape count.

Other changes:
- fixes bugs in polygon rasterizer
- added a few tests and test program features
- updated documentation to use features of newer version of Breathe
  • Loading branch information
Rouslan committed Jun 1, 2024
1 parent dc67be9 commit ab03178
Show file tree
Hide file tree
Showing 19 changed files with 761 additions and 438 deletions.
2 changes: 1 addition & 1 deletion LICENSE.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Copyright 2022-2023 Rouslan Korneychuk
Copyright 2022-2024 Rouslan Korneychuk

Permission is hereby granted, free of charge, to any person or organization
obtaining a copy of the software and accompanying documentation covered by
Expand Down
1 change: 1 addition & 0 deletions doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,5 @@

breathe_default_project = 'polyops'
breathe_show_include = False
breathe_use_cpp_namespace = True

56 changes: 29 additions & 27 deletions doc/cpp/base.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,121 +2,123 @@ poly_ops/base.hpp
=================


.. cpp:namespace:: poly_ops

Concepts
-----------

.. doxygenconcept:: poly_ops::coordinate
.. doxygenconcept:: coordinate

-----------------------------

.. doxygenconcept:: poly_ops::point
.. doxygenconcept:: point

-----------------------------

.. doxygenconcept:: poly_ops::point_range
.. doxygenconcept:: point_range

-----------------------------

.. doxygenconcept:: poly_ops::point_range_range
.. doxygenconcept:: point_range_range

-----------------------------

.. doxygenconcept:: poly_ops::point_range_or_range_range
.. doxygenconcept:: point_range_or_range_range


Types
------------------

.. doxygentypedef:: poly_ops::long_coord_t
.. doxygentypedef:: long_coord_t

-----------------------------

.. doxygentypedef:: poly_ops::real_coord_t
.. doxygentypedef:: real_coord_t

-----------------------------

.. doxygenstruct:: poly_ops::point_ops
.. doxygenstruct:: point_ops

-----------------------------

.. doxygenstruct:: poly_ops::coord_ops
.. doxygenstruct:: coord_ops
:members:
:undoc-members:

-----------------------------

.. doxygenstruct:: poly_ops::point_t
.. doxygenstruct:: point_t
:members:
:undoc-members:

-----------------------------

.. doxygenclass:: poly_ops::winding_dir_sink
.. doxygenclass:: winding_dir_sink
:members:
:undoc-members:


Functions
----------------

.. doxygenfunction:: poly_ops::operator+(const point_t<T>&,const point_t<U>&)
.. doxygenfunction:: operator+(const point_t<T>&,const point_t<U>&)

-----------------------------

.. doxygenfunction:: poly_ops::operator-(const point_t<T>&,const point_t<U>&)
.. doxygenfunction:: operator-(const point_t<T>&,const point_t<U>&)

-----------------------------

.. doxygenfunction:: poly_ops::operator*(const point_t<T>&,const point_t<U>&)
.. doxygenfunction:: operator*(const point_t<T>&,const point_t<U>&)

-----------------------------

.. doxygenfunction:: poly_ops::operator*(const point_t<T>&,U)
.. doxygenfunction:: operator*(const point_t<T>&,U)

-----------------------------

.. doxygenfunction:: poly_ops::operator*(T,const point_t<U>&)
.. doxygenfunction:: operator*(T,const point_t<U>&)

-----------------------------

.. doxygenfunction:: poly_ops::operator/(const point_t<T>&,const point_t<U>&)
.. doxygenfunction:: operator/(const point_t<T>&,const point_t<U>&)

-----------------------------

.. doxygenfunction:: poly_ops::operator==(const point_t<T>&,const point_t<T>&)
.. doxygenfunction:: operator==(const point_t<T>&,const point_t<T>&)

-----------------------------

.. doxygenfunction:: poly_ops::operator!=(const point_t<T>&,const point_t<T>&)
.. doxygenfunction:: operator!=(const point_t<T>&,const point_t<T>&)

-----------------------------

.. doxygenfunction:: poly_ops::vdot
.. doxygenfunction:: vdot

-----------------------------

.. doxygenfunction:: poly_ops::square
.. doxygenfunction:: square

-----------------------------

.. doxygenfunction:: poly_ops::vcast
.. doxygenfunction:: vcast

-----------------------------

.. doxygenfunction:: poly_ops::vround
.. doxygenfunction:: vround

-----------------------------

.. doxygenfunction:: poly_ops::vmag
.. doxygenfunction:: vmag

-----------------------------

.. doxygenfunction:: poly_ops::vangle
.. doxygenfunction:: vangle

-----------------------------

.. doxygenfunction:: poly_ops::triangle_winding
.. doxygenfunction:: triangle_winding

-----------------------------

.. doxygenfunction:: poly_ops::winding_dir
.. doxygenfunction:: winding_dir
38 changes: 20 additions & 18 deletions doc/cpp/clip.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,85 +2,87 @@ poly_ops/clip.hpp
=====================


.. cpp:namespace:: poly_ops

Types
------------------

.. doxygenclass:: poly_ops::i_point_tracker
.. doxygenclass:: i_point_tracker
:members:
:undoc-members:

-----------------------------

.. doxygenconcept:: poly_ops::point_tracker
.. doxygenconcept:: point_tracker

-----------------------------

.. doxygenenum:: poly_ops::bool_op
.. doxygenenum:: bool_op

-----------------------------

.. doxygenenum:: poly_ops::bool_set
.. doxygenenum:: bool_set

-----------------------------

.. doxygenclass:: poly_ops::proto_loop_iterator
.. doxygenclass:: proto_loop_iterator

-----------------------------

.. doxygenclass:: poly_ops::temp_polygon_proxy
.. doxygenclass:: temp_polygon_proxy
:members:
:undoc-members:

-----------------------------

.. doxygentypedef:: poly_ops::borrowed_temp_polygon_tree_range
.. doxygentypedef:: borrowed_temp_polygon_tree_range

-----------------------------

.. doxygentypedef:: poly_ops::borrowed_temp_polygon_range
.. doxygentypedef:: borrowed_temp_polygon_range

-----------------------------

.. doxygentypedef:: poly_ops::temp_polygon_tree_range
.. doxygentypedef:: temp_polygon_tree_range

-----------------------------

.. doxygentypedef:: poly_ops::temp_polygon_range
.. doxygentypedef:: temp_polygon_range

-----------------------------

.. doxygenclass:: poly_ops::clipper
.. doxygenclass:: clipper
:members:
:undoc-members:

-----------------------------

.. doxygenclass:: poly_ops::tclipper
.. doxygenclass:: tclipper
:members:
:undoc-members:


Functions
----------------

.. doxygenfunction:: poly_ops::union_op(Input&&,std::pmr::memory_resource*)
.. doxygenfunction:: union_op(Input&&,std::pmr::memory_resource*)

-----------------------------

.. doxygenfunction:: poly_ops::union_op(Input&&,Tracker&&,std::pmr::memory_resource*)
.. doxygenfunction:: union_op(Input&&,Tracker&&,std::pmr::memory_resource*)

-----------------------------

.. doxygenfunction:: poly_ops::normalize_op(Input&&,std::pmr::memory_resource*)
.. doxygenfunction:: normalize_op(Input&&,std::pmr::memory_resource*)

-----------------------------

.. doxygenfunction:: poly_ops::normalize_op(Input&&,Tracker&&,std::pmr::memory_resource*)
.. doxygenfunction:: normalize_op(Input&&,Tracker&&,std::pmr::memory_resource*)

-----------------------------

.. doxygenfunction:: poly_ops::boolean_op(SInput&&,CInput&&,bool_op,std::pmr::memory_resource*)
.. doxygenfunction:: boolean_op(SInput&&,CInput&&,bool_op,std::pmr::memory_resource*)

-----------------------------

.. doxygenfunction:: poly_ops::boolean_op(SInput&&,CInput&&,bool_op,Tracker&&,std::pmr::memory_resource*)
.. doxygenfunction:: boolean_op(SInput&&,CInput&&,bool_op,Tracker&&,std::pmr::memory_resource*)
Loading

0 comments on commit ab03178

Please sign in to comment.