Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
einsteinathome
pulsatingscience
Commits
e5e1a494
Commit
e5e1a494
authored
Sep 13, 2017
by
Oliver Bock
Browse files
Added marker for source plane normal center
parent
e06756eb
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/pulsaranimationwidget.cpp
View file @
e5e1a494
...
...
@@ -57,6 +57,7 @@ PulsarAnimationWidget::PulsarAnimationWidget(QWidget *parent) :
m_quadricSourcePlane
=
NULL
;
m_quadricSourcePlaneNormal
=
NULL
;
m_quadricSourcePlaneNormalCap
=
NULL
;
m_quadricSourcePlaneNormalCenter
=
NULL
;
m_quadricLHOv
=
NULL
;
m_quadricLHOh
=
NULL
;
...
...
@@ -98,6 +99,7 @@ PulsarAnimationWidget::~PulsarAnimationWidget()
if
(
m_quadricSourcePlane
)
gluDeleteQuadric
(
m_quadricSourcePlane
);
if
(
m_quadricSourcePlaneNormal
)
gluDeleteQuadric
(
m_quadricSourcePlaneNormal
);
if
(
m_quadricSourcePlaneNormalCap
)
gluDeleteQuadric
(
m_quadricSourcePlaneNormalCap
);
if
(
m_quadricSourcePlaneNormalCenter
)
gluDeleteQuadric
(
m_quadricSourcePlaneNormalCenter
);
if
(
m_quadricLHOv
)
gluDeleteQuadric
(
m_quadricLHOv
);
if
(
m_quadricLHOh
)
gluDeleteQuadric
(
m_quadricLHOh
);
...
...
@@ -142,6 +144,7 @@ void PulsarAnimationWidget::initializeGL()
m_quadricSourcePlane
=
gluNewQuadric
();
m_quadricSourcePlaneNormal
=
gluNewQuadric
();
m_quadricSourcePlaneNormalCap
=
gluNewQuadric
();
m_quadricSourcePlaneNormalCenter
=
gluNewQuadric
();
m_quadricLHOv
=
gluNewQuadric
();
m_quadricLHOh
=
gluNewQuadric
();
...
...
@@ -153,6 +156,7 @@ void PulsarAnimationWidget::initializeGL()
gluQuadricNormals
(
m_quadricSourcePlane
,
GLU_SMOOTH
);
gluQuadricNormals
(
m_quadricSourcePlaneNormal
,
GLU_SMOOTH
);
gluQuadricNormals
(
m_quadricSourcePlaneNormalCap
,
GLU_SMOOTH
);
gluQuadricNormals
(
m_quadricSourcePlaneNormalCenter
,
GLU_SMOOTH
);
gluQuadricNormals
(
m_quadricLHOv
,
GLU_SMOOTH
);
gluQuadricNormals
(
m_quadricLHOh
,
GLU_SMOOTH
);
...
...
@@ -393,6 +397,12 @@ void PulsarAnimationWidget::paintGL()
glEnd
();
}
glPopMatrix
();
glColor3f
(
1.0
f
,
1.0
f
,
1.0
f
);
glPushMatrix
();
{
gluSphere
(
m_quadricSourcePlaneNormalCenter
,
0.040
,
32
,
32
);
}
glPopMatrix
();
// draw disc
glMaterialfv
(
GL_FRONT
,
GL_AMBIENT_AND_DIFFUSE
,
translucent
);
...
...
src/pulsaranimationwidget.h
View file @
e5e1a494
...
...
@@ -79,6 +79,7 @@ private:
GLUquadricObj
*
m_quadricLLOv
;
GLUquadricObj
*
m_quadricSourcePlaneNormal
;
GLUquadricObj
*
m_quadricSourcePlaneNormalCap
;
GLUquadricObj
*
m_quadricSourcePlaneNormalCenter
;
GLUquadricObj
*
m_quadricLHOv
;
GLUquadricObj
*
m_quadricLHOh
;
...
...
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