Scene#
- class ansys.stk.core.graphics.Scene#
A scene provides properties and functionality that are reflected in the rendering of the globe control that it is associated with. An globe controlβs scene is available from the scene propertyβ¦
Overview#
Render the scene. To render all the scenes within an application, use the Render method. |
|
Execute a pick at the given x, y and returns a depth sorted collection of picked objects. The coordinate origin is top, left. To pick screen overlays, use the PickScreenOverlays method. |
|
Execute a pick in the given rectangular region and returns a depth sorted collection of picked objects. The coordinate origin is top, left. To pick screen overlays, use the PickScreenOverlays method. |
|
Execute a pick on screen overlays at the given x, y and returns a front to back sorted collection of picked overlays. The coordinate origin is top, left. To pick other objects in the scene, use the Pick method. |
|
|
βββReturn an ISceneEventHandler that is subscribed to handle events associated with this instance of Scene.βββ |
Get the camera associated with the scene, which affects the view that is rendered by the scene. |
|
Get the lighting associated with the scene. |
|
Get or set whether sunshine is rendered by the Sun central body. Sunshine renders a halo effect around the sun when it is viewed in the scene. |
|
Get the central body graphics for a specified central body. |
|
Get or set the background color of the scene. |
|
Get or set whether the sky will be shaded based on camera altitude. When shade sky based on altitude is set to true, the sky will become more blue as the Camera gets closer to the surface of the central body. |
|
Get or set whether stars are shown or hidden in the scene. |
|
Get the scene globe overlay settings for the scene. |
|
Return the scene identifier. |
|
Get or set whether water surface on earth is shown or hidden in the scene. |
|
Get or set the multisample anti-aliasing (MSAA) option for this scene. As the level of anti-aliasing increases, performance will generally decrease, but the quality of the anti-aliasing will improve. |
|
Get the visual effects associated with the scene. |
|
Get the clouds for the scene. |
|
Get or set whether stars labels are shown or hidden in the scene. |
Examples#
Control the Display of Stars and Water Texture
# Scenario scenario: Scenario object
# Turn off the stars and water texture
manager = scenario.scene_manager
manager.scenes.item(0).show_stars = False
manager.scenes.item(0).show_water_surface = False
Import detail#
from ansys.stk.core.graphics import Scene
Property detail#
- property Scene.camera: Camera#
Get the camera associated with the scene, which affects the view that is rendered by the scene.
- property Scene.show_sunshine: bool#
Get or set whether sunshine is rendered by the Sun central body. Sunshine renders a halo effect around the sun when it is viewed in the scene.
- property Scene.central_bodies: CentralBodyGraphicsIndexer#
Get the central body graphics for a specified central body.
- property Scene.shade_sky_based_on_altitude: bool#
Get or set whether the sky will be shaded based on camera altitude. When shade sky based on altitude is set to true, the sky will become more blue as the Camera gets closer to the surface of the central body.
- property Scene.globe_overlay_settings: SceneGlobeOverlaySettings#
Get the scene globe overlay settings for the scene.
- property Scene.show_water_surface: bool#
Get or set whether water surface on earth is shown or hidden in the scene.
- property Scene.anti_aliasing: AntiAliasingMethod#
Get or set the multisample anti-aliasing (MSAA) option for this scene. As the level of anti-aliasing increases, performance will generally decrease, but the quality of the anti-aliasing will improve.
- property Scene.visual_effects: VisualEffects#
Get the visual effects associated with the scene.
Method detail#
- Scene.render(self) None #
Render the scene. To render all the scenes within an application, use the Render method.
- Returns:
- Scene.pick(self, x: int, y: int) PickResultCollection #
Execute a pick at the given x, y and returns a depth sorted collection of picked objects. The coordinate origin is top, left. To pick screen overlays, use the PickScreenOverlays method.
- Scene.pick_rectangular(self, left: int, bottom: int, right: int, top: int) PickResultCollection #
Execute a pick in the given rectangular region and returns a depth sorted collection of picked objects. The coordinate origin is top, left. To pick screen overlays, use the PickScreenOverlays method.
- Scene.pick_screen_overlays(self, x: int, y: int) ScreenOverlayPickResultCollection #
Execute a pick on screen overlays at the given x, y and returns a front to back sorted collection of picked overlays. The coordinate origin is top, left. To pick other objects in the scene, use the Pick method.