
Recherche avancée
Autres articles (55)
-
Support de tous types de médias
10 avril 2011Contrairement à beaucoup de logiciels et autres plate-formes modernes de partage de documents, MediaSPIP a l’ambition de gérer un maximum de formats de documents différents qu’ils soient de type : images (png, gif, jpg, bmp et autres...) ; audio (MP3, Ogg, Wav et autres...) ; vidéo (Avi, MP4, Ogv, mpg, mov, wmv et autres...) ; contenu textuel, code ou autres (open office, microsoft office (tableur, présentation), web (html, css), LaTeX, Google Earth) (...)
-
Support audio et vidéo HTML5
10 avril 2011MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...) -
Personnaliser les catégories
21 juin 2013, parFormulaire de création d’une catégorie
Pour ceux qui connaissent bien SPIP, une catégorie peut être assimilée à une rubrique.
Dans le cas d’un document de type catégorie, les champs proposés par défaut sont : Texte
On peut modifier ce formulaire dans la partie :
Administration > Configuration des masques de formulaire.
Dans le cas d’un document de type média, les champs non affichés par défaut sont : Descriptif rapide
Par ailleurs, c’est dans cette partie configuration qu’on peut indiquer le (...)
Sur d’autres sites (8963)
-
PyInstaller —noconsole still shows the console after running the app
23 septembre 2020, par Kiren78I've built an app to download and play sound everytime someone inserts or removes USB drive from PC.

Code :

from playsound import playsound
from win10toast import ToastNotifier
from time import sleep
from typing import Callable
import threading
import os
import youtube_dl
import win32file


def play_audio():
 try:
 path = os.getcwd() + "\\audio.mp3"
 ydl_opts = {
 'format': 'bestaudio/best',
 'postprocessors': [{
 'key': 'FFmpegExtractAudio',
 'preferredcodec': 'mp3',
 'preferredquality': '192',
 }],
 'outtmpl': path
 }

 with youtube_dl.YoutubeDL(ydl_opts) as ydl:
 ydl.download(['https://www.youtube.com/watch?v=_0HTwQjMr9k'])

 playsound(path)
 except Exception as e:
 toast = ToastNotifier()
 toast.show_toast("RIP prank failed byq", "no ogolnie prank failed rip co jest?", duration=20)


def get_drives():
 drive_list = []
 drivebits = win32file.GetLogicalDrives()
 for d in range(1, 26):
 mask = 1 << d
 if drivebits & mask:
 drname = '%c:\\' % chr(ord('A') + d)
 t = win32file.GetDriveType(drname)
 if t == win32file.DRIVE_REMOVABLE:
 drive_list.append(drname)
 return drive_list


def watch_drives(on_change: Callable[[dict], None] = print, poll_interval: int = 1):
 def _watcher():
 global prev
 while True:
 drives = get_drives()
 if prev != drives:
 on_change(drives)
 play_audio()
 prev = drives
 sleep(poll_interval)

 t = threading.Thread(target=_watcher)
 t.start()
 t.join()


if __name__ == '__main__':
 prev = get_drives()
 watch_drives(on_change=print)



I don't understand it but everytime the download starts and FFmpeg starts debugging everything (using youtube-dl) a couple of console windows appear for a fraction of a second and they immediately disappear. How can I TOTALLY disable the console so that even FFmpeg can't open it ?


EDIT : Yes, I've already tried using
--windowed
and-w
parameters in PyInstaller

-
(FFMPEG) Make areas transparent before overlaying a vid with perspective
7 octobre 2020, par aaeimI'm trying to add perspective to a small video then overlay it on top of an other.



So far I can make the video small, add perspective to it and overlay it to an other video. but after applying the perspective filter, the excess areas don't turn transparent, they just stretch out the pixels.



the perspective filter doesn't have much documentation but as far as i could find out there was no way of setting the extra pixels to transparent.



So I'm guessing ill need to apply some kind of alpha mask, to the desired area ?



this is the command I'm using for perspective :



ffmpeg -i /synced_folder/testvid.mp4 -vf perspective=0:0:W:H/4:0:H:W:3*H/4:0:1:0 /synced_folder/output5.mp4




Don't think it matters but I'm running ffmpeg on a VM with centOS.



This is a SS of how the result looks like :


-
How to convert ffmpeg command to ffmpeg-python
1er décembre 2020, par Retro PieHello and thanks for reading.


I have the following command :
ffmpeg -i tmp.mp4 -loop 1 -i mask.png -filter_complex "[0:v]split [a][b];[a]transpose=1,crop=720:888:0:196,scale=876:1080,setdar=876/1080 [crop];[b]transpose=1,crop=720:888:0:196,scale=1920:1080,setdar=16/9,avgblur=76 [back];[1:v]alphaextract [mask];[crop][mask]alphamerge [masked];[back][masked]overlay=522:0" "out.mp4


And I would like to convert it to ffmpeg-python syntax. So far I was able to come up with the bellow, but it far from ready :


overlay_file = ffmpeg.input(mask)
(
ffmpeg
.input(tmp).split()
.overlay(overlay_file.hflip())
.alphaextract(),
.alphamerge(),
.output('out.mp4')
.run()
)



Any help will be appreciated.