Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
8077f109
Commit
8077f109
authored
Oct 11, 1998
by
Rein Klazes
Committed by
Alexandre Julliard
Oct 11, 1998
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Yet another improvement to the bezier code.
parent
d62c62b1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
5 deletions
+25
-5
graphics.c
graphics/x11drv/graphics.c
+25
-5
No files found.
graphics/x11drv/graphics.c
View file @
8077f109
...
...
@@ -976,10 +976,20 @@ static BOOL32 BezierCheck( int level, POINT32 *Points)
INT32
dx
,
dy
;
dx
=
Points
[
3
].
x
-
Points
[
0
].
x
;
dy
=
Points
[
3
].
y
-
Points
[
0
].
y
;
if
(
ABS
(
dy
)
<
ABS
(
dx
)){
/* shallow line */
if
(
ABS
(
dy
)
<
=
ABS
(
dx
)){
/* shallow line */
/* check that control points are between begin and end */
if
(
(
Points
[
1
].
x
-
Points
[
0
].
x
)
*
dx
<
0
||
(
Points
[
2
].
x
-
Points
[
0
].
x
)
*
dx
<
0
)
return
FALSE
;
if
(
Points
[
1
].
x
<
Points
[
0
].
x
){
if
(
Points
[
1
].
x
<
Points
[
3
].
x
)
return
FALSE
;
}
else
if
(
Points
[
1
].
x
>
Points
[
3
].
x
)
return
FALSE
;
if
(
Points
[
2
].
x
<
Points
[
0
].
x
){
if
(
Points
[
2
].
x
<
Points
[
3
].
x
)
return
FALSE
;
}
else
if
(
Points
[
2
].
x
>
Points
[
3
].
x
)
return
FALSE
;
dx
=
BEZIERSHIFTDOWN
(
dx
);
if
(
!
dx
)
return
TRUE
;
if
(
abs
(
Points
[
1
].
y
-
Points
[
0
].
y
-
(
dy
/
dx
)
*
...
...
@@ -991,8 +1001,18 @@ static BOOL32 BezierCheck( int level, POINT32 *Points)
return
TRUE
;
}
else
{
/* steep line */
/* check that control points are between begin and end */
if
(
(
Points
[
1
].
y
-
Points
[
0
].
y
)
*
dy
<
0
||
(
Points
[
2
].
y
-
Points
[
0
].
y
)
*
dy
<
0
)
return
FALSE
;
if
(
Points
[
1
].
y
<
Points
[
0
].
y
){
if
(
Points
[
1
].
y
<
Points
[
3
].
y
)
return
FALSE
;
}
else
if
(
Points
[
1
].
y
>
Points
[
3
].
y
)
return
FALSE
;
if
(
Points
[
2
].
y
<
Points
[
0
].
y
){
if
(
Points
[
2
].
y
<
Points
[
3
].
y
)
return
FALSE
;
}
else
if
(
Points
[
2
].
y
>
Points
[
3
].
y
)
return
FALSE
;
dy
=
BEZIERSHIFTDOWN
(
dy
);
if
(
!
dy
)
return
TRUE
;
if
(
abs
(
Points
[
1
].
x
-
Points
[
0
].
x
-
(
dx
/
dy
)
*
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment