HOW-TO create video-preview thumbnails on a PC for XBMC - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33) +--- Forum: General Support (https://forum.kodi.tv/forumdisplay.php?fid=111) +---- Forum: OS independent / Other (https://forum.kodi.tv/forumdisplay.php?fid=228) +---- Thread: HOW-TO create video-preview thumbnails on a PC for XBMC (/showthread.php?tid=22179) Pages:
1
2
|
HOW-TO create video-preview thumbnails on a PC for XBMC - hoki_goujons - 2006-09-22 This is a way of getting a thumbnail for videos that show a screenshot from the vid. I find it useful for folders of TV shows, where I forget which ep I'm up to if I just leave it as the name foo-s01-e01.avi You need ffmpeg on your PC, preferably in your path - put the exe in windows\system32 or add its location to your path. Then open a command prompt, go to the folder containing your vids and do Code: for %i in (*.avi) do ffmpeg -i %i -f mjpeg -t 0.001 -ss 5 -y %~ni.tbn That goes through all the avi files in the folder and creates a jpeg (actually with a .tbn extension for XBMC) of the frame 5 seconds in, with the same name as the avi. Then set that folder in XBMC to show in thumbs view and you're away!. Alter the number after '-ss' to change how far in you want the grab taken. Change *.avi to be whatever the extension of your vids is. Not rocket science, but I found it useful and thought I'd share. - jgawera - 2006-09-22 Thanks, so simple, so cool. - kugai - 2006-09-28 Nice idea. Here are my embellishments. You need quotes to deal with filenames with spaces: Code: for %i in (*.avi) do ffmpeg -i "%i" -f mjpeg -t 0.001 -ss 5 -y "%~ni.tbn" And here is one for recursively doing directories: Code: for /r %i in (*.avi) do ffmpeg -i "%i" -f mjpeg -t 0.001 -ss 5 -y "%~di%~pi%~ni.tbn" - gzusrawx - 2006-09-28 Has anyone or does anyone know how to do this in linux? - Bazzio - 2006-09-29 "unable to find a suitable output format for 'videoname.tbn'" i keep getting this error any ideas? - hoki_goujons - 2006-09-29 Kugai - good stuff, I was just looking around for how to do spaces :-) gzusrawx - Not off the top of my head. Some kind of find -exec with a bit of awk goodness to do the filename would be my guess. Bazzio - are you using a current version of ffmpeg? Try changing '.tbn' for 'jpg' or try -singlejpeg instead of -mjpeg - sCAPe - 2006-09-30 Just wanted to say thanks to you guys for sharing your ideas and tricks. I just created a page in the online-manual for creating the preview-thumbnails. http://www.xboxmediacenter.com/wiki/index.php?title=HOW-TO:_Create_video-preview_thumbnails Please have a look at that page and tell me if i have included any mistakes/typos.. - Bazzio - 2006-09-30 no i dont think i do have the latest. is is mplayer i need? I cant seem to find just ffmpeg to put in windows/system32 if you could give me some links or explain this that would be great! Thanks - Bazzio - 2006-09-30 ok i got the latest version sorted, but now i have a new error "swScaler: 0x0 ( is not supported as output format Cannot get resampling context" - hoki_goujons - 2006-09-30 sCAPe - I'm honoured :-) Looks good to me. Bazzio - I don't know what that error is. Maybe your version is too recent (http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/2006-August/013856.html) - what damn fool told you to use the latest version? ;-) The one I'm using is SVN-r5570, you can try mine if you like (http://homepages.nildram.co.uk/~pravda/foo/ffmpeg.exe). Have you tried it with a few different types of file? - Bazzio - 2006-09-30 what verison do you have? - Bazzio - 2006-09-30 aparently pthreadGC2.dll is missing, so i cant use your version grrrr - Bazzio - 2006-09-30 ok finally got it working Rather than 5 seconds, i wanted to do it with about a min in. Sometimes expecially on movies there is only an intro around 5 secs, so it doesnt make a very good thumbnail. however this takes a lot more time to process. Is there a way you can tell it to ignore the file if a tbn is present, this way updates will be a lot quicker - kugai - 2006-10-02 If there is interest I can probably throw together a perl script or something like that to make this a little easier. I'll try to get something up in the next few days. - Bazzio - 2006-10-02 that would be awesome |