CFx SDK Documentation
2022 SP0
|
#include <AveLight.h>
Static Public Member Functions | |
static OdAveLightPtr | getLight (const OdDbObjectId &blockRefId) |
static OdString | getLightName (const OdDbObjectId &blockRefId) |
Static Public Member Functions inherited from OdRxObject | |
static OdRxObjectPtr | cast (const OdRxObject *pointer) |
static OdRxClass * | desc () |
Protected Member Functions | |
OdAveLight () | |
OdAveLight (OdAveLightImpl *pImpl) | |
Protected Attributes | |
OdAveLightImpl * | m_pImpl |
Additional Inherited Members | |
Public Types inherited from OdGsLight | |
enum | LightType { kPointLight = 0 , kDistantLight = 1 , kSpotlight = 2 } |
enum | LightAttenuation { kAttenNone = 0 , kAttenInverseLinear = 1 , kAttenInverseSquare = 2 } |
This class represents AVE Light properties.
Corresponding C++ library: TD_Ave <group OdAve_Classes>
Definition at line 57 of file AveLight.h.
|
protected |
Constructors
|
protected |
void OdAveLight::addShadowBoundingObject | ( | const OdDbObjectId & | objectId | ) |
Adds the specified OdDbDatabase object to the shadow bounding objects for this Light object.
objectId | [in] Object ID to add. |
|
virtual |
Returns the attenuation of this Light object.
Value
OdGsLight::kAttenNone 0
OdGsLight::kAttenInverseLinear 1
OdGsLight::kAttenInverseSquare 2
Implements OdGsLight.
|
virtual |
|
virtual |
Returns the WCS direction of this Light object.
Implements OdGsLight.
|
static |
Creates a Light object from the specified OdDbBlockReference.
blockRefId | [in] Object ID of the block reference. |
Returns a SmartPointer to the new Light object.
|
static |
Returns the Light name from the specified OdDbBlockReference.
blockRefId | [in] Object ID of the block reference. |
OdDbObjectId OdAveLight::holderId | ( | ) | const |
Returns the Object ID of the OdDbBlockReference associated with this Light object.
double OdAveLight::innerConeAngle | ( | ) | const |
Specifies the cone angles for spotlight (OdAve::kSpotLight). Inner cone defines the brightest cone of light(hotspot, beam angle). Outer cone defines the full cone of light(falloff, field angle). These values can range from 0 to 80 degrees.
Returns the inner cone angle for this kSpotLight Light object.
innerConeAngle() has a range of [0..80].
|
virtual |
Returns the intensity of this Light object.
Implements OdGsLight.
bool OdAveLight::isShadowOn | ( | ) | const |
Returns true if and only if shadows are enabled for this Light object.
bool OdAveLight::isShadowVolumes | ( | ) | const |
Returns true if and only if volumetric/raytraced shadows are enabled for this Light object.
OdString OdAveLight::name | ( | ) | const |
Returns the name of this Light object.
OdAveLight::ODRX_DECLARE_MEMBERS | ( | OdAveLight | ) |
double OdAveLight::outerConeAngle | ( | ) | const |
Returns the outer cone angle for this kSpotLight Light object.
outerConeAngle() has a range of [0..80].
|
virtual |
Returns the WCS position of this Light object.
Implements OdGsLight.
void OdAveLight::setAttenuation | ( | OdGsLight::LightAttenuation | attenuation | ) |
Sets the attenuation of this Light object.
attenuation | [in] Attenuation. |
Value
OdGsLight::kAttenNone 0
OdGsLight::kAttenInverseLinear 1 OdGsLight::kAttenInverseSquare 2
Sets the color of this Light object.
color | [in] 24-bit RGB color. |
void OdAveLight::setConeAngle | ( | double | innerConeAngle, |
double | outerConeAngle | ||
) |
Sets the cone angles for this kSpotLight Light object.
innerConeAngle | [in] Inner cone angle. [0..80] |
outerConeAngle | [in] Outer cone angle. [0..80] |
The outer cone angle is one-half the field angle, which defines the falloff or full cone of light.
void OdAveLight::setDirection | ( | const OdGePoint3d & | fromPoint, |
const OdGePoint3d & | toPoint | ||
) |
Sets the WCS direction of this Light object.
fromPoint | [in] From point. |
toPoint | [in] To point. |
void OdAveLight::setIntensity | ( | double | intensity | ) |
Sets the intensity of this Light object.
intensity | [in] Intensity. [0.0 .. 1.0] |
Sets the name of this Light object.
name | [in] Name. |
void OdAveLight::setPosition | ( | const OdGePoint3d & | position | ) |
Sets the WCS position of this Light object.
position | [in] Position. |
void OdAveLight::setShadowBoundingObjects | ( | const OdDbObjectIdArray & | objectIds | ) |
Sets the shadow bounding objects for this Light object.
objectIds | [in] Array of Object IDs. |
void OdAveLight::setShadowOn | ( | bool | shadowOn | ) |
Controls shadows for this Light object.
shadowOn | [in] Controls shadows. |
void OdAveLight::setShadowSoftness | ( | double | shadowSoftness | ) |
Sets the softness (fuzziness) of shadow-mapped shadows for this Light object.
shadowSoftness | [in] Shadow softness. [1..10] |
Values in the range [2..4] typically give the best results.
void OdAveLight::setShadowVolumes | ( | bool | ) |
Controls volumetric/raytraced shadows for this Light object.
shadowVolumes | [in] Controls shadows. |
void OdAveLight::setTarget | ( | const OdGePoint3d & | target | ) |
Sets the WCS target of this Light object.
target | [in] Target. |
void OdAveLight::setType | ( | OdGsLight::LightType | type | ) |
Sets the type of this Light object.
type | [in] Light type. |
Value OdGsLight::kPointLight 0 OdGsLight::kDistantLight 1 OdGsLight::kSpotlight 2
void OdAveLight::shadowBoundingObjects | ( | OdDbObjectIdArray & | objectIds | ) | const |
Returns the shadow bounding objects for this Light object.
objectIds | [out] Receives the array of Object IDs. |
OdInt16 OdAveLight::shadowMapSize | ( | ) | const |
Accesses the size of the shadow map for this Light object.
The smaller the size, the faster but less accurate the rendering.
Accesses the size of the shadow map for this Light object.
mapSize | [in] Shadow map size. [64..4096] |
The smaller the size, the faster but less accurate the rendering.
double OdAveLight::shadowSoftness | ( | ) | const |
Returns the softness (fuzziness) of shadow-mapped shadows for this Light object.
Shadow softness represents the number of shadow-edge pixels blended into the image.
|
virtual |
Returns the WCS target of this Light object.
Implements OdGsLight.
|
virtual |
Returns the type of this Light object.
Value OdGsLight::kPointLight 0 OdGsLight::kDistantLight 1 OdGsLight::kSpotlight 2
Implements OdGsLight.
OdResult OdAveLight::writeLight | ( | OdDbDatabase * | pDb = 0 , |
const OdDbHandle & | holderHandle = 0 , |
||
const OdDbObjectId & | ownerId = OdDbObjectId::kNull |
||
) |
Saves the Light properties to the OdDbBlockReference to which this Light object is associated.
pDb | [in] Pointer to the database. |
|
protected |
Definition at line 377 of file AveLight.h.