Surface3D QML Type

3D 서피스 그래프의 사용법을 설명합니다. 더 보기...

Import Statement: import QtDataVisualization 1.8
Since: QtDataVisualization 1.0
Inherits:

AbstractGraph3D

속성

방법

상세 설명

이 유형을 사용하면 개발자가 Qt Quick 을 사용하여 표면 플롯을 3D로 렌더링할 수 있습니다.

이 유형을 사용하려면 데이터 시각화 모듈을 가져와야 합니다:

import QtDataVisualization 1.2

그런 다음 qml 파일에서 Surface3D를 사용할 수 있습니다:

import QtQuick 2.0
import QtDataVisualization 1.2

Item {
    width: 640
    height: 480

    Surface3D {
        width: parent.width
        height: parent.height
        Surface3DSeries {
            itemLabelFormat: "Pop density at (@xLabel N, @zLabel E): @yLabel"
            ItemModelSurfaceDataProxy {
                itemModel: dataModel
                // Mapping model roles to surface series rows, columns, and values.
                rowRole: "longitude"
                columnRole: "latitude"
                yPosRole: "pop_density"
            }
        }
    }
    ListModel {
        id: dataModel
        ListElement{ longitude: "20"; latitude: "10"; pop_density: "4.75"; }
        ListElement{ longitude: "21"; latitude: "10"; pop_density: "3.00"; }
        ListElement{ longitude: "22"; latitude: "10"; pop_density: "1.24"; }
        ListElement{ longitude: "23"; latitude: "10"; pop_density: "2.53"; }
        ListElement{ longitude: "20"; latitude: "11"; pop_density: "2.55"; }
        ListElement{ longitude: "21"; latitude: "11"; pop_density: "2.03"; }
        ListElement{ longitude: "22"; latitude: "11"; pop_density: "3.46"; }
        ListElement{ longitude: "23"; latitude: "11"; pop_density: "5.12"; }
        ListElement{ longitude: "20"; latitude: "12"; pop_density: "1.37"; }
        ListElement{ longitude: "21"; latitude: "12"; pop_density: "2.98"; }
        ListElement{ longitude: "22"; latitude: "12"; pop_density: "3.33"; }
        ListElement{ longitude: "23"; latitude: "12"; pop_density: "3.23"; }
        ListElement{ longitude: "20"; latitude: "13"; pop_density: "4.34"; }
        ListElement{ longitude: "21"; latitude: "13"; pop_density: "3.54"; }
        ListElement{ longitude: "22"; latitude: "13"; pop_density: "1.65"; }
        ListElement{ longitude: "23"; latitude: "13"; pop_density: "2.67"; }
    }
}

자세한 사용 예는 표면 그래프 갤러리를 참조하세요.

Surface3DSeries, ItemModelSurfaceDataProxy, Bars3D, Scatter3D, 및 Qt Data Visualization C++ Classes.

속성 문서

axisX : ValueAxis3D

활성 X축입니다.

축을 지정하지 않으면 레이블이 없고 자동으로 조정되는 범위가 있는 임시 기본 축이 생성됩니다. 이 임시 축은 다른 축이 명시적으로 같은 방향으로 설정되어 있으면 삭제됩니다.


axisY : ValueAxis3D

활성 Y 축입니다.

축을 지정하지 않으면 레이블이 없고 자동으로 조정되는 범위가 있는 임시 기본 축이 생성됩니다. 이 임시 축은 다른 축이 명시적으로 같은 방향으로 설정되면 삭제됩니다.


axisZ : ValueAxis3D

활성 Z축입니다.

축을 지정하지 않으면 레이블이 없고 자동으로 조정되는 범위가 있는 임시 기본 축이 생성됩니다. 이 임시 축은 다른 축이 명시적으로 같은 방향으로 설정되면 삭제됩니다.


flipHorizontalGrid : bool [since QtDataVisualization 1.2]

일부 사용 사례에서는 가로축 그리드가 대부분 표면에 가려져 있으므로 가로축 그리드를 그래프 아래쪽이 아닌 위에 표시하는 것이 더 유용할 수 있습니다. 이에 대한 일반적인 사용 사례는 하향식 시점의 직교 투영을 사용하여 2D 스펙트로그램을 표시하는 것입니다.

false 인 경우 가로축 그리드와 레이블이 그래프의 가로 배경에 그려집니다. true 인 경우 가로축 그리드와 레이블이 그래프의 가로 배경과 반대쪽에 그려집니다. 기본값은 false 입니다.

이 속성은 QtDataVisualization 1.2에 도입되었습니다.


selectedSeries : Surface3DSeries

선택된 계열 또는 null입니다. selectionModeSelectionMultiSeries 플래그가 설정되어 있는 경우, 이 속성은 선택한 점을 소유하는 계열을 보유합니다.


seriesList : list<Surface3DSeries> [default]

이 속성은 그래프의 계열을 보유합니다. 기본적으로 이 속성에는 빈 목록이 포함됩니다. 계열을 설정하려면 addSeries() 함수를 사용하거나 그래프의 자식으로 정의합니다.


메서드 문서

void addSeries(Surface3DSeries series)

그래프에 series 를 추가합니다.

AbstractGraph3D::hasSeries()도 참조하세요 .


void removeSeries(Surface3DSeries series)

그래프에서 series 을 제거합니다.

AbstractGraph3D::hasSeries()도 참조 하세요.


© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.