Scene3D type provides description of the 3D scene being visualized. 更多...
import 语句: | import QtDataVisualization 1.2 |
Since: | QtDataVisualization 1.0 |
实例化: | Q3DScene |
The 3D scene contains a single active camera and a single active light source. Visualized data is assumed to be at a fixed location.
The 3D scene also keeps track of the viewport in which visualization rendering is done, the primary subviewport inside the viewport where the main 3D data visualization view resides and the secondary subviewport where the 2D sliced view of the data resides.
Also the scene has flag for tracking if the secondary 2D slicing view is currently active or not.
注意: 并非所有可视化都支持次级 2D 切片视图。
activeCamera : Camera3D |
The currently active camera in the 3D scene. When a Camera3D is set in the property, it is automatically added as child of the scene.
activeLight : Light3D |
The currently active light in the 3D scene. When a Light3D is set in the property, it is automatically added as child of the scene.
The current device pixel ratio that is used when mapping input coordinates to pixel coordinates.
The coordinates for the user input that should be processed by the scene as a graph position query. If this property is set to value other than invalidSelectionPoint , the graph tries to match a graph position to the given point within the primary viewport. After the rendering pass, this property is returned to its default state of invalidSelectionPoint . The queried graph position can be read from the AbstractGraph3D::queriedGraphPosition property after the next render pass.
There is no single correct 3D coordinate to match a particular screen position, so to be consistent, the queries are always done against the inner sides of an invisible box surrounding the graph.
注意: Bar graphs allow graph position queries only at the graph floor level.
另请参阅 AbstractGraph3D::queriedGraphPosition .
A constant property providing an invalid point for selection.
primarySubViewport : rect |
The current subviewport rectangle inside the viewport where the primary view of the data visualization is targeted.
若
slicingActive
is
false
, the primary sub viewport will be equal to the viewport. If
slicingActive
is
true
and the primary sub viewport has not been explicitly set, it will be one fifth of the viewport.
注意: Setting primarySubViewport larger than or outside of viewport resizes viewport accordingly.
secondarySubViewport : rect |
* * * The secondary viewport rectangle inside the viewport. The secondary viewport * is used for drawing the 2D slice view in some visualizations. If it has not * been explicitly set, it will be null. If
slicingActive
is
true
, it will * be equal to the viewport. *
注意: If the secondary sub viewport is larger than or outside of the * viewport, the viewport is resized accordingly.
Defines whether the 2D slicing view or the 3D view is drawn on top.
The coordinates for the user input that should be processed by the scene as a selection. If this property is set to a value other than invalidSelectionPoint , the graph tries to select a data item at the given point within the primary viewport. After the rendering pass, the property is returned to its default state of invalidSelectionPoint .
Defines whether the 2D slicing view is currently active. If
true
,
AbstractGraph3D::selectionMode
must have either the
AbstractGraph3D.SelectionRow
or
AbstractGraph3D.SelectionColumn
set to a valid selection.
注意: Not all visualizations support the 2D slicing view.
viewport : rect |
The current viewport rectangle where all 3D rendering is targeted.