summaryrefslogtreecommitdiffstats
path: root/src/datavisualization/doc/src/qtdatavisualization-qml-abstractdeclarative.qdoc
blob: dfa65877982cfdd02741c8763f69f8569179e337 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
/****************************************************************************
**
** Copyright (C) 2014 Digia Plc
** All rights reserved.
** For any questions to Digia, please use contact form at http://qt.digia.com
**
** This file is part of the QtDataVisualization module.
**
** Licensees holding valid Qt Enterprise licenses may use this file in
** accordance with the Qt Enterprise License Agreement provided with the
** Software or, alternatively, in accordance with the terms contained in
** a written agreement between you and Digia.
**
** If you have questions regarding the use of this file, please use
** contact form at http://qt.digia.com
**
****************************************************************************/

/*!
  \qmltype AbstractGraph3D
  \inqmlmodule QtDataVisualization
  \since QtDataVisualization 1.0
  \ingroup datavisualization_qml
  \brief Base type for 3D visualizations.

  This type is the base type for all 3D visualizations in QtDataVisualization.

  Note that this type is uncreatable, but contains properties that are shared between
  the 3D visualizations.

  For AbstractGraph3D enums, see \l{QAbstract3DGraph::SelectionFlag},
  \l{QAbstract3DGraph::ShadowQuality}, \l{QAbstract3DGraph::ElementType}, and
  \l{QAbstract3DGraph::OptimizationHint}.

  \sa Bars3D, Scatter3D, Surface3D, {Qt Data Visualization C++ Classes}
 */

/*!
  \qmlproperty AbstractGraph3D.SelectionMode AbstractGraph3D::selectionMode
  Active selection mode in the visualization.
 */

/*!
  \qmlproperty AbstractGraph3D.ShadowQuality AbstractGraph3D::shadowQuality
  Shadow quality.
 */

/*!
  \qmlproperty bool AbstractGraph3D::shadowsSupported
  This read-only property indicates if shadows are supported with the
  current configuration or not. OpenGL ES2 configurations do not support shadows.
 */

/*!
  \qmlproperty Scene3D AbstractGraph3D::scene
  Read only property that can be used to access for example Camera3D via the Scene3D held here.
 */

/*!
  \qmlproperty AbstractInputHandler3D AbstractGraph3D::inputHandler
  Input handler. You can disable default input handlers by setting this property to \c {null}.
 */

/*!
  \qmlproperty Theme3D AbstractGraph3D::theme
  The active theme of the graph.
 */

/*!
  \qmlproperty AbstractGraph3D.RenderingMode AbstractGraph3D::renderingMode

  Defaults to \c{RenderIndirect}.

  \table
       \header
           \li Render Mode
           \li Description
       \row
           \li RenderDirectToBackground
           \li Indicates the graph will be rendered directly on the window background.
  This mode also clears the whole window before rendering the graph, including the areas
  outside the graph.
  Since the graphs in this rendering mode are drawn on the window background under other QML
  items, the regular QML window clearing before rendering is suppressed. The graphs handle the clearing
  themselves instead.
  If the surface format of the window supports antialiasing, it will be used (see
  \c {QtDataVisualization::qDefaultSurfaceFormat()}).
  This rendering mode offers the best performance at the expense of non-standard QML behavior. For example,
  the graphs do not obey the Z ordering of QML items and the opacity value has no effect on them.
       \row
           \li RenderDirectToBackground_NoClear
           \li Similar to RenderDirectToBackground mode, except that the graph will not clear the whole
  window before rendering the graph. This mode is better for windows where you have other custom items
  besides the graphs that also draw on the window background. In that case you need to either take care
  of the window clearing yourself or ensure that all areas of the window are fully covered with opaque
  items.
  If one graph in the window uses either of the direct rendering modes, then all other graphs in the
  same window also drawn in direct modes should use the exact same direct rendering mode.
  Otherwise some graphs may not show up, depending on the drawing order of the graphs.
       \row
           \li RenderIndirect
           \li Indicates the graph will be first rendered to an offscreen surface that
  is then drawn during normal QML item rendering. The rendered image is
  antialiased using multisampling method if it is supported in the current environment and the
  msaaSamples property value is greater than zero.
  This rendering mode offers good quality and normal QML item behavior at the expense of performance.
  \endtable

  \note Antialiasing is not supported in OpenGL ES2 environments in any rendering mode.

  \note Setting the \c antialiasing property of the graphs doesn't do anything. However, it is
  set by the graph itself if the current rendering mode uses antialiasing.

  \sa msaaSamples
 */

