MCPcopy Create free account
hub / github.com/RenderKit/ospray / commit

Method commit

modules/cpu/lights/PointLight.cpp:69–86  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

67}
68
69void PointLight::commit()
70{
71 Light::commit();
72 position = getParam<vec3f>("position", vec3f(0.f));
73 radius = getParam<float>("radius", 0.f);
74
75 // per default perpendicular to direction
76 direction = getParam<vec3f>("direction", vec3f(0.f, 0.f, 1.f));
77 intensityDistribution.c0 = std::abs(direction.x) < std::abs(direction.y)
78 ? vec3f(0.0f, direction.z, direction.y)
79 : vec3f(direction.z, 0.0f, direction.x);
80 intensityDistribution.readParams(*this);
81
82 queryIntensityQuantityType(intensityDistribution
83 ? OSP_INTENSITY_QUANTITY_SCALE
84 : OSP_INTENSITY_QUANTITY_INTENSITY);
85 processIntensityQuantityType();
86}
87
88void PointLight::processIntensityQuantityType()
89{

Callers

nothing calls this directly

Calls 2

commitFunction · 0.50
readParamsMethod · 0.45

Tested by

no test coverage detected