LevelOfDetail QML Type
LevelOfDetailは、画面上のサイズに基づいてレンダリングされるエンティティの複雑さを制御する方法を提供します。詳細...
| Import Statement: | import Qt3D.Render 2.11 |
| In C++: | QLevelOfDetail |
| Inherits: | |
| Status: | Deprecated |
プロパティ
- ThresholdType : enumeration
- camera : Camera
- currentIndex : int
- thresholdType : int
- thresholds : QList<qreal>
- volumeOverride : int
詳細説明
LevelOfDetail を使用すると、観察者からの距離や画面上のサイズに基づいてエンティティの表現を制御できます。
レンダリングのパフォーマンスを向上させるために、非常に小さいオブジェクトは、ジオメトリまたはテクスチャのはるかに少ない詳細を使用してレンダリングすることができます。
このコンポーネントは、カメラからの距離または画面サイズとして解釈される値のしきい値を指定することで制御されます。
視点が変わると、currentIndex プロパティは、範囲配列の一致する値を反映するように変更されます。
currentIndex プロパティは、エンティティの有効化または無効化、EntityLoader のソースの変更、マテリアルの変更などに使用できます。
LevelOfDetail コンポーネントは、複数の Entity 間で共有することはできません。
import Qt3D.Core 2.0 import Qt3D.Render 2.0 Entity { id: root // Scene Camera { id: mainCamera } LevelOfDetail { id: lod camera: mainCamera thresholds: [20, 35, 50, 65] thresholdType: LevelOfDetail.DistanceToCameraThreshold } GeometryRenderer { id: mesh view: CylinderMesh { property var sliceValues: [20, 10, 6, 4] slices: sliceValues[lod.currentIndex] } } Entity { id: renderableEntity components: [ mesh, lod ] } }
プロパティのドキュメント
ThresholdType : enumeration
閾値の値の解釈方法を指定します。
- DistanceToCameraThreshold エンティティから選択されたカメラまでの距離。
- ProjectedScreenPixelSizeThreshold 選択されたカメラから見た,スクリーン上に投影されたときのエンティティのサイズ.
Qt3DRender::QLevelOfDetail::ThresholdTypeも参照してください .
camera : Camera
実際の距離または画面サイズを計算するために使用されるカメラの ID を保持する。
currentIndex : int
現在のカメラまでの距離または画面サイズに一致する範囲配列のインデックス。
thresholdType : int
範囲値の解釈方法を指定する。
thresholds : QList<qreal>
浮動小数点数としての範囲値の配列。最も詳細な表現の値を最初に指定する。
LevelOfDetail::thresholdType がLevelOfDetail.DistanceToCameraThreshold に設定されている場合、値はカメラ空間座標で昇順に指定されるべきです。
LevelOfDetail::thresholdType がLevelOfDetail.ProjectedScreenPixelSizeThreshold に設定されている場合、値はスクリーン空間のピクセル単位で降順に指定されるべきです。
volumeOverride : int
距離または画面サイズの評価に使用するものを指定する。
デフォルトは、半径1でエンティティのローカル原点を中心とする球体です。この代理体積は、カメラまでの距離やスクリーンの投影サイズを計算するために使用されます。
この値をNULLにすると、エンティティのバウンディングボリュームが使用されます。この外接ボリュームが無効にならないように注意する必要があります。
Qt3DRender::QLevelOfDetailBoundingSphereも参照してください 。
© 2026 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.