module Fluorite::Docs::A_GETTING_STARTED::GETTING_STARTED

Overview

Getting Started with Fluorite

Fluorite is a next-generation Crystal library and developer studio for FFMPEG. It transforms complex, cryptic FFmpeg command strings into expressive, type-safe, and self-documenting Crystal code. Fluorite includes deep media probing via ffprobe, a microsecond-accurate streaming progress runner, smart presets for Discord video budgeting and high-definition GIFs, and a full-screen reactive terminal UI powered by Opal.

Executive Summary & Key Topics

Topic Method / Anchor Description
Installation .topic_01_installation Adding Fluorite to your Crystal shard.yml.
Quickstart Example .topic_02_quickstart Converting media with real-time progress callbacks.

Related Guides & Source References

Defined in:

fluorite/docs/a_getting_started/getting_started.cr

Class Method Summary

Class Method Detail

def self.topic_01_installation : Nil #

Installation: Adding Fluorite to your Crystal shard.yml.

Add fluorite to your project's shard.yml:

dependencies:
  fluorite:
    github: sol-vin/fluorite
    branch: main

Then install dependencies:

shards install

def self.topic_02_quickstart : Nil #

Quickstart Example: Converting media with real-time progress callbacks.

Convert any media file with a single call and live terminal progress:

require "fluorite"

Fluorite.convert("input.mov")
  .to("output.mp4")
  .video_codec(:h264)
  .crf(22)
  .scale(1280, 720)
  .audio_codec(:aac)
  .run do |p|
    puts "#{p.bar} | #{p.speed_formatted} | ETA: #{p.eta_formatted}"
  end