/*!
  \qmlproperty int AbstractGraph3D::msaaSamples
  The number of samples used in multisample antialiasing when renderingMode is \c RenderIndirect.
  When renderingMode is \c RenderDirectToBackground or \c RenderDirectToBackground_NoClear, this
  property value is read-only and returns the number of samples specified by the window surface
  format.
  Defaults to \c{4}.

  \sa renderingMode
 */

/*!
 * \qmlproperty bool AbstractGraph3D::measureFps
 * \since QtDataVisualization 1.1
 *
 * If \c {true}, the rendering is done continuously instead of on demand, and currentFps property
 * is updated. Defaults to \c{false}.
 *
 * \sa currentFps
 */

/*!
 * \qmlproperty int AbstractGraph3D::currentFps
 * \since QtDataVisualization 1.1
 *
 * When fps measuring is enabled, the results for the last second are stored in this read-only
 * property. It takes at least a second before this value updates after measurement is activated.
 *
 * \sa measureFps
 */

/*!
 * \qmlproperty list<Custom3DItem> AbstractGraph3D::customItemList
 * \since QtDataVisualization 1.1
 *
 * Add a list of \l{Custom3DItem}s to the graph. Graph takes ownership of the added items.
 */

/*!
 * \qmlproperty bool AbstractGraph3D::polar
 * \since QtDataVisualization 1.2
 *
 * If \c {true}, the horizontal axes are changed into polar axes. The X axis becomes the
 * angular axis and the Z axis becomes the radial axis.
 * Polar mode is not available for bar graphs.
 *
 * Defaults to \c{false}.
 *
 * \sa orthoProjection, radialLabelOffset
 */

/*!
 * \qmlproperty real AbstractGraph3D::radialLabelOffset
 * \since QtDataVisualization 1.2
 *
 * This property specifies the normalized horizontal offset for the axis labels of the radial
 * polar axis. The value 0.0 indicates the labels should be drawn next to the 0-angle angular
 * axis grid line. The value 1.0 indicates the labels are drawn on their normal place at the edge
 * of the graph background.
 * This property is ignored if polar property value is \c{false}. Defaults to 1.0.
 *
 * \sa polar
 */

/*!
 * \qmlmethod void AbstractGraph3D::clearSelection()
 * Clears selection from all attached series.
 */

/*!
 * \qmlmethod int AbstractGraph3D::addCustomItem(Custom3DItem item)
 *
 * Adds a Custom3DItem \a item to the graph. Graph takes ownership of the added item.
 *
 * \return index to the added item if add was successful, -1 if trying to add a null item, and
 * index of the item if trying to add an already added item.
 *
 * \sa removeCustomItems(), removeCustomItem(), removeCustomItemAt()
 *
 * \since QtDataVisualization 1.1
 */

/*!
 * \qmlmethod void AbstractGraph3D::removeCustomItems()
 *
 * Removes all custom items. Deletes the resources allocated to them.
 *
 * \since QtDataVisualization 1.1
 */

/*!
 * \qmlmethod void AbstractGraph3D::removeCustomItem(Custom3DItem item)
 *
 * Removes the custom \a {item}. Deletes the resources allocated to it.
 *
 * \since QtDataVisualization 1.1
 */

/*!
 * \qmlmethod void AbstractGraph3D::removeCustomItemAt(vector3d position)
 *
 * Removes all custom items at \a {position}. Deletes the resources allocated to them.
 *
 * \since QtDataVisualization 1.1
 */

/*!
 * \qmlmethod void AbstractGraph3D::releaseCustomItem(Custom3DItem item)
 *
 * Gets ownership of \a item back and removes the \a item from the graph.
 *
 * \since QtDataVisualization 1.1
 *
 * \note If the same item is added back to the graph, the texture file needs to be re-set.
 *
 * \sa Custom3DItem::textureFile
 */

/*!
 * \qmlmethod int AbstractGraph3D::selectedLabelIndex()
 *
 * Can be used to query the index of the selected label after receiving \c selectedElementChanged
 * signal with any label type. Selection is valid until the next \c selectedElementChanged signal.
 *
 * \return index of the selected label, or -1.
 *
 * \since QtDataVisualization 1.1
 *
 * \sa selectedElement
 */

/*!
 * \qmlmethod Abstract3DAxis AbstractGraph3D::selectedAxis()
 *
 * Can be used to get the selected axis after receiving \c selectedElementChanged signal with any label
 * type. Selection is valid until the next \c selectedElementChanged signal.
 *
 * \return the selected axis, or null.
 *
 * \since QtDataVisualization 1.1
 *
 * \sa selectedElement
 */

