diff --git a/mne/viz/backends/_pyvista.py b/mne/viz/backends/_pyvista.py index dbf04335598..585eebd4c12 100644 --- a/mne/viz/backends/_pyvista.py +++ b/mne/viz/backends/_pyvista.py @@ -862,12 +862,11 @@ def project(self, xyz, ch_names): return _Projection(xy=xy, pts=pts, plotter=self.plotter) def _enable_depth_peeling(self): - if not self.figure.store["off_screen"]: - for plotter in self._all_plotters: - if self.depth_peeling: - plotter.enable_depth_peeling() - else: - plotter.disable_depth_peeling() + for plotter in self._all_plotters: + if self.depth_peeling: + plotter.enable_depth_peeling() + else: + plotter.disable_depth_peeling() def _toggle_antialias(self): """Enable it everywhere except Azure."""