Changes
- Updated the
filter::RayTracing
APIs to avoid accidentally passing incorrect image parameter configurations. This resolves #7 and #5 . The execute
method will now only accept valid configurations for the filter:
pub fn execute(&mut self, color: &[f32], output: &mut [f32]) -> Result<(), FilterError> {}
pub fn execute_with_albedo(
&mut self,
color: &[f32],
albedo: &[f32],
output: &mut [f32],
) -> Result<(), FilterError> {}
/// Normal requires albedo to be present
pub fn execute_with_albedo_normal(
&mut self,
color: &[f32],
albedo: &[f32],
normal: &[f32],
output: &mut [f32],
) -> Result<(), FilterError> {}