How I could use ExtractThumb ? - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32) +--- Forum: Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=26) +--- Thread: How I could use ExtractThumb ? (/showthread.php?tid=76411) |
How I could use ExtractThumb ? - itombs - 2010-06-29 Hi, i want to open some video file and ExtractThumb seeking to some positions. I saw that XBMC makes this and i want to do it into my plugin to work with those thumbs. There is any function to Extract a Thumb for a video seeking the position? Thanks in advance. - spiff - 2010-06-29 not available from python, but we do have such a function. although i doubt it takes the position as a parameter. - itombs - 2010-06-30 spiff Wrote:not available from python, but we do have such a function. although i doubt it takes the position as a parameter. Ok, thanks. Is it possible i could use your function? or any idea i could make a function to seek a position and extract a thumb. Thanks a lot. - spiff - 2010-06-30 sure, patch welcome. - itombs - 2010-06-30 spiff Wrote:sure, patch welcome. What? I need code or help to make code of the function. Thanks - itombs - 2010-07-14 Anyone could help me to make a function that extracts thumbs for video files seeking the position? Thanks in advance. - itombs - 2010-07-17 When we create bookmarks seeking time of a movie, xbmc save a thumbnail into \XBMC\UserData\Thumbnails\Video\Bookmarks I want to save thumbnails of a movie in a folder seeking its positions and without play the movie. Any idea? Thanks. - itombs - 2010-07-30 I found this: http://www.crocodile.org/lord/thumbextraction/vthumb.py Quote:import Image And this: http://myy.helia.fi/~karte/mplayer-video-thumbnailer.html I think the first code could be used to make thumbnails seeking position but I dont know how to begin with. Anyone know how I could make a python function that let me take thumbnails for a input file (video) seeking a position or time?? Thanks - itombs - 2010-09-14 Hi, Im triying to make thumbnails using ffmpeg but doesnt work! If I execute this with cmd (under windows 7): Code: "C:\Program Files (x86)\XBMC\scripts\Base De Datos\ffmpeg.exe" -y -ss 30 -i "C:\Program Files (x86)\XBMC\scriptsmovie.avi" -f mjpeg -vframes 1 -s 120x90 -an "C:\Program Files (x86)\XBMC\scripts\Base De Datos\thumbnail.jpg" work fine! But, if I execute this code into my python plugin: Code: os.system('"C:\Program Files (x86)\XBMC\scripts\Base De Datos\ffmpeg.exe" -y -ss 30 -i "C:\Program Files (x86)\XBMC\scriptsmovie.avi" -f mjpeg -vframes 1 -s 120x90 -an "C:\Program Files (x86)\XBMC\scripts\Base De Datos\thumbnail.jpg"') doesnt work! I import os and the code work into my cmd so there is no errors. Anyone could help me?? Thanks a lot. - davilla - 2010-09-14 I bet if you delimit your spaces, it will work. - itombs - 2010-09-14 davilla Wrote:I bet if you delimit your spaces, it will work.I tryed this without spaces: Code: os.system('"C:\prueba\ffmpeg.exe" -y -ss 30 -i "C:\prueba\movie.avi" -f mjpeg -vframes 1 -s 120x90 -an "C:\prueba\thumbnail.jpg"') Into cmd works fine but doesnt work in python with os.system. Any idea? I need make thumbnails, i trying a lot of methods Thanks. - itombs - 2010-09-16 I solved the problem, I have to use \\ instead \. But now, I have another problem: When my plugin executes the order os.system() xbmc window minimizes!! Anyone could help me? Thanks in advance. - itombs - 2010-09-16 Anyone know how to launch a subprocess in python ? I want to launch ffmpeg without interfering with my plugin. If I use: Code: sacarThumb = """"C:\\Program Files (x86)\\XBMC\\scripts\\Base De Datos\\ffmpeg.exe" -y -ss 423 -i "\\GERAR\\HD_RED_6\\Peliculas\\La Princesa Mononoke\\Movie.mkv" -f mjpeg -vframes 1 -s 720x400 -an "C:/Program Files (x86)/XBMC/scripts/Base De Datos/thumbnail.jpg"""" Debugger says me: Code: 13:46:41 T:2904 M:2748325888 ERROR: Exception in python script's onAction If I use: Code: os.system(sacarThumb) Works fine ! but minimizes my xbmc window If I use: Code: os.popen(sacarThumb) Debugger says me: Code: 14:47:04 T:1980 M:2464804864 ERROR: CThread::staticThread : Access violation at 0x77498c19: Writing location 0x00000014 Thanks. |