You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+27Lines changed: 27 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,6 +24,33 @@ def deps do
24
24
end
25
25
```
26
26
27
+
## Controlling FFmpeg log output
28
+
29
+
FFmpeg's underlying libraries (`libavcodec`, `libswscale`, ...) print to `stderr` at the `AV_LOG_INFO` level by default. This is usually fine but can produce informational noise such as
30
+
31
+
```
32
+
[swscaler @ 0x1490a0000] No accelerated colorspace conversion found from yuv420p to rgb24.
33
+
```
34
+
35
+
when `libswscale` falls back to a generic colorspace conversion path. These are not errors — decoded frames are bit-exact — but they can clutter test output and logs.
36
+
37
+
You can raise the threshold from Elixir:
38
+
39
+
```elixir
40
+
Xav.set_log_level(:error)
41
+
```
42
+
43
+
Or set it once at application start by configuring your application env:
44
+
45
+
```elixir
46
+
# config/runtime.exs
47
+
config :xav, ffmpeg_log_level::error
48
+
```
49
+
50
+
`Xav.Application` reads this on boot and applies it before your supervision tree starts. Valid atoms are `:quiet`, `:panic`, `:fatal`, `:error`, `:warning`, `:info`, `:verbose`, `:debug`, and `:trace`. An integer FFmpeg level is also accepted.
51
+
52
+
Note that `av_log_set_level/1` is process-global — changing the level affects every `libav*` call made from the current OS process, not just the reader that triggered the change.
0 commit comments