From e7c4598fe53eaa3105789f2e23b4646152eaf833 Mon Sep 17 00:00:00 2001 From: Arsham Arya <81646632+arshamalh@users.noreply.github.com> Date: Mon, 16 Oct 2023 23:02:28 +0330 Subject: [PATCH] Update README.md --- README.md | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/README.md b/README.md index c262538..b1996de 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,30 @@ ffmpeg-go is golang port of https://github.com/kkroening/ffmpeg-python check examples/example_test.go and ffmpeg_test.go for more examples. +# How to get and use +You can get this package via: +``` +go get -u github.com/u2takey/ffmpeg-go +``` + +> **Note**: `ffmpeg-go` makes no attempt to download/install FFmpeg, as `ffmpeg-go` is merely a pure-Go wrapper - whereas FFmpeg installation is platform-dependent/environment-specific, and is thus the responsibility of the user, as described below. + +### Installing FFmpeg + +Before using `ffmpeg-go`, FFmpeg must be installed and accessible via the `$PATH` environment variable. + +There are a variety of ways to install FFmpeg, such as the [official download links](https://ffmpeg.org/download.html), or using your package manager of choice (e.g. `sudo apt install ffmpeg` on Debian/Ubuntu, `brew install ffmpeg` on OS X, etc.). + +Regardless of how FFmpeg is installed, you can check if your environment path is set correctly by running the `ffmpeg` command from the terminal, in which case the version information should appear, as in the following example (truncated for brevity): + +``` +$ ffmpeg +ffmpeg version 4.2.4-1ubuntu0.1 Copyright (c) 2000-2020 the FFmpeg developers + built with gcc 9 (Ubuntu 9.3.0-10ubuntu2) +``` + +> **Note**: The actual version information displayed here may vary from one system to another; but if a message such as `ffmpeg: command not found` appears instead of the version information, FFmpeg is not properly installed. + # Examples ```go