# AI Manga/Manhwa Parallax Animator Description ----------- AI-powered tool to create dynamic parallax animations from manga or manhwa artwork. The tool analyzes static illustrations and generates cinematic motion effects — parallax layers, camera zooms, shakes, and style-preserving movements — and can export sequences compatible with After Effects for further refinement. Key Features ------------ - AI-Powered Motion Analysis: layer detection, matting, and depth estimation stubs provided - Dynamic Zoom & Shake Effects: camera-path and procedural shake modules (stubs) - Style Preservation: designed to keep original line art and halftone textures - After Effects Integration: JSON export template and exporter class - CLI for quick iteration and example demo Quickstart ---------- 1. Clone the repository 2. Create a virtualenv and install dependencies: pip install -r requirements.txt 3. Run the demo (replace `input.png` with your artwork): python -m animator.cli --input examples/sample_art.png --output out.mp4 --export-ae out_ae.json Project layout -------------- - README.md — this file - LICENSE — MIT license - requirements.txt — minimal Python deps - .gitignore - src/animator/ — core Python package - core.py — processing pipeline and primary classes - ae_exporter.py — After Effects export helper - scripts/cli.py — command-line entrypoint - examples/demo.py — demo pipeline runner - aftereffects/export_template.json — AE-friendly JSON structure template Architecture (high-level) ------------------------- 1. Input image -> Preprocessing (resize, normalize) 2. Layer & matte extraction (segmentation / matting models) 3. Depth / parallax map estimation 4. Motion plan generation (paths, camera zooms, shakes) 5. Frame synthesis / compositing (render frames with transforms + optional style-preservation passes) 6. Export video (MP4 / WebM) and After Effects JSON for further refinement Extending the scaffold ---------------------- - Replace stubbed implementations in `src/animator/core.py` with your chosen ML models (e.g., U^2-Net for matting, MiDaS or custom depth estimator). - Implement a GPU-accelerated renderer that composes per-layer transforms and output frames. - Expand `ae_exporter.py` to match your After Effects scripting workflow or JSON schema expected by third-party AE importers. License ------- MIT. See LICENSE file. Contributing ------------ Pull requests and issues are welcome. For major changes, open an issue first to discuss the plan.