20 void setGeometry(
const std::shared_ptr<Geometry>& geometry);
21 void setMaterial(
const std::shared_ptr<Material>& material);
25 std::shared_ptr<Geometry> m_geometry;
26 std::shared_ptr<Material> m_material;
27 std::shared_ptr<Image> m_emittedEnergy;
28 bool m_isBackFaceEmit;
33 ClassType clazz(
"model-light");
34 clazz.docName(
"Model Light Actor");
36 "A light source that emits energy from the surface of a geometry. A surface material model "
37 "can also be given to describe its surface appearance.");
41 geometry.description(
"A geometry that defines the surface energy is going to emit from.");
43 clazz.addField(geometry);
46 material.
description(
"A material that describes this source's surface appearance.");
48 clazz.addField(material);
52 "An image that describes the emitted energy (e.g., radiance) across the surface.");
54 clazz.addField(emittedEnergy);
57 isBackFaceEmit.
description(
"Whether the energy should emit from the back face of the geometry.");
60 clazz.addField(isBackFaceEmit);
Definition AGeometricLight.h:18
Definition AModelLight.h:11
std::shared_ptr< Material > getMaterial(const CookingContext &ctx) const override
Definition AModelLight.cpp:22
void setBackFaceEmit(bool isBackFaceEmit)
Definition AModelLight.cpp:92
const Emitter * buildEmitter(const CookingContext &ctx, TSpanView< const Primitive * > lightPrimitives) const override
Definition AModelLight.cpp:27
std::shared_ptr< Geometry > getGeometry(const CookingContext &ctx) const override
Definition AModelLight.cpp:17
void setGeometry(const std::shared_ptr< Geometry > &geometry)
Definition AModelLight.cpp:80
PH_DEFINE_SDL_CLASS(TSdlOwnerClass< AModelLight >)
Definition AModelLight.h:31
void setMaterial(const std::shared_ptr< Material > &material)
Definition AModelLight.cpp:86
Information about the world being cooked.
Definition CookingContext.h:24
An electromagnetic energy emitting source. The emitted energy can be captured by a Receiver.
Definition Emitter.h:68
A field class that binds a bool member variable.
Definition TSdlBool.h:21
SDL binding type for a canonical SDL resource class.
Definition TSdlOwnerClass.h:23
A value that points to a SDL resource.
Definition TSdlReference.h:21
TSdlReference & optional()
Definition TSdlReference.ipp:214
TSdlReference & description(std::string descriptionStr)
Definition TSdlReference.ipp:206
TSdlValue & description(std::string descriptionStr)
Definition TSdlValue.ipp:95
TSdlValue & optional()
Definition TSdlValue.ipp:103
TSdlValue & defaultTo(T defaultValue)
Definition TSdlValue.ipp:71
The root for all renderer implementations.
Definition EEngineProject.h:6
std::span< const T, EXTENT > TSpanView
Same as TSpan, except that the objects are const-qualified. Note that for pointer types,...
Definition TSpan.h:19