Quantcast
Channel: Kodi Community Forum - Meta-Data provider and Artwork Packs
Viewing all articles
Browse latest Browse all 370

Full resolution thumbnail script

$
0
0
I am using the FTV skin at 4K resolution and wanted to have higher quality TV episode thumbnails than what were available online (such as at the TVDB).

After a lot of googling, I created the following script. It crawls all my TV shows and generates up to 50 full resolution thumbnails per episode. I then pick the best one and use another tool (Name Mangler) to rename the selected image to the original thumbnail.

There are a few extra options in here to improve picture quality including deinterlacing, cropping, and sharpening.

The only thing I haven't solved is how to create normal aspect ratio thumbnails from anamorphic SD content (e.g. widescreen DVDs). If someone knows, please share and I will update the script.

Code:
#!/bin/bash

for v; do
    cd "$v"    
    find . -name '*.mkv' -type f -exec sh -c 'ffmpeg -ss 30 -i "${0%.*}.mkv" -vf  "thumbnail,yadif=0:-1:0,cropdetect,unsharp,curves=linear_contrast" -frames:v 50 -vf fps=1/60 -bsf:v mjpeg2jpeg "${0%.*}-thumb%03d.jpg"' {} \;        
                
done

To use it, simply save it to a text file and run it in terminal (e.g. "sh thumbnails.sh [folders]". Obviously you would need to modify it to search for non-MKV files.

Viewing all articles
Browse latest Browse all 370

Trending Articles