Skip to content

Potri2357/LineX

Repository files navigation

LineX - Visual Manim Editor

LineX is a powerful, visual-first IDE for creating Manim animations. It bridges the gap between code-based animation and modern video editing, allowing users to create mathematical animations using a drag-and-drop interface, real-time preview, and AI automation.

LineX Editor

🚀 Key Features

🎨 Visual Canvas

  • Drag & Drop: Add shapes (Circles, Squares, Triangles) and Math symbols ($\pi$, $\sum$, $\int$) directly from the toolkit.
  • Direct Manipulation: Select objects to Move, Scale, and Rotate visually.
  • Mini-Tool: A context-aware floating toolbar appears near your selection for quick style edits (Color, Stroke Width).

🤖 Gemini AI Automation

  • Natural Language to Animation: Type prompts like "Create a rotating red square with text" and watch LineX generate the code and render the video automatically.
  • Smart Chat: Authentically styled AI Assistant that helps you write Manim code.
  • Robust Pipeline: Automatically cleans and validates AI-generated code to prevent render errors.

🎬 Professional Timeline

  • Non-Linear Editing: A Premiere Pro-style timeline with V1 (Video) and A1 (Audio) tracks.
  • Clip Management: Drag generated clips to arrange them in time.
  • Transitions: Add visual transitions between your animation clips.

⚡ Real-Time Rendering

  • Instant Preview: Renders scenes in the background and plays them immediately on the canvas.
  • Quality Control: Switch between Low (480p) for fast previews and High (1080p) for final export.

🛠️ Installation

Prerequisites

  1. Python 3.10+
  2. FFmpeg (Required for Manim and video playback)
    • Windows: choco install ffmpeg or download from ffmpeg.org and add to PATH.

Setup

  1. Clone the Repository

    git clone https://github.com/yourusername/LineX.git
    cd LineX
  2. Install Dependencies

    pip install -r requirements.txt

    Note: If you don't have a requirements file yet, install the core packages:

    pip install manim PySide6 google-generativeai python-dotenv
  3. Configure API Keys

    • Create a .env file in the root directory.
    • Add your Google Gemini API Key:
      GEMINI_API_KEY=your_api_key_here

▶️ Usage

  1. Run the Application

    python -m src.main
  2. Workflow

    • Option A (Visual): Drag shapes from the left Toolkit onto the canvas. Use the Properties Panel on the right to adjust them.
    • Option B (AI): Open the AI Assistant panel, type a request, and hit Enter. LineX will generate the code and show you the result.

📂 Project Structure

LineX/
├── src/
│   ├── core/           # Logic (Manim Runner, AI Worker, Signals)
│   ├── ui/             # Interface (Window, Canvas, Panels, Timeline)
│   └── main.py         # Entry Point
├── media/              # Generated Manim videos
├── .env                # API Keys (Git-ignored)
└── requirements.txt    # Python Dependencies

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages