Quick Start Guide

This guide will help you get started with FMUS-VID for video processing.

Installation

# Install basic package
pip install fmusvid

# Install with AI features
pip install fmusvid[ai]

# Install all features
pip install fmusvid[all]

Basic Usage

Loading and Saving Videos

import fmusvid

# Load a video file
video = fmusvid.load("input.mp4")

# Get video information
print(f"Duration: {video.duration} seconds")
print(f"Resolution: {video.width}x{video.height}")
print(f"FPS: {video.fps}")

# Save to different format
video.save("output.webm")

Basic Transformations

# Chain multiple operations
processed = (video
    .trim(start=5, end=15)    # Cut 10 seconds
    .resize(width=1280)       # Resize width, maintain aspect ratio
    .rotate(90)               # Rotate 90 degrees
    .grayscale()             # Convert to grayscale
)

# Save the result
processed.save("processed.mp4")

Audio Operations

# Adjust audio
video = (video
    .volume(0.5)             # Reduce volume to 50%
    .add_audio(
        "music.mp3",
        start=5.0,           # Start at 5 seconds
        volume=0.3           # Background music at 30%
    )
)