
Recherche avancée
Médias (1)
-
DJ Dolores - Oslodum 2004 (includes (cc) sample of “Oslodum” by Gilberto Gil)
15 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
Autres articles (83)
-
Amélioration de la version de base
13 septembre 2013Jolie sélection multiple
Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...) -
Participer à sa traduction
10 avril 2011Vous pouvez nous aider à améliorer les locutions utilisées dans le logiciel ou à traduire celui-ci dans n’importe qu’elle nouvelle langue permettant sa diffusion à de nouvelles communautés linguistiques.
Pour ce faire, on utilise l’interface de traduction de SPIP où l’ensemble des modules de langue de MediaSPIP sont à disposition. ll vous suffit de vous inscrire sur la liste de discussion des traducteurs pour demander plus d’informations.
Actuellement MediaSPIP n’est disponible qu’en français et (...) -
Menus personnalisés
14 novembre 2010, parMediaSPIP utilise le plugin Menus pour gérer plusieurs menus configurables pour la navigation.
Cela permet de laisser aux administrateurs de canaux la possibilité de configurer finement ces menus.
Menus créés à l’initialisation du site
Par défaut trois menus sont créés automatiquement à l’initialisation du site : Le menu principal ; Identifiant : barrenav ; Ce menu s’insère en général en haut de la page après le bloc d’entête, son identifiant le rend compatible avec les squelettes basés sur Zpip ; (...)
Sur d’autres sites (8870)
-
Revision b76fd48a99 : Remove vp9_ prefix from static function names in loopfilter_16_msa Remove the c
17 juillet 2015, par Jingning HanChanged Paths :
Modify /vpx_dsp/mips/loopfilter_16_msa.c
Remove vp9_ prefix from static function names in loopfilter_16_msaRemove the codec-specific global prefix from static function names.
Change-Id : I61b2d5f2b7b5fb9dc8bc357d5493ea44df8ab19d
-
How can I read all the data from a pipe and prevent it from closing ?
23 septembre 2014, par slhckI’m trying to read raw YUV data from a compressed file using
ffmpeg
and pipes with Python.
The ffmpeg command correctly spits out frames as raw YUV data, and I’m reading it like this :def read_from_pipe(pipe, amount):
raw = pipe.stdout.read(amount)
pipe.stdout.flush()
return raw
pipe_ref = subprocess.Popen('ffmpeg -i "' + input + '" -r 30 -c:v rawvideo -pix_fmt yuv420p -an -f rawvideo -t 5 -',
shell = True,
stdout = subprocess.PIPE,
bufsize=1920*1080*3*2)
frame_num = 0
while True:
data = read_from_pipe(pipe_ref, width*height*3)
# no more data
if (len(data) != width*height*3))
return results
image = extract_image_data(data, width, height)
# do something with image, put it into "results" and print frame / SSIM values to console
frame_num += 1The problem is, as soon as ffmpeg is done converting all frames, my program stops. Since the program is a little slower than ffmpeg, it will stop receiving data and exit.
Basically, for example, I can only work up to frame 30, then ffmpeg finishes at frame 60, and my program also exits. The command line output would say :
Frame=25 SSIM=0.990472732391
Frame=26 SSIM=0.98359411819
Frame=27 SSIM=0.981074433586
Frame=28 SSIM=0.97850843075
frame= 60 fps= 27 q=0.0 Lsize= 182250kB time=00:00:02.00 bitrate=746496.0kbits/s dup=12 drop=0
video:182250kB audio:0kB subtitle:0 data:0 global headers:0kB muxing overhead 0.000000%
Frame=29 SSIM=0.977698849804
frame= 60 fps= 27 q=0.0 Lsize= 182250kB time=00:00:02.00 bitrate=746496.0kbits/s dup=12 drop=0
video:182250kB audio:0kB subtitle:0 data:0 global headers:0kB muxing overhead 0.000000%How can I get it to work on all frames that are output by ffmpeg ? Or is there any other easier way of obtaining the raw YUV data from any file if not through a pipe ? (I need it to work concurrently)
-
Recursively run ffprobe to get codec types
5 juin 2022, par Timothy MassingI modified @rojo code from here a little to look for h264/AC3 and to recursively run thru all the children folders. My only issue is that it always says the videos has h264 and AC3, but when I run the ffprobe command manually it states different. Am I missing something ?



@if (@CodeSection == @Batch) @then
@echo off & setlocal

