This is a fix for the following input (r2minpt.cin):
s -91 36 36 87
p -23 4
p -17 37
p -17 40
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
Avoid computing a predicate for the support line of a query segment,
if that segment has a common endpoint with another segment and this
endpoint also defines the vertex and also the two segments have the
same slope. In that case, the sl value should be ZERO.
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
Use the most distant point to choose segment direction in
the bisector of two segments computation.
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
These new insert functions are from the SDG L2 code and will be
useful for the test_sdg_new_range_api test for the SDG Linf code.
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
The script ipe2plg converts all paths and points
in the first page of the ipe file given as the command
line argument to the polygon .plg format of CGAL.
The result is printed to the standard output.
Use redirection to save to a .plg file.
The file ipe2plg.lua has to be put in the appropriate
place, e.g., ~/.ipe/scripts/ and here is an example use:
ipescript ipe2plg test1.ipe > test1.plg
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
This fixes the computation of neighbors for
insert_point_on_segment and is the same as the
insert_exact_point_on_segment fix.
Here are some inputs that are affected.
(5sqin.cin)
s 0 0 0 100
s 0 100 100 100
s 100 100 100 0
s 0 0 100 0
s -100 50 150 50
(lala3.cin)
s 1 2 3 2
s 13 25 13 25
s 27 24 54 24
s 43 31 43 35
s 41 51 71 51
s 57 93 57 141
s 75 117 96 117
s 143 95 143 143
s 81 162 117 162
s 101 171 101 211
s 189 156 222 156
s 219 123 219 219
s 121 199 199 199
s 229 159 229 229
s 156 186 246 186
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
I might have to do the same with insert_point_on_segment.
This fixes a bug in the validity check of diammid1.cin:
s -200 0 0 200
s 0 -200 200 0
s -200 0 0 -200
s 0 200 200 0
p 100 100
p -100 -100
p 100 -100
p -100 100
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
This fixes a bug in validity check of ipe10gperm.cin:
s 10 120 60 20
s 30 110 100 40
s 60 40 70 60
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
This avoids a ping-pong effect in the PSSP case.
It fixes the validity check of the following input br50noseg.cin:
s -50 -20 0 +30
s 0 +30 +50 -20
p -20 0
p +20 0
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
This is to fix validity checks of inputs like (rx8m8var.cin):
s -11 82 -11 4
p 58 60
p 89 1
p -11 16
s -11 16 89 1
This fixes the validity check of point t = p -11 82.
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
This is to fix validity checks of inputs like (rx8m8var.cin):
s -11 82 -11 4
p 58 60
p 89 1
p -11 16
s -11 16 89 1
This fixes point t = p -11 16, but I still have to fix
point t = p -11 82.
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
The following inputs had problems before this fix:
(s2.cin)
s -100 50 200 -100
p 0 100
p 0 150
p 0 0
(s2hor.cin)
s -100 50 200 -100
p 100 0
p 150 0
p 0 0
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
Many changes to support the tie breaking predicates
in the implementation and the declaration part of
the algorithm class.
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
This fixes validity checking for spl1.cin input (and others):
s -100 110 200 80
s 200 80 -110 -190
p 0 0
p 0 100
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
I added point_inside_touching_sides_v function
in vsqrnew code, which is an adaptation of the
respective vring code.
This fixes, among other things, the validity checking
of input ppswedge.cin:
s -200 -200 0 0
s -200 200 0 0
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
The check for point t against a segment s is too
strong at the moment. I have to implement a predicate
similar to point_inside_touching_sides of the ring code.
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
Before this fix, the point t was not tested at all with
segments q or r.
This fixes a bug for input (v4nox.cin):
s 100 100 300 300
s -100 110 200 80
p 0 150
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>
If point t is inside any of the two sides of the square
that touch the touching corner of a segment s in p, q, r,
then return negative.
Use helper function point_inside_touching_sides.
Signed-off-by: Panagiotis Cheilaris <philaris@cs.ntua.gr>