diff --git a/frontend/src/lib/components/SettingsPanel.svelte b/frontend/src/lib/components/SettingsPanel.svelte index 3de3af1..b6f6efb 100644 --- a/frontend/src/lib/components/SettingsPanel.svelte +++ b/frontend/src/lib/components/SettingsPanel.svelte @@ -295,7 +295,7 @@ type="range" bind:value={config.processing.blur.min_sharpness} min="10" - max="50" + max="150" step="1" /> {Number(config.processing.blur.min_sharpness).toFixed(0)} diff --git a/src/config.rs b/src/config.rs index a97bf29..d28e3c1 100644 --- a/src/config.rs +++ b/src/config.rs @@ -184,7 +184,7 @@ impl Default for BlurConfig { fn default() -> Self { Self { enabled: true, - min_sharpness: 100.0, + min_sharpness: 75.0, } } } diff --git a/src/pipeline/mod.rs b/src/pipeline/mod.rs index 5f5d562..7fb84e8 100644 --- a/src/pipeline/mod.rs +++ b/src/pipeline/mod.rs @@ -100,8 +100,8 @@ impl Pipeline { /// 2. DecodeImageStep - Load and orient the image (always) /// 3. CropAndResizeStep - Extract face region with padding and resize to output size (always) /// 4. BrightnessStep - Filter by luminance on face region within cropped image (if enabled) - /// 5. BlurStep - Filter blurry images using gradient magnitude (if enabled) - /// 6. HeadPoseStep - Filter non-frontal faces (if enabled) + /// 5. HeadPoseStep - Filter non-frontal faces (if enabled) + /// 6. BlurStep - Filter blurry images using gradient magnitude (if enabled) /// 7. LandmarksStep - Detect 68 facial landmarks (always) /// 8. EyeFilterStep - Filter closed eyes by EAR (if enabled) /// 9. AlignmentStep - Align face based on eye positions and resize to final output (always) @@ -127,16 +127,16 @@ impl Pipeline { pipeline.add_step(Box::new(BrightnessStep)); } - // Optional: Blur detection - if config.processing.blur.enabled { - pipeline.add_step(Box::new(BlurStep)); - } - // Optional: Head pose validation if config.processing.head_pose.enabled { pipeline.add_step(Box::new(HeadPoseStep)); } + // Optional: Blur detection + if config.processing.blur.enabled { + pipeline.add_step(Box::new(BlurStep)); + } + // Core: Always detect landmarks (required for alignment) pipeline.add_step(Box::new(LandmarksStep)); @@ -166,8 +166,8 @@ impl Pipeline { pipeline.add_step(Box::new(DecodeImageStep)); pipeline.add_step(Box::new(CropAndResizeStep)); pipeline.add_step(Box::new(BrightnessStep)); - pipeline.add_step(Box::new(BlurStep)); pipeline.add_step(Box::new(HeadPoseStep)); + pipeline.add_step(Box::new(BlurStep)); pipeline.add_step(Box::new(LandmarksStep)); pipeline.add_step(Box::new(EyeFilterStep)); pipeline.add_step(Box::new(AlignmentStep));