CFx SDK Documentation  2020SP3
AveLight.h
Go to the documentation of this file.
1 // Copyright (C) 2002-2017, Open Design Alliance (the "Alliance").
3 // All rights reserved.
4 //
5 // This software and its documentation and related materials are owned by
6 // the Alliance. The software may only be incorporated into application
7 // programs owned by members of the Alliance, subject to a signed
8 // Membership Agreement and Supplemental Software License Agreement with the
9 // Alliance. The structure and organization of this software are the valuable
10 // trade secrets of the Alliance and its suppliers. The software is also
11 // protected by copyright law and international treaty provisions. Application
12 // programs incorporating this software must include the following statement
13 // with their copyright notices:
14 //
15 // This application incorporates Teigha(R) software pursuant to a license
16 // agreement with Open Design Alliance.
17 // Teigha(R) Copyright (C) 2002-2017 by Open Design Alliance.
18 // All rights reserved.
19 //
20 // By use of this software, its documentation or related materials, you
21 // acknowledge and accept the above terms.
23 
24 
25 
26 #ifndef OD_AVELIGHT_H
27 #define OD_AVELIGHT_H
28 
29 #include "TD_PackPush.h"
30 
31 #include "RxObject.h"
32 #include "DbObjectId.h"
33 #include "IdArrays.h"
34 #include "Ve/AveDefs.h"
35 #include "Gs/GsLight.h"
36 
37 class OdGePoint3d;
38 class OdGeVector3d;
39 
40 class OdAveLightImpl;
41 class OdAveLight;
46 
47 
58 {
59 public:
61 
72  static OdAveLightPtr getLight(const OdDbObjectId& blockRefId);
78  static OdString getLightName(const OdDbObjectId& blockRefId);
79 
88  OdResult writeLight(OdDbDatabase* pDb = 0, const OdDbHandle& holderHandle = 0, const OdDbObjectId& ownerId = OdDbObjectId::kNull);
89 
118 
123  OdString name() const;
124 
131  void setName(const OdString& name);
132 
138  double intensity() const;
143  void setIntensity(double intensity);
144 
151  OdUInt32 color() const;
152 
158  void setColor(OdUInt32 color);
159 
164 
169 
174 
180  void setPosition(const OdGePoint3d& position);
181 
187  void setTarget(const OdGePoint3d& target);
194  void setDirection(const OdGePoint3d& fromPoint, const OdGePoint3d& toPoint);
195 
210 
226 
246  double innerConeAngle() const;
259  double outerConeAngle() const;
260 
274  void setConeAngle(double innerConeAngle, double outerConeAngle);
275 
279  bool isShadowOn() const;
284  void setShadowOn(bool shadowOn);
285 
290  bool isShadowVolumes() const;
295  void setShadowVolumes(bool);
296 
309 
323  void shadowMapSize(OdInt16 mapSize);
324 
334  double shadowSoftness() const;
346  void setShadowSoftness(double shadowSoftness);
347 
353  void shadowBoundingObjects(OdDbObjectIdArray& objectIds) const;
363  void addShadowBoundingObject(const OdDbObjectId& objectId);
364 
369 
370 protected:
375  OdAveLight(OdAveLightImpl* pImpl);
376 
377  OdAveLightImpl* m_pImpl;
378 };
379 
387 
388 #include "TD_PackPop.h"
389 
390 #endif // OD_AVELIGHT_H
391 
OdAveLight::shadowBoundingObjects
void shadowBoundingObjects(OdDbObjectIdArray &objectIds) const
OdResult
OdResult
Definition: OdResult.h:29
OdAveLight::setColor
void setColor(OdUInt32 color)
OdAveLight::intensity
double intensity() const
OdGeVector3d
Definition: GeVector3d.h:54
OdString
Definition: OdString.h:95
OdDbDatabase
Definition: DbDatabase.h:421
OdAveLight
Definition: AveLight.h:58
OdAveLight::getLight
static OdAveLightPtr getLight(const OdDbObjectId &blockRefId)
OdAveLight::setConeAngle
void setConeAngle(double innerConeAngle, double outerConeAngle)
name
GLuint const GLchar * name
Definition: gles2_ext.h:265
OdAveLight::shadowMapSize
void shadowMapSize(OdInt16 mapSize)
OdAveLight::setShadowVolumes
void setShadowVolumes(bool)
IdArrays.h
oddbGetLights
AVE_EXPORT OdRxIteratorPtr oddbGetLights(OdDbDatabase *pDb)
OdAveLight::outerConeAngle
double outerConeAngle() const
type
GLuint GLsizei GLsizei GLint GLenum * type
Definition: gles2_ext.h:274
OdAveLight::shadowMapSize
OdInt16 shadowMapSize() const
OdAveLight::target
OdGePoint3d target() const
OdDbObjectId
Definition: DbObjectId.h:99
OdAveLight::setShadowOn
void setShadowOn(bool shadowOn)
OdAveLight::OdAveLight
OdAveLight()
OdArray< OdDbObjectId, OdMemoryAllocator< OdDbObjectId > >
TD_PackPop.h
OdAveLight::setAttenuation
void setAttenuation(OdGsLight::LightAttenuation attenuation)
OdAveLight::setShadowBoundingObjects
void setShadowBoundingObjects(const OdDbObjectIdArray &objectIds)
OdGsLight::LightAttenuation
LightAttenuation
Definition: GsLight.h:52
OdAveLight::setTarget
void setTarget(const OdGePoint3d &target)
OdAveLight::innerConeAngle
double innerConeAngle() const
RxObject.h
OdUInt32
unsigned int OdUInt32
Definition: OdPlatformSettings.h:783
OdInt16
short OdInt16
Definition: OdPlatformSettings.h:756
GsLight.h
OdAveLightPtr
OdSmartPtr< OdAveLight > OdAveLightPtr
Definition: AveLight.h:41
OdAveLight::type
OdGsLight::LightType type() const
OdAveLight::color
OdUInt32 color() const
OdAveLight::addShadowBoundingObject
void addShadowBoundingObject(const OdDbObjectId &objectId)
OdAveLight::setPosition
void setPosition(const OdGePoint3d &position)
OdSmartPtr
Definition: SmartPtr.h:58
OdGePoint3d
Definition: GePoint3d.h:55
OdGsLight::LightType
LightType
Definition: GsLight.h:45
AveDefs.h
OdAveLight::ODRX_DECLARE_MEMBERS
ODRX_DECLARE_MEMBERS(OdAveLight)
DbObjectId.h
OdAveLight::OdAveLight
OdAveLight(OdAveLightImpl *pImpl)
OdAveLight::setShadowSoftness
void setShadowSoftness(double shadowSoftness)
OdDbObjectId::kNull
static TOOLKIT_EXPORT_STATIC const OdDbObjectId kNull
Definition: DbObjectId.h:118
OdAveLight::setDirection
void setDirection(const OdGePoint3d &fromPoint, const OdGePoint3d &toPoint)
OdAveLight::position
OdGePoint3d position() const
OdAveLight::setType
void setType(OdGsLight::LightType type)
OdAveLight::isShadowOn
bool isShadowOn() const
TD_PackPush.h
OdAveLight::m_pImpl
OdAveLightImpl * m_pImpl
Definition: AveLight.h:377
OdAveLight::attenuation
OdGsLight::LightAttenuation attenuation() const
OdAveLight::isShadowVolumes
bool isShadowVolumes() const
OdAveLight::getLightName
static OdString getLightName(const OdDbObjectId &blockRefId)
OdAveLight::setIntensity
void setIntensity(double intensity)
OdAveLight::name
OdString name() const
OdDbHandle
Definition: DbHandle.h:67
OdGsLight
Definition: GsLight.h:40
OdAveLight::direction
OdGeVector3d direction() const
OdAveLight::writeLight
OdResult writeLight(OdDbDatabase *pDb=0, const OdDbHandle &holderHandle=0, const OdDbObjectId &ownerId=OdDbObjectId::kNull)
OdAveLight::shadowSoftness
double shadowSoftness() const
OdAveLight::holderId
OdDbObjectId holderId() const
AVE_EXPORT
#define AVE_EXPORT
Definition: AveExport.h:37
OdAveLight::setName
void setName(const OdString &name)