
Recherche avancée
Médias (91)
-
Corona Radiata
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Lights in the Sky
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Head Down
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Echoplex
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Discipline
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
-
Letting You
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Audio
Autres articles (75)
-
Le profil des utilisateurs
12 avril 2011, parChaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...) -
Configurer la prise en compte des langues
15 novembre 2010, parAccéder à la configuration et ajouter des langues prises en compte
Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...) -
XMP PHP
13 mai 2011, parDixit Wikipedia, XMP signifie :
Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...)
Sur d’autres sites (7363)
-
How to count variable in for loop in power shell
17 avril 2020, par ilham zackyI am using powershell and i have got a for loop running each time 3 variables get printed, for now, loop runs 5 times. I need to get the count like $i++



This is a part of my code



$file = "D:\edl\input\CPExport.xlsx"
$sheetName = "Sheet1"
$objExcel = New-Object -ComObject Excel.Application
$workbook = $objExcel.Workbooks.Open($file)
$sheet = $workbook.Worksheets.Item($sheetName)
$objExcel.Visible = $false
$rowMax = ($sheet.UsedRange.Rows).count
$nu = 0
$rowcount = 000 

for ($i = 0; $i -le $rowMax - 1; $i++) {
 $id = $sheet.Cells.Item($rowName + $i, $colName).text
 $name = $sheet.Cells.Item($rowAge + $i, $colAge).text
 $subtitle = $sheet.Cells.Item($rowCity + $i, $colCity).text
 $jpgId = "$id.jpg"
 $videoId = "$id.mp4"
 $audioId = "$id.m4a"
 $duration1 = if ((ffmpeg -i $audioId 2>&1 | Out-String) -match 'Duration:\s+([\d:"."]+)') { $matches[1] };
 $duration2 = if ((ffmpeg -i $jpgId 2>&1 | Out-String) -match 'Duration:\s+([\d:"."]+)') { $matches[1] };
 $duration = if ((ffmpeg -i $videoId 2>&1 | Out-String) -match 'Duration:\s+([\d:"."]+)') { $matches[1] };

 $newduration = ("$duration").Replace(".", ":")
 $newduration1 = ("$duration1").Replace(".", ":")
 $newduration2 = ("$duration2").Replace(".", ":")

 $out1 = ""
 $out2 = ""
 $out = ""
 $nu++
 $rowcount++
 if ($newduration1) {

 if ($nu -eq 1) {
 $audioA = "00:00:00:00"
 }

 $audioB = Add-Frame -Base $newduration1 -Offset $audioA
 $out1 = "$rowcount" + " " + "AX" + " " + "AA" + " " + "C" + " " + "00:00:00:00" + " " + $newduration1 + " " + $audioA 
 }

 if ($newduration2) {

 $imagecal = Add-Frame -Base $imageA -Offset "00:00:06:00"
 $imageB = $imagecal
 $out = "$rowcount" + " " + "AX" + " " + "V" + " " + "C" + " " + "02:00:05:15" + " " + $newduration2 + " " + " " + $imageA 
 }


 if ($newduration) {

 $videoA = $imageB
 $videocal = Add-Frame -Base $newduration -Offset $videoA
 $videoB = $videocal
 $out2 = "$rowcount" + " " + "AX" + " " + "AA/V" + " " + "C" + " " + "00:00:00:00" + " " + $hh + " " + " " + $videoA 
 }
 else {
 $videoB = ""
 }
 $gg = $out1 + "`n" + "`n" + $out + "`n" + "`n" + $out2 + "`n"
 echo $gg

 $gg | Out-File -FilePath d:\edl\input\output.txt -Append
}
#close excel file
$objExcel.quit()




i have echo $gg
this is the output



