24#ifndef __OD_GI_VIEWPORT_TRAITS_DATA__
25#define __OD_GI_VIEWPORT_TRAITS_DATA__
41 OdDbStub* m_backgroundId;
45 double m_defLightIntensity;
51 OdDbStub* m_renderEnvId;
52 OdDbStub* m_renderSettings;
53 OdDbStub* m_visualStyle;
79 : m_backgroundId(NULL)
80 , m_bDefLightOn(
false)
83 , m_defLightIntensity(0.5)
84 , m_defLightColor(255, 255, 255)
90 , m_renderSettings(NULL)
94 m_pToneOperators = OdGiToneOperatorParameters::createObject();
110 m_backgroundId = backgroundId;
119 return m_backgroundId;
138 return m_bDefLightOn;
164 return m_userDefLightDir;
172 m_userDefLightDir = lightDirection;
181 return m_defLightIntensity;
189 m_defLightIntensity = dIntensity;
198 return m_defLightColor;
206 m_defLightColor = color;
217 return m_defShadowParams;
227 m_defShadowParams =
params;
237 m_colorAmbient = clr;
244 return m_colorAmbient;
261 return m_dBrightness;
288 m_renderEnvId = renderEnvId;
295 return m_renderEnvId;
305 m_renderSettings = renderSettingsId;
312 return m_renderSettings;
324 m_visualStyle = visualStyleId;
334 return m_visualStyle;
347 m_pToneOperators = OdGiPhotographicExposureParameters::createObject();
353 m_pToneOperators = OdGiToneOperatorParameters::createObject();
354 *m_pToneOperators =
params;
367 params = *m_pToneOperators;
374 return *m_pToneOperators;
388 if (bPhoto1 && bPhoto2)
390 else if (!bPhoto1 && !bPhoto2)
418 return ((m_backgroundId == data2.m_backgroundId) &&
419 (m_bDefLightOn == data2.m_bDefLightOn) &&
420 (m_lightType == data2.m_lightType) &&
421 m_userDefLightDir.
isEqualTo(data2.m_userDefLightDir) &&
422 OdEqual(m_defLightIntensity, data2.m_defLightIntensity) &&
423 (m_defLightColor == data2.m_defLightColor) &&
424 (m_colorAmbient == data2.m_colorAmbient) &&
425 OdEqual(m_dBrightness, data2.m_dBrightness) &&
426 OdEqual(m_dContrast, data2.m_dContrast) &&
427 (m_renderEnvId == data2.m_renderEnvId) &&
428 (m_renderSettings == data2.m_renderSettings) &&
429 (m_visualStyle == data2.m_visualStyle) &&
455 return !(*
this == data2);
bool OdEqual(double x, double y, double tol=1.e-10)
bool isEqualTo(const OdGeVector3d &vect, const OdGeTol &tol=OdGeContext::gTol) const
void setShadowsOn(bool on)
static bool compareToneOps(const OdGiToneOperatorParametersPtr &op1, const OdGiToneOperatorParametersPtr &op2)
void setDefaultLightingColor(const OdCmEntityColor &color)
void setDefaultLightingType(OdGiViewportTraits::DefaultLightingType typ)
void setDefaultLightingShadowParameters(const OdGiShadowParameters ¶ms)
void setDefaultLightingIntensity(double dIntensity)
OdGiViewportTraits::DefaultLightingType defaultLightingType() const
void setBrightness(double brightness)
OdDbStub * background() const
void setDefaultLightingOn(bool on)
const OdGiShadowParameters & defaultLightingShadowParameters() const
OdGiDrawable::DrawableType type() const
OdDbStub * visualStyle() const
bool operator!=(const OdGiViewportTraitsData &data2) const
OdGeVector3d userDefinedLightDirection() const
void toneOperatorParameters(OdGiToneOperatorParameters ¶ms) const
void setVisualStyle(OdDbStub *visualStyleId)
OdDbStub * renderEnvironment() const
OdDbStub * renderSettings() const
void setContrast(double contrast)
void setAmbientLightColor(const OdCmEntityColor &clr)
void setRenderEnvironment(OdDbStub *renderEnvId)
const OdCmEntityColor & defaultLightingColor() const
bool isDefaultLightingOn() const
double brightness() const
double defaultLightingIntensity() const
void setToneOperatorParameters(const OdGiToneOperatorParameters ¶ms)
void setUserDefinedLightDirection(const OdGeVector3d &lightDirection)
bool operator==(const OdGiViewportTraitsData &data2) const
const OdCmEntityColor & ambientLightColor() const
const OdGiToneOperatorParameters & toneOperatorParameters() const
void setBackground(OdDbStub *backgroundId)
void setRenderSettings(OdDbStub *renderSettingsId)
static OdRxClass * desc()
bool isKindOf(const OdRxClass *pClass) const