Skip to content

Commit

Permalink
fix(VtkGeometryRenderer): Guard call when no camera available
Browse files Browse the repository at this point in the history
  • Loading branch information
jourdain committed Aug 3, 2018
1 parent d343142 commit 453e75e
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/React/Renderers/VtkGeometryRenderer/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,9 @@ export default class VtkGeometryRenderer extends React.Component {
// FIXME: find the proper way to get the renderer we care about
// Calling getCurrentRenderer() on the interactorStyle seems to return null
// const activeCamera = this.interactorStyle.getCurrentRenderer().getActiveCamera();
if (!this.activeCamera && !this.renderWindow.getRenderers().length) {
return null;
}
const activeCamera =
this.activeCamera ||
this.renderWindow.getRenderers()[0].getActiveCamera();
Expand Down

0 comments on commit 453e75e

Please sign in to comment.