- Accueil
- » Forum
- » XFCE
- » [Truc] Vignette
Pages : 1
#1 Le 04/09/2007, à 11:47
- Coolaman
[Truc] Vignette
Petit truc pas vraiment utile donc indispensable.
- Pour avoir des miniatures de vos vidéos avec mplayer :
Creer un fichier /usr/local/bin/mplayer-thumbnailer
sudo mousepad /usr/local/bin/mplayer-thumbnailer
et copier/coller ce script trouvé sur les forums de zenwalk :
#!/bin/bash
videofile=$(echo "$1" | sed -e 's/%20/ /g' | sed -e 's/%26/\&/g' | sed -e 's/%5B/\[/g' | sed -e 's/%5D/\]/g' | sed -e 's/%40/\@/g' )
# If we only have a chunk, then file will return "data", so we must exit to prevent mplayer from hanging
[ "$(/usr/bin/file --brief "$videofile" | grep -e "^data$")" ] && exit
thumbfile="$2"
LENGTH=$(mplayer -nocache -identify -vo null -ao null -frames 0 "$videofile" | awk -F= '/ID_LENGTH/ {print $2}'| awk -F. '{print $1}')
RANDOM=$(date %+s)
START=$(((LENGTH / 100) * 15)) ; END=$(((LENGTH / 100) * 70)); LENGTH=$(($END - $START)) ; SHOT=$((($RANDOM % $LENGTH) + $START))
/usr/bin/mplayer -nojoystick -nolirc -nocache -noautosub -nosound -vf scale -vo jpeg:outdir=/tmp:quality=100 -ao null -ss "$SHOT" -frames 3 -zoom -xy 128 -slave "$videofile"
mv /tmp/00000002.jpg "$thumbfile" || rm -f /tmp/00000002.jpg
rm -f /tmp/00000001.jpg /tmp/00000003.jpg
Rendez le exécutable :
sudo chmod 755 /usr/local/bin/mplayer-thumbnailer
Puis créer ce fichier desktop dans ~/.local/share/thumbnailers/video-thumbs.desktop
mousepad ~/.local/share/thumbnailers/video-thumbs.desktop
et copier/coller ceci:
[Desktop Entry]
Version=1.0
Encoding=UTF-8
Type=X-Thumbnailer
Name=VIDEO Thumbnailer
MimeType=video/x-ms-wmv;video/mpeg;video/x-msvideo;video/quicktime;video/x-ms-asf;application/vnd.rn-realmedia;application/x-flash-video;video/x-matroska;video/mp4
X-Thumbnailer-Exec=/usr/local/bin/mplayer-thumbnailer %i %o
- Pour avoir des miniatures de vos fichier pdf avec evince :
créer ce fichier desktop dans ~/.local/share/thumbnailers/pdf-thumbs.desktop
mousepad ~/.local/share/thumbnailers/pdf-thumbs.desktop
et copier/coller ceci:
[Desktop Entry]
Version=1.0
Encoding=UTF-8
Type=X-Thumbnailer
Name=PDF Thumbnailer
MimeType=application/pdf;
X-Thumbnailer-Exec=/usr/bin/evince-thumbnailer %u %o
Pour régénérer les vignettes :
Fermer toutes les instances de thunar
thunar -q
puis
/usr/lib/thunar/thunar-vfs-update-thumbnailers-cache-1
Pour plus de détail :
http://support.zenwalk.org/index.php/topic,4241.0.html
et l'explication ( en anglais ) pour générer des vignettes pour thunar : http://thunar.xfce.org/documentation/C/ … hunar.html
Dernière modification par Coolaman (Le 04/09/2007, à 11:48)
Hors ligne
#2 Le 04/05/2014, à 22:33
- tlecheva
Re : [Truc] Vignette
Bonjour,
Pour ma part, j'ai enfin réussi a afficher les vignettes de videos au format .MOD (camescope HD Everio GZ-MG JVC).
En fait c'est du mpeg, pour enfin avoir des vignettes (thumbnail), j'ai tout simplement installer kdenlive .
Plus de détails sur kdenlive ici:
http://fr.lprod.org/wiki/doku.php/video:kdenlive
Je suis sur une Debian 7.4 comme ubuntu mais avec une distribution HandyLinux (bureau xfce). J'ai également un eeepc sous lubuntu mais je n'ai pas fait le test.
Je visionne les .mod avec mplayer plutôt que VLC (bug avec le son).
Hors ligne
Pages : 1
- Forum
- » XFCE
- » [Truc] Vignette