Update Makefile and ReadMe for ffmpeg v7

This commit is contained in:
Shi Liang 2024-09-26 15:39:53 +08:00
parent a1c504ae9c
commit fbb8bc6c2f
2 changed files with 10 additions and 1 deletions

View File

@ -841,6 +841,7 @@ endif
ifdef WHISPER_FFMPEG ifdef WHISPER_FFMPEG
OBJ_COMMON += examples/ffmpeg-transcode.o OBJ_COMMON += examples/ffmpeg-transcode.o
override CXXFLAGS := $(CXXFLAGS) -DWHISPER_FFMPEG
override LDFLAGS := $(LDFLAGS) -lavutil -lavformat -lavcodec -lswscale -lswresample override LDFLAGS := $(LDFLAGS) -lavutil -lavformat -lavcodec -lswscale -lswresample
endif endif

View File

@ -205,7 +205,15 @@ The command downloads the `base.en` model converted to custom `ggml` format and
For detailed usage instructions, run: `./main -h` For detailed usage instructions, run: `./main -h`
Note that the [main](examples/main) example currently runs only with 16-bit WAV files, so make sure to convert your input before running the tool. Note that the [main](examples/main) example currently runs by default with 16-bit WAV files.
Building with `WHISPER_FFMPEG=1` enables ffmpeg support to handle other formats:
```bash
WHISPER_FFMPEG=1 make main
```
If you do not want to rebuild it, convert your input before running the tool.
For example, you can use `ffmpeg` like this: For example, you can use `ffmpeg` like this:
```bash ```bash