Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
VR-demos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nomad-lab
VR-demos
Commits
b85520c7
Commit
b85520c7
authored
Apr 04, 2018
by
Ruben Jesus Garcia Hernandez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Atom bonds in GearVR
parent
b38a4b4e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
19 additions
and
0 deletions
+19
-0
OculusMobile/NOMADGearvrT/Src/OvrApp.cpp
OculusMobile/NOMADGearvrT/Src/OvrApp.cpp
+19
-0
No files found.
OculusMobile/NOMADGearvrT/Src/OvrApp.cpp
View file @
b85520c7
...
...
@@ -563,6 +563,25 @@ void OvrApp::RenderAtoms(const float *m) //m[16]
if
((
e
=
glGetError
())
!=
GL_NO_ERROR
)
eprintf
(
"Gl error after Render cloned Atom timestep =%d: %d
\n
"
,
currentSet
,
e
);
}
// painting cloned atoms
//now bonds
if
(
numBonds
&&
displaybonds
/*&& showAtoms*/
)
{
glLineWidth
(
bondThickness
);
glBindVertexArray
(
AtomTVAO
[
2
]);
glUseProgram
(
UnitCellP
);
glUniformMatrix4fv
(
UnitCellMatrixLoc
,
1
,
GL_FALSE
,
m
);
glUniform4fv
(
UnitCellColourLoc
,
1
,
bondscolours
);
if
((
e
=
glGetError
())
!=
GL_NO_ERROR
)
eprintf
(
"Gl error after Render Atom bonds uniform timestep =%d: %d
\n
"
,
currentSet
,
e
);
if
(
currentSet
==
0
||
fixedAtoms
)
glDrawElements
(
GL_LINES
,
numBonds
[
0
],
GL_UNSIGNED_INT
,
(
void
*
)
0
);
else
glDrawElements
(
GL_LINES
,
numBonds
[
currentSet
]
-
numBonds
[
currentSet
-
1
],
GL_UNSIGNED_INT
,
(
void
*
)(
sizeof
(
int
)
*
numBonds
[
currentSet
-
1
])
);
glLineWidth
(
1.0
f
);
if
((
e
=
glGetError
())
!=
GL_NO_ERROR
)
eprintf
(
"Gl error after Render Atom bonds timestep =%d: %d
\n
"
,
currentSet
,
e
);
glBindVertexArray
(
0
);
}
}
// no tess
}
...
...
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