Commit b911f5a14baabf16b806ae4242eee1bcb595fc0e
1 parent
c3bcac3d
Exists in
master
and in
67 other branches
Added init of GPU support
Showing
1 changed file
with
2 additions
and
4 deletions
Show diff stats
invesalius/data/volume.py
... | ... | @@ -432,7 +432,7 @@ class Volume(): |
432 | 432 | raycasting_function = vtk.vtkVolumeRayCastCompositeFunction() |
433 | 433 | raycasting_function.SetCompositeMethodToInterpolateFirst() |
434 | 434 | |
435 | - if ses.Session().rendering == 0: | |
435 | + if ses.Session().rendering == '0': | |
436 | 436 | self.volume_mapper.SetVolumeRayCastFunction(raycasting_function) |
437 | 437 | |
438 | 438 | def ApplyConvolution(self, imagedata, update_progress = None): |
... | ... | @@ -516,13 +516,11 @@ class Volume(): |
516 | 516 | volume_mapper.IntermixIntersectingGeometryOn() |
517 | 517 | self.volume_mapper = volume_mapper |
518 | 518 | else: |
519 | - | |
520 | - if ses.Session().rendering == 0: | |
519 | + if ses.Session().rendering == '0': | |
521 | 520 | volume_mapper = vtk.vtkFixedPointVolumeRayCastMapper() |
522 | 521 | #volume_mapper.AutoAdjustSampleDistancesOff() |
523 | 522 | self.volume_mapper = volume_mapper |
524 | 523 | volume_mapper.IntermixIntersectingGeometryOn() |
525 | - | |
526 | 524 | else: |
527 | 525 | volume_mapper = vtk.vtkGPUVolumeRayCastMapper() |
528 | 526 | self.volume_mapper = volume_mapper | ... | ... |