Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
e3cb0aa3
Commit
e3cb0aa3
authored
Apr 12, 2013
by
Maciej Suminski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Tesselation error fix.
Added missing callback function (combine callback).
parent
b1144a86
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
4 deletions
+17
-4
opengl_gal.cpp
common/gal/opengl/opengl_gal.cpp
+17
-4
No files found.
common/gal/opengl/opengl_gal.cpp
View file @
e3cb0aa3
...
...
@@ -1394,6 +1394,18 @@ void CALLBACK VertexCallback( GLvoid* aVertexPtr )
}
void
CALLBACK
CombineCallback
(
GLdouble
coords
[
3
],
GLdouble
*
vertex_data
[
4
],
GLfloat
weight
[
4
],
GLdouble
**
dataOut
)
{
GLdouble
*
vertex
=
new
GLdouble
[
3
];
memcpy
(
vertex
,
coords
,
3
*
sizeof
(
GLdouble
)
);
*
dataOut
=
vertex
;
}
void
CALLBACK
BeginCallback
(
GLenum
aWhich
)
{
glBegin
(
aWhich
);
...
...
@@ -1417,10 +1429,11 @@ void CALLBACK ErrorCallback( GLenum aErrorCode )
void
InitTesselatorCallbacks
(
GLUtesselator
*
aTesselator
)
{
gluTessCallback
(
aTesselator
,
GLU_TESS_VERTEX
,
(
void
(
CALLBACK
*
)()
)
VertexCallback
);
gluTessCallback
(
aTesselator
,
GLU_TESS_BEGIN
,
(
void
(
CALLBACK
*
)()
)
BeginCallback
);
gluTessCallback
(
aTesselator
,
GLU_TESS_END
,
(
void
(
CALLBACK
*
)()
)
EndCallback
);
gluTessCallback
(
aTesselator
,
GLU_TESS_ERROR
,
(
void
(
CALLBACK
*
)()
)
ErrorCallback
);
gluTessCallback
(
aTesselator
,
GLU_TESS_VERTEX
,
(
void
(
CALLBACK
*
)()
)
VertexCallback
);
gluTessCallback
(
aTesselator
,
GLU_TESS_COMBINE
,
(
void
(
CALLBACK
*
)()
)
CombineCallback
);
gluTessCallback
(
aTesselator
,
GLU_TESS_BEGIN
,
(
void
(
CALLBACK
*
)()
)
BeginCallback
);
gluTessCallback
(
aTesselator
,
GLU_TESS_END
,
(
void
(
CALLBACK
*
)()
)
EndCallback
);
gluTessCallback
(
aTesselator
,
GLU_TESS_ERROR
,
(
void
(
CALLBACK
*
)()
)
ErrorCallback
);
}
...
...
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