From d6f5f29a2a5624da9934ad5f6e42580b8d9e5337 Mon Sep 17 00:00:00 2001 From: Bruno BELANYI Date: Tue, 17 Mar 2020 22:46:25 +0100 Subject: [PATCH] library: render: rename LightAggregate fields --- src/render/light_aggregate.rs | 35 ++++++++++++++++++----------------- 1 file changed, 18 insertions(+), 17 deletions(-) diff --git a/src/render/light_aggregate.rs b/src/render/light_aggregate.rs index c45cd4b..2407c24 100644 --- a/src/render/light_aggregate.rs +++ b/src/render/light_aggregate.rs @@ -1,11 +1,12 @@ -use crate::light; +use crate::light::*; +use std::iter::Iterator; #[derive(Debug, PartialEq)] pub struct LightAggregate { - ambient_lights: Vec, - directional_lights: Vec, - point_lights: Vec, - spot_lights: Vec, + ambients: Vec, + directionals: Vec, + points: Vec, + spots: Vec, } impl LightAggregate { @@ -14,16 +15,16 @@ impl LightAggregate { } pub fn new( - ambient_lights: Vec, - directional_lights: Vec, - point_lights: Vec, - spot_lights: Vec, + ambients: Vec, + directionals: Vec, + points: Vec, + spots: Vec, ) -> Self { LightAggregate { - ambient_lights, - directional_lights, - point_lights, - spot_lights, + ambients, + directionals, + points, + spots, } } } @@ -44,10 +45,10 @@ mod test { assert_eq!( lights, LightAggregate { - ambient_lights: vec![], - directional_lights: vec![], - point_lights: vec![], - spot_lights: vec![], + ambients: vec![], + directionals: vec![], + points: vec![], + spots: vec![], } ) }