本页内容

Qt3DExtras::QNormalDiffuseMapAlphaMaterial Class

class Qt3DExtras::QNormalDiffuseMapAlphaMaterial

QNormalDiffuseMapAlphaMaterial 提供了对QNormalDiffuseMapMaterial 的特化实现,支持透明度覆盖,并在渲染阶段执行深度测试。更多内容...

头文件: #include <qnormaldiffusemapalphamaterial.h>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3dextras)
target_link_libraries(mytarget PRIVATE Qt6::3dextras)
qmake: QT += 3dextras
继承自: Qt3DExtras::QNormalDiffuseMapMaterial
状态: 已弃用

该类已被弃用。我们强烈建议不要在新代码中使用它。

公共函数

QNormalDiffuseMapAlphaMaterial(Qt3DCore::QNode *parent = nullptr)
virtual ~QNormalDiffuseMapAlphaMaterial()

详细说明

此类已弃用;请改用Qt3DExtras::QDiffuseSpecularMaterial 。

镜面反射光效基于环境光、漫反射和镜面反射这三个光照组件的组合。这些组件的相对强度通过其反射系数来控制,这些系数以 RGB 三元组的形式建模:

  • 环境光是指在没有任何其他光源的情况下,物体所发出的颜色。
  • 漫反射是指粗糙表面在光线照射下产生的反射颜色。
  • 镜面反射是指光线在光滑表面上反射时所呈现的颜色。
  • 表面的光泽度由一个浮点属性控制。

该材质采用单渲染通道的方法,并执行基于片段的照明计算。提供了适用于 OpenGL 2、OpenGL 3 或更高版本以及 OpenGL ES 2 的技术实现。

成员函数文档

[explicit] QNormalDiffuseMapAlphaMaterial::QNormalDiffuseMapAlphaMaterial(Qt3DCore::QNode *parent = nullptr)

创建一个新的 QNormalDiffuseMapAlphaMaterial 实例,其父对象为parent 。

[virtual noexcept] QNormalDiffuseMapAlphaMaterial::~QNormalDiffuseMapAlphaMaterial()

销毁该QNormalDiffuseMapAlphaMaterial 实例。

© 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.