/*!
 * \qmlmethod int AbstractGraph3D::selectedCustomItemIndex()
 *
 * Can be used to query the index of the selected custom item after receiving \c selectedElementChanged
 * signal with \l{QAbstract3DGraph::ElementCustomItem}{ElementCustomItem} type. Selection is valid
 * until the next \c selectedElementChanged signal.
 *
 * \return index of the selected custom item, or -1.
 *
 * \since QtDataVisualization 1.1
 *
 * \sa selectedElement
 */

/*!
 * \qmlmethod Custom3DItem AbstractGraph3D::selectedCustomItem()
 *
 * Can be used to get the selected custom item after receiving \c selectedElementChanged signal with
 * \l{QAbstract3DGraph::ElementCustomItem}{ElementCustomItem} type. Ownership of the item remains
 * with the graph. Selection is valid until the next \c selectedElementChanged signal.
 *
 * \return the selected custom item, or null.
 *
 * \since QtDataVisualization 1.1
 *
 * \sa selectedElement
 */

/*!
 * \qmlproperty AbstractGraph3D.ElementType AbstractGraph3D::selectedElement
 *
 * Can be used to query the selected element type.
 * Type is valid until the next \c selectedElementChanged signal.
 *
 * \c selectedElementChanged signal is emitted when a selection is made in the graph.
 *
 * Signal can be used for example for implementing customized input handling, as demonstrated in
 * this \l {Qt Quick 2 Axis Dragging Example}{example}.
 *
 * \sa selectedLabelIndex(), selectedAxis(), selectedCustomItemIndex(), selectedCustomItem(),
 * Bars3D::selectedSeries, Scatter3D::selectedSeries, Scene3D::selectionQueryPosition
 *
 * \since QtDataVisualization 1.1
 */

/*!
 * \qmlproperty bool AbstractGraph3D::orthoProjection
 * \since QtDataVisualization 1.1
 *
 * If \c {true}, orthographic projection will be used for displaying the graph. Defaults to \c{false}.
 * \note Shadows will be disabled when set to \c{true}.
 */

/*!
 * \qmlproperty real AbstractGraph3D::aspectRatio
 * \since QtDataVisualization 1.1
 *
 * The aspect ratio is the ratio of the graph scaling between the longest axis on the horizontal
 * plane and the Y-axis. Defaults to \c{2.0}.
 *
 * \note Has no effect on Bars3D.
 *
 * \sa horizontalAspectRatio
 */

/*!
 * \qmlproperty real AbstractGraph3D::horizontalAspectRatio
 * \since QtDataVisualization 1.2
 *
 * The horizontal aspect ratio is the ratio of the graph scaling between the X and Z axes.
 * Value of 0.0 indicates automatic scaling according to axis ranges.
 * Defaults to \c{0.0}.
 *
 * \note Has no effect on Bars3D, which handles scaling on the horizontal plane via
 * \l{Bars3D::barThickness}{barThickness} and \l{Bars3D::barSpacing}{barSpacing} properties.
 * Polar graphs also ignore this property.
 *
 * \sa aspectRatio, polar, Bars3D::barThickness, Bars3D::barSpacing
 */

/*!
 * \qmlproperty AbstractGraph3D.OptimizationHints AbstractGraph3D::optimizationHints
 * \since QtDataVisualization 1.1
 *
 * Defines if the rendering optimization is default or static. Default mode provides the full feature set at
 * reasonable performance. Static is a beta level feature and currently supports only a subset of the
 * features on the Scatter graph. Missing features are object gradient for mesh objects, both gradients
 * for points, and diffuse and specular color on rotations. At this point static is intended just for
 * introducing a new feature. It optimizes graph rendering and is ideal for large non-changing data
 * sets. It is slower with dynamic data changes and item rotations. Selection is not optimized, so using it
 * with massive data sets is not advisable.
 * Defaults to \c{OptimizationDefault}
 */

/*!
 * \qmlproperty bool AbstractGraph3D::reflection
 * \since QtDataVisualization 1.2
 *
 * Sets floor reflections on or off. Defaults to \c{false}.
 *
 * \note Affects only Bars3D.
 *
 * \sa reflectivity
 */

/*!
 * \qmlproperty real AbstractGraph3D::reflectivity
 * \since QtDataVisualization 1.2
 *
 * Adjusts floor reflectivity, larger number being more reflective. Valid range is \c{[0...1]}.
 * Defaults to \c{0.5}.
 *
 * \note Affects only Bars3D.
 *
 * \sa reflection
 */