<p>The split filter expects exactly one input. Also, scale2ref requires two, as does overlay. As currently specified, the filters will rely on implicit routing which won't help with debugging or clarity.</p>
<p>Use</p>
<p><code>[0:v]drawtext=fontfile=/var/www/area51-process1.example.com/html/includes/helveticaneue/HelveticaNeueMed.ttf:text=@mustsee:fontcolor=white@0.7:fontsize=(h/32):x=w-tw-25:y=h-th-10,format=yuv420p[wm];[1:v][wm]scale2ref=oh*mdar:ih[logo][wm];[wm][logo]overlay=main_w-overlay_w-10:main_h-overlay_h-65,split=5[s0][s1][s2][s3][s4];[s0]scale=854:450[480p];[s1]scale=640:338[360p];[s2]scale=1280:-2[720p];[s3]scale=1920:-2[1080p];[s4]scale=2560:1350[1440p]</code></p>

CC BY-SA 4.0
2022-10-01T07:54:29.700Z
Thanks for the answer. It was driving me crazy. I just have one problem. The logo is showing very big across the whole screen. Please see image above. What might cause that? It's the same code used here.  Is the scale2ref incorrect?
Panama Jack
CC BY-SA 4.0
2022-10-01T08:27:03.637Z
Never mind. I used code from another answer you provided `scale2ref=w=oh*mdar:h=ih/20` and it's working great. thank you.
Panama Jack
CC BY-SA 4.0
2022-09-29T04:22:17.820Z
2022-09-29T04:22:17.820Z
Gyan
<p>So I'm trying to add text and a logo onto all my video qualities with HLS and I am receiving the error <code>Too many inputs specified for the &quot;split&quot; filter</code>. I am not sure how to correct it so that my command is working.</p>
<pre><code>ffmpeg -y -hide_banner -i /var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9.mp4
-i /var/www/area51-process1.example.com/html/includes/assets/watermark_logo.png
-filter_complex &quot;[0:v]drawtext=fontfile=/var/www/area51-process1.example.com/html/includes/helveticaneue/HelveticaNeueMed.ttf:text=@mustsee:fontcolor=white@0.7:fontsize=(h/32):x=w-tw-25:y=h-th-10,format=yuv420p[wm];[1:v]scale2ref=oh*mdar:ih[logo];[logo]overlay=main_w-overlay_w-10:main_h-overlay_h-65;[wm][logo]split=5[s0][s1][s2][s3][s4];[s0]scale=854:450[480p];[s1]scale=640:338[360p];[s2]scale=1280:-2[720p];[s3]scale=1920:-2[1080p];[s4]scale=2560:1350[1440p]&quot;
-map &quot;[480p]&quot; -map &quot;[360p]&quot; -map &quot;[720p]&quot; -map &quot;[1080p]&quot; -map &quot;[1440p]&quot; -maxrate:v:0 4000000 -bufsize:v:0 4000000 -maxrate:v:1 3000000 -bufsize:v:1 3000000 -maxrate:v:2 8000000 -bufsize:v:2 8000000
-maxrate:v:3 14000000 -bufsize:v:3 14000000 -maxrate:v:4 20000000 -bufsize:v:4 20000000 -map 0:a -c:a libfdk_aac -ac 2 -async 1 -ar 48000 -b:a 128k -c:v libx264 -preset superfast -crf:v:0 24
-profile:v:0 high -crf:v:1 25 -profile:v:1 high -crf:v:2 23 -profile:v:2 high -crf:v:3 22 -profile:v:3 high -crf:v:4 21 -profile:v:4 high  -g 100 -keyint_min 100 -force_key_frames &quot;expr:gte(t,n_forced*2)&quot; -sc_threshold 0 -flags +global_header
-movflags +faststart -max_muxing_queue_size 4096 -threads 0 -f tee &quot;[select=\'v:0,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-480p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-480p.m3u8|[select=\'v:1,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-360p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-360p.m3u8|[select=\'v:2,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-720p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-720p.m3u8|[select=\'v:3,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-1080p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-1080p.m3u8|[select=\'v:4,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-1440p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-1440p.m3u8&quot;
</code></pre>
<p>update:
After using the new code it works but the image is huge. what could be causing that?</p>
<p><a href="https://i.sstatic.net/FRUsv.png" rel="nofollow noreferrer"><img src="https://i.sstatic.net/FRUsv.png" alt="enter image description here" /></a></p>

<ffmpeg>
ffmpeg - Too many inputs specified for the "split" filter
Panama Jack
# ffmpeg - Too many inputs specified for the "split" filter

(Asked by: username_0 on 2022-09-28)

So I'm trying to add text and a logo onto all my video qualities with HLS and I am receiving the error Too many inputs specified for the "split" filter. I am not sure how to correct it so that my command is working.
ffmpeg -y -hide_banner -i /var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9.mp4
-i /var/www/area51-process1.example.com/html/includes/assets/watermark_logo.png
-filter_complex "[0:v]drawtext=fontfile=/var/www/area51-process1.example.com/html/includes/helveticaneue/HelveticaNeueMed.ttf:text=@mustsee:fontcolor=white@0.7:fontsize=(h/32):x=w-tw-25:y=h-th-10,format=yuv420p[wm];[1:v]scale2ref=oh*mdar:ih[logo];[logo]overlay=main_w-overlay_w-10:main_h-overlay_h-65;[wm][logo]split=5[s0][s1][s2][s3][s4];[s0]scale=854:450[480p];[s1]scale=640:338[360p];[s2]scale=1280:-2[720p];[s3]scale=1920:-2[1080p];[s4]scale=2560:1350[1440p]"
-map "[480p]" -map "[360p]" -map "[720p]" -map "[1080p]" -map "[1440p]" -maxrate:v:0 4000000 -bufsize:v:0 4000000 -maxrate:v:1 3000000 -bufsize:v:1 3000000 -maxrate:v:2 8000000 -bufsize:v:2 8000000
-maxrate:v:3 14000000 -bufsize:v:3 14000000 -maxrate:v:4 20000000 -bufsize:v:4 20000000 -map 0:a -c:a libfdk_aac -ac 2 -async 1 -ar 48000 -b:a 128k -c:v libx264 -preset superfast -crf:v:0 24
-profile:v:0 high -crf:v:1 25 -profile:v:1 high -crf:v:2 23 -profile:v:2 high -crf:v:3 22 -profile:v:3 high -crf:v:4 21 -profile:v:4 high  -g 100 -keyint_min 100 -force_key_frames "expr:gte(t,n_forced*2)" -sc_threshold 0 -flags +global_header
-movflags +faststart -max_muxing_queue_size 4096 -threads 0 -f tee "[select=\'v:0,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-480p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-480p.m3u8|[select=\'v:1,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-360p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-360p.m3u8|[select=\'v:2,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-720p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-720p.m3u8|[select=\'v:3,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-1080p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-1080p.m3u8|[select=\'v:4,a\':f=hls:start_number=0:hls_flags=single_file:hls_playlist_type=vod:hls_segment_type=fmp4:hls_time=4:hls_list_size=0:hls_segment_filename=/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-1440p-segment.mp4]/var/www/area51-process1.example.com/html/v/he2IqMmhZLG-f205e4f3-2351-447d-a16c-52855da761e9-1440p.m3u8"

update:
After using the new code it works but the image is huge. what could be causing that?

**Tags:** ffmpeg


---

## 1 answers

### Answer by username_1 on 2022-09-29. Score: 2 | Accepted answer

The split filter expects exactly one input. Also, scale2ref requires two, as does overlay. As currently specified, the filters will rely on implicit routing which won't help with debugging or clarity.

Use

`[0:v]drawtext=fontfile=/var/www/area51-process1.example.com/html/includes/helveticaneue/HelveticaNeueMed.ttf:text=@mustsee:fontcolor=white@0.7:fontsize=(h/32):x=w-tw-25:y=h-th-10,format=yuv420p[wm];[1:v][wm]scale2ref=oh*mdar:ih[logo][wm];[wm][logo]overlay=main_w-overlay_w-10:main_h-overlay_h-65,split=5[s0][s1][s2][s3][s4];[s0]scale=854:450[480p];[s1]scale=640:338[360p];[s2]scale=1280:-2[720p];[s3]scale=1920:-2[1080p];[s4]scale=2560:1350[1440p]`

> **Comments:**
> **username_0**: Thanks for the answer. It was driving me crazy. I just have one problem. The logo is showing very big across the whole screen. Please see image above. What might cause that? It's the same code used here.  Is the scale2ref incorrect?  
> **username_0**: Never mind. I used code from another answer you provided `scale2ref=w=oh*mdar:h=ih/20` and it's working great. thank you.  

---

