QPointLight Class

class Qt3DRender::QPointLight

Qt 3D 씬에서 포인트 라이트 오브젝트를 캡슐화합니다. 더 보기...

Header: #include <QPointLight>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3drender)
target_link_libraries(mytarget PRIVATE Qt6::3drender)
qmake: QT += 3drender
QML에서: PointLight
상속합니다: Qt3DRender::QAbstractLight
상태: Deprecated

속성

공용 기능

QPointLight(Qt3DCore::QNode *parent = nullptr)
float constantAttenuation() const
float linearAttenuation() const
float quadraticAttenuation() const

공용 슬롯

void setConstantAttenuation(float value)
void setLinearAttenuation(float value)
void setQuadraticAttenuation(float value)

신호

void constantAttenuationChanged(float constantAttenuation)
void linearAttenuationChanged(float linearAttenuation)
void quadraticAttenuationChanged(float quadraticAttenuation)

상세 설명

점광원은 한 지점에서 모든 방향으로 빛을 방출하는 광원입니다. 개념적으로는 표준 전구에서 발산하는 빛과 유사합니다.

포인트 조명은 거리에 따라 빛의 강도가 감소하는 방식을 설명하기 위해 세 가지 감쇠 계수를 사용합니다. 이러한 요소는 총 감쇠를 계산할 때 함께 사용하도록 설계되었습니다. Qt3D Extras의 머티리얼에는 다음 공식이 사용되며, 여기서 거리는 광원에서 렌더링되는 표면까지의 거리입니다:

totalAttenuation = 1.0 / (constantAttenuation + (linearAttenuation * distance) + (quadraticAttenuation * distance * distance));

커스텀 머티리얼은 이러한 요소를 다르게 해석하도록 선택할 수 있습니다.

프로퍼티 문서

constantAttenuation : float

포인트 라이트의 상수 감쇠를 지정합니다.

참고: 이 프로퍼티의 정확한 의미와 사용법은 머티리얼 구현에 달려 있습니다.

함수에 액세스합니다:

float constantAttenuation() const
void setConstantAttenuation(float value)

알림 신호:

void constantAttenuationChanged(float constantAttenuation)

linearAttenuation : float

포인트 라이트의 선형 감쇠를 지정합니다.

참고: 이 프로퍼티의 정확한 의미와 사용법은 머티리얼 구현에 달려 있습니다.

함수에 액세스합니다:

float linearAttenuation() const
void setLinearAttenuation(float value)

알림 신호:

void linearAttenuationChanged(float linearAttenuation)

quadraticAttenuation : float

포인트 라이트의 2 차 감쇠를 지정합니다.

참고: 이 프로퍼티의 정확한 의미와 사용법은 머티리얼 구현에 달려 있습니다.

함수에 액세스합니다:

float quadraticAttenuation() const
void setQuadraticAttenuation(float value)

노티파이 신호:

void quadraticAttenuationChanged(float quadraticAttenuation)

멤버 함수 문서

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

지정된 parent 으로 새 QPointLight를 구성합니다.

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