
Recherche avancée
Médias (1)
-
Bug de détection d’ogg
22 mars 2013, par
Mis à jour : Avril 2013
Langue : français
Type : Video
Autres articles (99)
-
List of compatible distributions
26 avril 2011, parThe table below is the list of Linux distributions compatible with the automated installation script of MediaSPIP. Distribution nameVersion nameVersion number Debian Squeeze 6.x.x Debian Weezy 7.x.x Debian Jessie 8.x.x Ubuntu The Precise Pangolin 12.04 LTS Ubuntu The Trusty Tahr 14.04
If you want to help us improve this list, you can provide us access to a machine whose distribution is not mentioned above or send the necessary fixes to add (...) -
Activation de l’inscription des visiteurs
12 avril 2011, parIl est également possible d’activer l’inscription des visiteurs ce qui permettra à tout un chacun d’ouvrir soit même un compte sur le canal en question dans le cadre de projets ouverts par exemple.
Pour ce faire, il suffit d’aller dans l’espace de configuration du site en choisissant le sous menus "Gestion des utilisateurs". Le premier formulaire visible correspond à cette fonctionnalité.
Par défaut, MediaSPIP a créé lors de son initialisation un élément de menu dans le menu du haut de la page menant (...) -
La sauvegarde automatique de canaux SPIP
1er avril 2010, parDans le cadre de la mise en place d’une plateforme ouverte, il est important pour les hébergeurs de pouvoir disposer de sauvegardes assez régulières pour parer à tout problème éventuel.
Pour réaliser cette tâche on se base sur deux plugins SPIP : Saveauto qui permet une sauvegarde régulière de la base de donnée sous la forme d’un dump mysql (utilisable dans phpmyadmin) mes_fichiers_2 qui permet de réaliser une archive au format zip des données importantes du site (les documents, les éléments (...)
Sur d’autres sites (9416)
-
How to add escape characters to a filename to be consumed later by a shell command ?
9 mars 2023, par nhershyI am trying to find out which of my video files are corrupted. I loop through a directory, grab each video file, and check if it is corrupt/healthy. If the filename has no spaces nor special characters, it will work. Unfortunately, many of my files have spaces or parenthesis in the name, and this causes my shell command
ffmpeg
within my python script to fail. How can I retrieve the filenames inabs_file_path
with the escape characters preceding the special characters ?

Example filename : Movie Name (1080p)


Goal : Movie\ Name\ \(1080p\)


for filename in os.listdir(directory):
 if filename.endswith(tuple(VIDEO_EXTENSIONS)):
 print(f'PROCESSING: {filename}...')

 abs_file_path = os.path.join(directory, filename)

 proc = subprocess.Popen(f'./ffmpeg -v error -i {abs_file_path} -f null - 2>&1', shell=True, stdout=subprocess.PIPE)
 output = proc.communicate()[0]

 row = ''
 if not output:
 # Healthy
 print("\033[92m{0}\033[00m".format("HEALTHY -> {}".format(filename)), end='\n') # red
 row = [filename, 0]
 else:
 # Corrupt
 print("\033[31m{0}\033[00m".format("CORRUPTED -> {}".format(filename)), end='\n') # red
 row = [filename, 1]

 results_file_writer.writerow(row)
 results_file.flush()

results_file.flush()
results_file.close()



-
ffmpeg - escaping special characters
21 février 2023, par RizI want to record screen using ffmpeg. Here is a simple command which I use and works fine


ffmpeg -f dshow -i audio="Microphone Array (Full HD 1080P PC Camera Audio)" -f gdigrab -offset_x 0 -offset_y 0 -video_size 500x500 -framerate 30 -i desktop -pix_fmt yuv420p -vcodec libx264 -crf 28 -preset ultrafast -tune zerolatency -movflags +faststart "recording.mp4"



But I have another USB mic (Microphone 1:2 (USB PnP Sound Device)), which has a colon ( :) in its name. When I use it for recording, it gives error


[dshow @ 0000028f718db740] Malformed dshow input string.
audio=Microphone 1:2 (USB PnP Sound Device): I/O error



I have tried to escape colon sign with & \ but still get same error. How to fix this ?


-
Best logical formula to determine perceptual / "experienced" quality of a video, given resolution / fps and bitrate ?
20 mars 2023, par JamesKI am looking for a formula that can provide me with a relatively decent approximation of a Video's playback quality that can be calculated based off of four metrics : width, height, fps, and bitrate (bits/sec). Alternatively, I can also use FFMPEG or similar tools to calculate a Video's playback quality, if any of those tools provide something like what I am looking for here.


An example of what a Video might look like in my problem is as follows :


interface Video {
 /** The width of the Video (in pixels). */
 width: number
 /** The height of the Video (in pixels). */
 height: number
 /** The frame rate of the Video (frames per second). */
 fps: number
 /** The bitrate of the video, in bits per second (e.g. 5_000_000 = 5Mbit/sec) */
 bitrate: number
}



I came up with the following function to compute the average amount of bits available for any given pixel per second :


const computeVideoQualityScalar = (video: Video): number => {
 // The amount of pixels pushed to the display, per frame.
 const pixelsPerFrame = video.width * video.height
 
 // The amount of pixels pushed to the display, per second.
 const pixelsPerSecond = pixelsPerFrame * video.fps
 
 // The average amount of bits used by each pixel, each second,
 // to convey all data relevant to that pixel (e.g. color data, etc)
 const bitsPerPixelPerSecond = video.bitrate / pixelsPerSecond
 
 return bitsPerPixelPerSecond
}



While my formula does do a good job of providing a more-or-less "standardized" assessment of mathematical quality for any given video, it falls short when I try to use it to compare videos of different resolutions to one another. For example, a 1080p60fps video with a bitrate of 10Mbit/sec has a greater visual fidelity (at least, subjectively speaking, to my eyes) than a 720p30fps video with a bitrate of 9Mbit/sec, but my formula would score the 720p30fps video significantly higher than the 1080p60fps video because the 720p video has more bits available per pixel per second than the 1080p video.


I am struggling to come up with ideas as to how to either come up with a different way to calculate the "subjective video quality" for a given video, or extend upon my existing idea here.