show#
- Session.show(what: str = 'image', width: int | None = None, height: int | None = None, temporal: bool = False, aa: int = 4, fps: float = 30.0, num_frames: int | None = None, ui: str | None = 'simple') renderable.Renderable#
Capture the current EnSight scene or otherwise make it available for display in a web browser.
This method generates the appropriate visuals and returns the renderable object for viewing. If the session is in a Jupyter notebook, the cell in which the
show()method is issued is updated with the renderable display.- Parameters:
- what
str,optional Type of scene display to generate. The default is
"image". Options are:image: Simple rendered PNG imagedeep_pixel: EnSight deep pixel imageanimation: MPEG4 moviewebgl: Interactive WebGL-based browser viewerremote: Remote rendering-based interactive EnSight viewerremote_scene: Remote rendering-based interactive EnSight viewer
- width
int,optional Width of the rendered entity. The default is
None.- height
int,optional Height of the rendered entity. The default is
None.- temporalbool,
optional Whether to include all timesteps in WebGL views. The default is
False.- aa
int,optional Number of antialiasing passes to use when rendering images. The default is
4.- fps
float,optional Number of frames per second to use for animation playback. The default is
30.- num_frames
int,optional Number of frames of static timestep to record for animation playback.
- what
- Returns:
- Raises:
RuntimeErrorIf it is not possible to generate the content.
Examples
Render an image and display it in a browser. Rotate the scene and update the display.
>>> image = session.show('image', width=800, height=600) >>> image.browser() >>> session.ensight.view_transf.rotate(30, 30, 0) >>> image.update() >>> image.browser()