7bde1ec6f5
pydashing: Add PSMatrix, Dash and extend HatchPattern.
2025-06-09 10:21:23 +02:00
6e2253948b
dashing::Dash: provide constructor
2025-06-09 10:20:43 +02:00
a0fe09e00a
my somewhat arty scriptsplitall.py
2025-06-08 20:23:45 +02:00
d24b15172b
pydashing: It's useful now!
2025-06-08 18:02:43 +02:00
acfd505b3d
Fix incorrect dash patterns that start in gaps
...
I noticed some (incorrect dash patterns)[https://social.afront.org/deck/@stylus/114647763027177789 ]
this fixes them by correctly advancing during a skip, refactoring
the code slightly to make it easier to think about.
2025-06-08 18:02:21 +02:00
a55d21398a
implement pythonmod closer to how python does it
...
I briefly suspected my implementation of pythonmod when debugging
an incorrect result. It was not the cause, but I might as well
make the structure of the function match current cpython.
2025-06-08 18:00:59 +02:00
a9ca7cbcda
Document the hatch pattern syntax a bit
2025-06-08 17:59:49 +02:00
8e0b4cddf9
skeleton python build
2025-06-07 20:05:02 +02:00
cf19fe5df1
vendor pybind11
2025-06-07 20:04:41 +02:00
cae1eecc87
finish getting rid of boost
2024-12-26 20:07:33 -06:00
f52035ead1
get rid of need for boost, but require c++20
2024-12-26 20:05:58 -06:00
d456749810
Update README.md
2024-12-26 10:37:05 -06:00
4ccd38acf2
no need to link to boost random
2024-12-26 10:36:40 -06:00
987ff83c06
add openmp
2023-12-31 15:57:30 -06:00
81a8b65a93
switch to c++17 dialect
2023-12-31 15:53:06 -06:00
8a27cd336f
use LTO linking & even generate some profile-guided optimization versions
2023-12-31 15:53:06 -06:00
e916865163
get rid of an unneeded conditional (we just asserted it)
2023-12-31 15:53:01 -06:00
5437dfba75
track number of segments as a size_t
2023-12-31 15:53:01 -06:00
4dc78ca136
Optimize
...
* Assume dash patterns are all on-off(-on-off...) even though this is
not necessarily true
* now unroll the uvdraw loop 1 time so that there's no test of whether
to draw or not, and half as many 'maybe reset i' checks
2023-12-31 15:52:50 -06:00
3d739ff51f
Turn off assertions in timing builds
2023-12-21 20:54:50 -06:00
40c67baf3a
Switch data types from double to float (via a new typedef)
...
and get rid of a pessimizing std::move
2023-12-21 20:44:13 -06:00
a273f8a84a
use LTO
2023-12-21 20:33:30 -06:00
Jeff Epler
2bb91cceeb
improve documentation
...
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:13:42 -05:00
Jeff Epler
b209a5bd09
avoid winding-rule calls via function pointer
...
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:13:42 -05:00
Jeff Epler
386d98d587
additional point operators
...
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:12:58 -05:00
Jeff Epler
5167ba3dd7
simplify the way the value is returned
...
.. no need for named temporary Point
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:12:58 -05:00
Jeff Epler
68f603353a
factor out SegmentsFromFile
...
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:12:58 -05:00
Jeff Epler
ad50918ad9
Makefile: mark default rule as phony
...
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:12:58 -05:00
Jeff Epler
18d444ca66
let us build with clang
...
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:12:58 -05:00
Jeff Epler
b70d655489
Manually unroll first loop iteration, where o may be nonzero
...
.. simplifying subsequent iterations by not requiring them to account for o
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:12:57 -05:00
Jeff Epler
7adf8e24df
Don't needlessly copy pattern.dash[i]
...
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:12:57 -05:00
Jeff Epler
ea1bfeb467
Makefile: rule to do a simple benchmark with 'perf stat'
...
Signed-off-by: Jeff Epler <jepler@unpythonic.net>
2017-06-02 16:12:57 -05:00
Jeff Epler
f18e7b6713
Add a note about development status
2017-05-03 07:37:20 -05:00
Jeff Epler
2d7cb43a1d
fix a typo
2016-12-06 15:37:46 -06:00
Jeff Epler
b8445e0a7d
Fix markup error (end of bullet list)
2016-12-06 15:36:54 -06:00
Jeff Epler
b40f009bf2
stop files in data/ from appearing in language summary
2016-01-27 20:45:45 -06:00
Jeff Epler
0818899738
reserve space for segments
2016-01-27 20:44:34 -06:00
Jeff Epler
c9a7c8241e
add -x 'just exit' benchmarking mode
2016-01-27 20:44:34 -06:00
Jeff Epler
bbd13083cf
tout increased performance
2016-01-27 15:50:19 -06:00
Jeff Epler
29530a3b6d
avoid calling fabs
2015-11-06 13:48:24 -06:00
Jeff Epler
9d1843800d
indices are integral types
2015-11-06 13:33:28 -06:00
Jeff Epler
6776ea122c
avoid expensive modulo calculation
2015-11-06 13:25:08 -06:00
Jeff Epler
171c391b20
use a more typical extension for C++ header files
2015-11-02 11:35:07 -06:00
Jeff Epler
242cd9d84b
use a more typical extension for C++ source files
2015-11-02 11:35:06 -06:00
Jeff Epler
8e3f37ed7a
Update README.md
2015-10-28 15:50:49 -05:00
Jeff Epler
40d5729b74
Introduce support for different winding rules
...
This is a model which can support all OpenGL winding rules as well as
any other rule which is just a test of the winding number (if there are
any such tests that are useful).
This requires introducing a flag on Segment objects to track whether they
have been "swapped": A Segment which is not swapped has its endpoints in
the proper order to be consecutive points in a CCW-wound polygon. One
which is swapped is in the opposite order.
It is necessary to invert this flag when transforming a segment by a
transformation with a negative determinant, and when swapping the endpoints
to satisfy a sorting criterion.
2015-10-02 13:56:20 -05:00
Jeff Epler
e888bf0502
add an unoptimized target
...
.. helpful when using a debugger
2015-10-02 13:56:20 -05:00
Jeff Epler
95d7f6e683
delete commented-out code
2015-10-02 13:56:20 -05:00
Jeff Epler
7d465a3041
remove unneded include
2015-10-02 13:56:20 -05:00
Jeff Epler
fab9ebe603
introduce, use PSMatrix::determinant method
2015-10-02 13:56:20 -05:00