1 AX AA C 00:00:00:00 00:00:03:48 
1 AX V C 02:00:05:15 02:00:11:15
1 AX AA/V C 00:00:00:00 00:00:06:93 
2 AX AA C 00:00:00:00 00:00:03:46 
2 AX V C 02:00:05:15 02:00:11:15 
2 AX AA C 00:00:00:00 00:00:03:46 
3 AX AA C 00:00:00:00 00:00:03:52 
3 AX V C 02:00:05:15 02:00:11:15 
3 AX AA/V C 00:00:00:00 00:00:06:93 
4 AX AA C 00:00:00:00 00:00:03:21 
4 AX V C 02:00:05:15 02:00:11:15 
4 AX AA C 00:00:00:00 00:00:03:21 
5 AX AA C 00:00:00:00 00:00:03:05 
5 AX V C 02:00:05:15 02:00:11:15 
5 AX AA/V C 00:00:00:00 00:00:06:93 




Output prints only 1-5 
I need it to be printed 1 - 15



any suggestions ?



thank you for reading


-
Converting files before merging with FFMPEG
25 mars 2022, par user1748217I'm trying to merge a series of files with the same format (taken from a camera) with another of a different format (an outro).


TARGET file ffprobe output :


Duration: 00:00:21.60, start: 0.000000, bitrate: 1847 kb/s

 Stream #0:0[0x1](eng): 
 Video: h264 (Main) (avc1 / 0x31637661), 
 yuv420p(progressive), 
 1280x720, 
 1050 kb/s, 
 30 fps, 
 30 tbr, 
 30k tbn (default)

 Stream #0:1[0x2](eng): 
 Audio: pcm_s16le (sowt / 0x74776F73), 
 32000 Hz, 
 1 channels, 
 s16, 
 512 kb/s (default)



OUTRO file ffprobe output :


Duration: 00:00:13.03, start: 0.000000, bitrate: 21890 kb/s

 Stream #0:0[0x1](eng): 
 Video: h264 (High) (avc1 / 0x31637661), 
 yuv420p(progressive), 
 1920x1080 [SAR 1:1 DAR 16:9], 
 21492 kb/s, 
 24 fps, 
 24 tbr, 
 24k tbn (default)

 Stream #0:1[0x2](eng): 
 Audio: aac (LC) (mp4a / 0x6134706D), 
 48000 Hz, 
 stereo, 
 fltp, 
 316 kb/s (default)



... and I'm trying to convert the outro to match the others using :


ffmpeg -i outro.mp4 \ 
 -c:v h264 \
 -s 1280x720 \
 -pix_fmt yuv420p \
 -framerate 30 \ 
 -r 30 \
 -c:a pcm_s16le \
 -ac 1 \ 
 -b:a 512k \
 -ar 32000 \ 
 outro.mov



After the transcode the outro plays fine.
but then I merge the files with :


ffmpeg -f concat -safe 0 -i videos.txt -c copy merged.mov -y



In the merged output the outro video is messed up, though the audio on it is ok.

It seems like the outro plays way too fast (milliseconds) but I'm not sure as the original/source outro video fades to black at the end and the "corrupted" merged outro "pauses" on the last frame prior to fading.

I noticed the outro has a lower FPS than the other files (24 FPS vs 30 on the others). When I run ffprobe on the outro after the conversion, it reads ...


Stream #0:0[0x1](eng): 
 Video: h264 (High) (avc1 / 0x31637661), yuv420p(progressive), 
 1280x720 [SAR 1:1 DAR 16:9], 
 1031 kb/s, 
 24 fps, 
 24 tbr, 
 12288 tbn (default)



... so the FPS is still 24 ? How come ? Is this my problem ? What am I missing ? How do I get this to convert so I can join it seamlessly ?


Thanks in advance.


UPDATE :


adding -r 30 (Thanks @Kesh) on the conversion got the FPS to match but but unfortunately it didn't fix the merge issue :-(


audio is all good however...


... If I add the "pre-converted" file to the end of the concat list then series of files I'm trying to match play video fine but the "pre-converted" file plays video through in roughly a second.


If I add the "pre-converted" file to the start of the list then it plays fine, but the rest play video far too slow.


-
Finding the time of a thumbnail in a video
10 mai 2013, par LiamI have a large set of pre-generated thumbnails and videos. What is the easiest way to figure out the specific time in the video of the associated thumbnail ?
I'd imagine that I would have to use something to loop through all the frames in a video to find a match. What libraries should I use ? Something like OpenCV maybe ? ffmpeg ?
Python is preferred but not required.