pub struct DiffuseAreaLight {
pub l_emit: Spectrum,
pub shape: Arc<Shape>,
pub two_sided: bool,
pub area: Float,
pub flags: u8,
pub n_samples: i32,
pub medium_interface: MediumInterface,
}
Fields
l_emit: Spectrum
shape: Arc<Shape>
two_sided: bool
area: Float
flags: u8
n_samples: i32
medium_interface: MediumInterface
Implementations
sourceimpl DiffuseAreaLight
impl DiffuseAreaLight
pub fn new(
_light_to_world: &Transform,
medium_interface: &MediumInterface,
l_emit: &Spectrum,
n_samples: i32,
shape: Arc<Shape>,
two_sided: bool
) -> Self
pub fn sample_li<'a, 'b>(
&'b self,
iref: &'a InteractionCommon,
light_intr: &'b mut InteractionCommon,
u: Point2f,
wi: &mut Vector3f,
pdf: &mut Float,
vis: &mut VisibilityTester<'a, 'b>
) -> Spectrum
pub fn power(&self) -> Spectrum
pub fn preprocess(&self, _scene: &Scene)
pub fn le(&self, _ray: &Ray) -> Spectrum
pub fn pdf_li(&self, iref: &dyn Interaction, wi: &Vector3f) -> Float
pub fn sample_le(
&self,
u1: Point2f,
u2: Point2f,
_time: Float,
ray: &mut Ray,
n_light: &mut Normal3f,
pdf_pos: &mut Float,
pdf_dir: &mut Float
) -> Spectrum
pub fn pdf_le(
&self,
ray: &Ray,
n: &Normal3f,
pdf_pos: &mut Float,
pdf_dir: &mut Float
)
pub fn get_flags(&self) -> u8
pub fn get_n_samples(&self) -> i32
pub fn l(&self, intr: &InteractionCommon, w: &Vector3f) -> Spectrum
Auto Trait Implementations
impl !RefUnwindSafe for DiffuseAreaLight
impl Send for DiffuseAreaLight
impl Sync for DiffuseAreaLight
impl Unpin for DiffuseAreaLight
impl !UnwindSafe for DiffuseAreaLight
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more