for /R %%f in (*.mkv, *.mp4) do (
 echo Testing %%f

 set ffprobe=C:\ffmpeg-4.0.2-win64-static\bin\ffprobe -v quiet -show_entries "stream=codec_name,height" -of json "%%f"

 for /f "delims=" %%I in ('%ffprobe% ^| cscript /nologo /e:JScript "%~f0"') do set "%%~I"

 set "pre=-hide_banner -fflags +genpts+discardcorrupt+fastseek -analyzeduration 100M"
 set "pre=%pre% -probesize 50M -hwaccel dxva2 -y -threads 3 -v error -stats"
 set "global="
 set "video=-c:v h264_nvenc"
 set "audio=-c:a ac3"

 if defined h264 if defined ac3 (
 echo %%~nf already in x264 + AC3 format.
 )

 if not defined h264 if not defined ac3 (

 if not defined ac3 (
 echo Already has AC3 audio. Re-encoding video only.
 set "audio=-c:a copy"
 ) 

 if not defined h264 (
 echo Already has h264 video. Re-encoding audio only.
 set "video=-c:v copy"
 )

 echo output "%%~df%%~pf%%~nf.new.mkv"
 echo C:\ffmpeg-4.0.2-win64-static\bin\ffmpeg %pre% -i "%%f" %global% %video% %audio% "%%~df%%~pf%%~nf.new.mkv"

 pause

 echo del "%%f" /f /q
 echo ren "%%~df%%~pf%%~nf.new.mkv" "%%f"
 )

)
@end // end Batch / begin JScript

var stdin = WSH.CreateObject('Scripting.FileSystemObject').GetStandardStream(0),
 htmlfile = WSH.CreateObject('htmlfile'),
 JSON;

htmlfile.write('');
htmlfile.close(JSON = htmlfile.parentWindow.JSON);

var obj = JSON.parse(stdin.ReadAll());

for (var i = obj.streams.length; i--;) {
 if (/h264/i.test(obj.streams[i].codec_name)) WSH.Echo('h264=true');
 if (/ac3/i.test(obj.streams[i].codec_name)) WSH.Echo('ac3=true');
}




I had this working of a second then it stopped for not reason.



@if (@CodeSection == @Batch) @then
@echo off & setlocal & goto run

:run
for /R %%f in (*.mkv, *.mp4) do (
 echo Testing %%f

 set "file=%%f"
 set "drive=%%~df"
 set "dir=%%~pf"
 set "name=%%~nf"
 set "ext=%%~xf"

 for /f "delims=" %%I in ('C:\ffmpeg-4.0.2-win64-static\bin\ffprobe.exe -v quiet -show_entries "stream=codec_name,height" -of json "%%f" ^| cscript /nologo /e:JScript "%~f0"') do (set "%%~I")

 set "pre=-hide_banner -fflags +genpts+discardcorrupt+fastseek -analyzeduration 100M"
 set "pre=%pre% -probesize 50M -hwaccel dxva2 -y -threads 3 -v error -stats"
 set "global="
 set "video=-c:v h264_nvenc"
 set "audio=-c:a ac3"

 if defined ac3 if defined h264 call :both
 if not defined ac3 call :either
 if not defined h264 call :either
)

:both
echo %name% already in x264 + AC3 format.
goto :EOF

:either
if not defined h264 (
 echo Already has AC3 audio. Re-encoding video only.
 set "audio=-c:a copy"
) 

if not defined ac3 (
 echo Already has h264 video. Re-encoding audio only.
 set "video=-c:v copy"
)

echo "C:\ffmpeg-4.0.2-win64-static\bin\ffmpeg %pre% -i "%file%" %global% %video% %audio% "%drive%%dir%%name%.new.mkv""
echo del "%file%" /f /q
echo ren "%drive%%dir%%name%.new.mkv" "%name%%ext%"
goto :EOF

@end // end Batch / begin JScript

var stdin = WSH.CreateObject('Scripting.FileSystemObject').GetStandardStream(0),
 htmlfile = WSH.CreateObject('htmlfile'),
 JSON;

htmlfile.write('');
htmlfile.close(JSON = htmlfile.parentWindow.JSON);

var obj = JSON.parse(stdin.ReadAll());

for (var i = obj.streams.length; i--;) {
 if (/h264/i.test(obj.streams[i].codec_name)) WSH.Echo('h264=true');
 if (/ac3/i.test(obj.streams[i].codec_name)) WSH.Echo('ac3=true');
}




ffprobe Output for h264



{
 "programs": [

 ],
 "streams": [
 {
 "codec_name": "h264",
 "height": 528
 },
 {
 "codec_name": "aac"
 }
 ]
}




output for ac3



{
 "programs": [

 ],
 "streams": [
 {
 "codec_name": "h265",
 "height": 528
 },
 {
 "codec_name": "ac3"
 }
 ]
}




output for both ac3/h264



{
 "programs": [

 ],
 "streams": [
 {
 "codec_name": "h264",
 "height": 528
 },
 {
 "codec_name": "ac3"
 }
 ]
}