Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix bug of vertexcolor #213

Open
wants to merge 6 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added

### Changed

* Fixed bug [#212](https://github.com/compas-dev/compas_view2/issues/212).
### Removed


Expand Down
1 change: 1 addition & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,7 @@ def setup(app):
"image_dark": "_static/compas_icon_white.png", # relative to parent of conf.py
"text": project,
},
"announcement": "This is the achieve documentation for the COMPAS_View2 for compas<=1.17.9. The next generation of the viewer for compas>2 is available <a href='https://compas.dev/compas_viewer/latest/'>here</a>.",
}

html_context = {
Expand Down
12 changes: 6 additions & 6 deletions src/compas_view2/objects/meshobject.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,9 +180,9 @@ def _frontfaces_data(self):
positions.append(b)
positions.append(c)
if self.use_vertex_color:
colors.append(vertex_color[a])
colors.append(vertex_color[b])
colors.append(vertex_color[c])
colors.append(vertex_color[vertices[0]])
colors.append(vertex_color[vertices[1]])
colors.append(vertex_color[vertices[2]])
else:
colors.append(color)
colors.append(color)
Expand Down Expand Up @@ -254,9 +254,9 @@ def _backfaces_data(self):
positions.append(b)
positions.append(c)
if self.use_vertex_color:
colors.append(vertex_color[a])
colors.append(vertex_color[b])
colors.append(vertex_color[c])
colors.append(vertex_color[vertices[0]])
colors.append(vertex_color[vertices[1]])
colors.append(vertex_color[vertices[2]])
else:
colors.append(color)
colors.append(color)
Expand Down
Loading