{"id":42499290,"url":"https://github.com/ratatui/tachyonfx","last_synced_at":"2026-02-14T21:18:32.490Z","repository":{"id":243442654,"uuid":"812197206","full_name":"ratatui/tachyonfx","owner":"ratatui","description":"Effects and animation library for Ratatui applications","archived":false,"fork":false,"pushed_at":"2026-02-08T16:27:57.000Z","size":42600,"stargazers_count":1116,"open_issues_count":5,"forks_count":16,"subscribers_count":5,"default_branch":"development","last_synced_at":"2026-02-08T19:29:11.429Z","etag":null,"topics":["nostd","ratatui","tui","tweening","wasm"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ratatui.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2024-06-08T08:00:49.000Z","updated_at":"2026-02-08T16:02:49.000Z","dependencies_parsed_at":"2024-08-26T07:23:39.121Z","dependency_job_id":"c557849e-32be-47da-b80f-2b8dc94a8d23","html_url":"https://github.com/ratatui/tachyonfx","commit_stats":{"total_commits":148,"total_committers":4,"mean_commits":37.0,"dds":"0.060810810810810856","last_synced_commit":"76dba6e713604e1478d6235046060987937f0fb8"},"previous_names":["junkdog/tachyonfx"],"tags_count":28,"template":false,"template_full_name":null,"purl":"pkg:github/ratatui/tachyonfx","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratatui%2Ftachyonfx","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratatui%2Ftachyonfx/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratatui%2Ftachyonfx/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratatui%2Ftachyonfx/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ratatui","download_url":"https://codeload.github.com/ratatui/tachyonfx/tar.gz/refs/heads/development","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratatui%2Ftachyonfx/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29455072,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-14T15:52:44.973Z","status":"ssl_error","status_checked_at":"2026-02-14T15:52:11.208Z","response_time":53,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["nostd","ratatui","tui","tweening","wasm"],"created_at":"2026-01-28T13:02:40.215Z","updated_at":"2026-02-14T21:18:32.460Z","avatar_url":"https://github.com/ratatui.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tachyonfx\n\n[![Crates.io](https://img.shields.io/crates/v/tachyonfx.svg)](https://crates.io/crates/tachyonfx)\n[![Documentation](https://docs.rs/tachyonfx/badge.svg)](https://docs.rs/tachyonfx)\n[![License](https://img.shields.io/crates/l/tachyonfx.svg)](https://github.com/ratatui/tachyonfx/blob/main/LICENSE)\n[![Downloads](https://img.shields.io/crates/d/tachyonfx.svg)](https://crates.io/crates/tachyonfx)\n[![Deps.rs](https://deps.rs/repo/github/ratatui/tachyonfx/status.svg)](https://deps.rs/repo/github/ratatui/tachyonfx)\n\nAn effects and animation library for [Ratatui][ratatui] applications. Build complex animations by composing and\nlayering simple effects, bringing smooth transitions and visual polish to the terminal.\n\n![demo](images/demo-0.6.0.gif)\n\n**[Try exabind](https://junkdog.github.io/exabind/) - experience tachyonfx in your browser without installing anything!**\n\n## Features\n\n- **40+ unique effects** — color transformations, text animations, geometric distortions, plus support for custom effects\n- **Spatial patterns** — control effect timing and distribution with radial, diagonal, checkerboard, and organic patterns\n- **Effect composition** — chain and combine effects for sophisticated animations\n- **Cell-precise targeting** — apply effects to specific regions or cells matching custom criteria\n- **WebAssembly \u0026 no_std support** — run in browsers and embedded environments\n- **Interactive browser editor** — iterate on effects in real-time with [TachyonFX FTL][tfx-ftl] using the built-in DSL\n\n## Quick Start\n\nAdd tachyonfx to your `Cargo.toml`:\n\n```bash\ncargo add tachyonfx\n```\n\nCreate your first effect:\n\n```rust\nuse std::{io, time::Instant};\n\nuse ratatui::{crossterm::event, prelude::*, widgets::Paragraph};\nuse tachyonfx::{fx, EffectManager, Interpolation};\n\nfn main() -\u003e io::Result\u003c()\u003e {\n    let mut terminal = ratatui::init();\n    let mut effects: EffectManager\u003c()\u003e = EffectManager::default();\n\n    // Add a simple fade-in effect\n    let fx = fx::fade_to(Color::Cyan, Color::Gray, (1_000, Interpolation::SineIn));\n    effects.add_effect(fx);\n\n    let mut last_frame = Instant::now();\n    loop {\n        let elapsed = last_frame.elapsed();\n        last_frame = Instant::now();\n\n        terminal.draw(|frame| {\n            let screen_area = frame.area();\n\n            // Render your content\n            let text = Paragraph::new(\"Hello, TachyonFX!\").alignment(Alignment::Center);\n            frame.render_widget(text, screen_area);\n\n            // Apply effects\n            effects.process_effects(elapsed.into(), frame.buffer_mut(), screen_area);\n        })?;\n\n        // Exit on any key press\n        if event::poll(std::time::Duration::from_millis(16))? {\n            if let event::Event::Key(_) = event::read()? {\n                break;\n            }\n        }\n    }\n\n    ratatui::restore();\n    Ok(())\n}\n\n```\n\n## Examples\n\nExplore the examples to see effects in action:\n\n```bash\n# Basic effects showcase\ncargo run -p basic-effects\n\n# Minimal setup example\ncargo run -p minimal\n\n# Interactive effect registry demo\ncargo run -p effect-registry\n\n# Complete effect showcase\ncargo run -p effect-showcase\n\n# Tweening examples\ncargo run -p tweens\n```\n\n## Getting Started\n\n### Try it in your browser\n\n![TachyonFX FTL](https://raw.githubusercontent.com/ratatui/tachyonfx/development/images/tfx-ftl.png)\n\n[TachyonFX FTL][tfx-ftl] is a browser-based editor for creating and tweaking effects in real-time, using\nthe [Effect DSL][dsl-md] (don't worry, it mimics rust syntax).\n\n [dsl-md]: https://github.com/ratatui/tachyonfx/blob/development/docs/dsl.md\n\n### Basic Concepts\n\n1. **Effects are stateful** — Create once, apply every frame\n2. **Effects transform rendered content** — Apply after widgets render  \n3. **Effects compose** — Build complex animations from simple pieces\n\n### Simple Example: Fade In\n\n```rust\n// Create a fade-in effect\nlet mut fade = fx::fade_from(Color::Black, Color::White, \n    EffectTimer::from_ms(500, QuadOut));\n\n// Apply to red text only\nfade.set_cell_filter(CellFilter::FgColor(Color::Red));\n\n// In your render loop\nfade.process(delta_time, buf, area);\n```\n\n### Combining Effects\n\n```rust\n// Run multiple effects in parallel\nlet effects = fx::parallel(\u0026[\n    fx::fade_from_fg(Color::Red, 500),\n    fx::slide_in(Direction::LeftToRight, 800),\n]);\n\n// Or sequence them\nlet effects = fx::sequence(\u0026[\n    fx::fade_from_fg(Color::Black, 300),\n    fx::coalesce(500),\n]);\n```\n\n### Using Patterns\n\nApply spatial patterns to control how effects spread:\n\n```rust\n// Radial dissolve from center\nlet effect = fx::dissolve(800)\n    .with_pattern(RadialPattern::center());\n\n// Diagonal fade with transition width\nlet effect = fx::fade_to_fg(Color::Cyan, 1000)\n    .with_pattern(\n        DiagonalPattern::top_left_to_bottom_right()\n            .with_transition_width(3.0)\n    );\n```\n\n### Using the DSL\n\nCreate effects from strings at runtime:\n\n```rust\nuse tachyonfx::dsl::EffectDsl;\n\nlet effect = EffectDsl::new()\n    .compiler()\n    .compile(\"fx::dissolve(500)\")\n    .expect(\"valid effect\");\n```\n\n## Effect Reference\n\nBelow is a non-exhaustive list of built-in effects.\n\n### Color Effects\nTransform colors over time for smooth transitions.\n\n- `fade_from` / `fade_to` — Transition colors\n- `fade_from_fg` / `fade_to_fg` — Foreground color transitions\n- `hsl_shift` / `hsl_shift_fg` — Animate through HSL color space\n- `term256_colors` — Downsample to 256-color mode\n\n### Text \u0026 Motion Effects\nAnimate text and cell positions for dynamic content.\n\n- `coalesce` / `coalesce_from` — Text materialization effects\n- `dissolve` / `dissolve_to` — Text dissolution effects\n- `evolve` / `evolve_into` / `evolve_from` — Character evolution through symbol sets\n- `slide_in` / `slide_out` — Directional sliding animations\n- `sweep_in` / `sweep_out` — Color sweep transitions\n- `explode` — Particle dispersion effect\n- `expand` — Bidirectional expansion from center\n- `stretch` — Unidirectional stretching with block characters\n\n### Control Effects\nFine-tune timing and behavior.\n\n- `parallel` — Run multiple effects simultaneously\n- `sequence` — Chain effects one after another\n- `repeat` / `repeating` — Loop effects with optional limits or indefinitely\n- `ping_pong` — Play forward then reverse\n- `delay` / `sleep` — Add pauses before or during effects\n- `prolong_start` / `prolong_end` — Extend effect duration\n- `freeze_at` — Freeze effect at specific transition point\n- `remap_alpha` — Remap effect progress to smaller range\n- `run_once` — Ensure effect runs exactly once\n- `never_complete` / `timed_never_complete` — Run indefinitely (with optional time limit)\n- `consume_tick` — Minimal single-frame delay\n- `with_duration` — Override effect duration\n\n### Spatial Patterns\nControl how effects spread and progress across the terminal.\n\n- `RadialPattern` — Expand outward from center point\n- `DiagonalPattern` — Sweep across diagonally\n- `CheckerboardPattern` — Alternate cell-by-cell in grid pattern\n- `SweepPattern` — Linear progression in cardinal directions\n- `CoalescePattern` / `DissolvePattern` — Organic, randomized reveals\n\n### Geometry Effects\nTransform positions and layout.\n\n- `translate` — Move content by offset\n- `resize_area` — Scale effect bounds\n- `translate_buf` — Copy and move buffer content\n\n## Advanced Features\n\n### Cell Filtering\n\nApply effects selectively:\n\n```rust\n// Only apply to cells with specific colors\nfx::dissolve(500)\n    .with_filter(CellFilter::FgColor(Color::Red))\n\n// Target specific regions\nlet filter = CellFilter::AllOf(vec![\n    CellFilter::Outer(Margin::new(1, 1)),\n    CellFilter::Text,\n]);\n```\n\n### Custom Effects\n\nCreate your own effects:\n\n```rust\nfx::effect_fn(state, timer, |state, context, cell_iter| {\n    // Your custom effect logic\n    timer.progress()\n})\n```\n\nAlternatively, implement the `Shader` trait and use it together with `.into_effect()`.\n\n### Effect DSL\n\nThe DSL supports:\n- Most built-in effects (excludes: `effect_fn`, `effect_fn_buf`, `glitch`, `offscreen_buffer`, `resize_area`, `translate`, `translate_buf`)\n- All spatial patterns with method chaining\n- Variable bindings\n- Method chaining\n- Complex compositions\n\n```rust\nlet expr = r#\"\n    let duration = 300;\n    fx::sequence(\u0026[\n        fx::fade_from(black, white, duration),\n        fx::dissolve(duration)\n            .with_pattern(RadialPattern::center())\n    ])\n\"#;\n```\n\n## Configuration\n\n### Features\n\n- `std` — Standard library support (enabled by default)\n- `dsl` — Effect DSL support (enabled by default)\n- `sendable` — Make effects `Send` (but not `Sync`)\n- `std-duration` — Use `std::time::Duration` instead of 32-bit custom type\n- `wasm` — WebAssembly compatibility\n\n\n## Contributing\n\nContributions welcome! Please check existing issues or create new ones to discuss changes.\n\n## License\n\nMIT License - see [LICENSE](LICENSE) for details.\n\n[ratatui]: https://ratatui.rs/\n[tfx-ftl]: https://junkdog.github.io/tachyonfx-ftl/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fratatui%2Ftachyonfx","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fratatui%2Ftachyonfx","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fratatui%2Ftachyonfx/lists"}