diff --git a/itkwidgets/viewer.py b/itkwidgets/viewer.py index e3055373..61d70a69 100644 --- a/itkwidgets/viewer.py +++ b/itkwidgets/viewer.py @@ -242,6 +242,13 @@ def set_background_color(self, bgColor: List[float]): def get_background_color(self): return self.viewer_rpc.itk_viewer.getBackgroundColor() + @fetch_value + def set_cropping_planes(self, croppingPlanes): + self.viewer_rpc.itk_viewer.setCroppingPlanes(croppingPlanes) + @fetch_value + async def get_cropping_planes(self): + return await self.viewer_rpc.itk_viewer.getCroppingPlanes() + @fetch_value def set_image(self, image: Image, name: str = 'Image'): render_type = _detect_render_type(image, 'image')