
Recherche avancée
Autres articles (44)
-
Ajouter notes et légendes aux images
7 février 2011, parPour pouvoir ajouter notes et légendes aux images, la première étape est d’installer le plugin "Légendes".
Une fois le plugin activé, vous pouvez le configurer dans l’espace de configuration afin de modifier les droits de création / modification et de suppression des notes. Par défaut seuls les administrateurs du site peuvent ajouter des notes aux images.
Modification lors de l’ajout d’un média
Lors de l’ajout d’un média de type "image" un nouveau bouton apparait au dessus de la prévisualisation (...) -
Submit bugs and patches
13 avril 2011Unfortunately a software is never perfect.
If you think you have found a bug, report it using our ticket system. Please to help us to fix it by providing the following information : the browser you are using, including the exact version as precise an explanation as possible of the problem if possible, the steps taken resulting in the problem a link to the site / page in question
If you think you have solved the bug, fill in a ticket and attach to it a corrective patch.
You may also (...) -
HTML5 audio and video support
13 avril 2011, parMediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
For older browsers the Flowplayer flash fallback is used.
MediaSPIP allows for media playback on major mobile platforms with the above (...)
Sur d’autres sites (8221)
-
PyQt-thread. Get dynamicly output
1er janvier 2020, par ZProI use PyQt-thread for parallel conversion of mp3 files to aac via ffmpeg.
Here is my code :class SubprocessThread(QThread):
signal = pyqtSignal('PyQt_PyObject')
def __init__(self, command, args):
QThread.__init__(self)
self.command = command
self.args = args
def __del__(self):
self.wait()
def run(self):
output = subprocess.check_output('{0} {1}'.format(self.command, self.args), shell=True).split()
self.signal.emit(output)And here is example of usage :
threads = []
for part in parts.keys():
args = "-i \'{0}.mp3\' -c:a aac -b:a {1}k \'{2}.m4a\'".format(
os.path.join(tmp_dir, str(part)),
int(self.bitrate_cbx.currentText()),
os.path.join(tmp_dir, str(part)))
print(args) # debug
ffmpeg_thread = SubprocessThread('ffmpeg', args)
ffmpeg_thread.signal.connect(self.on_data_ready)
threads.append(ffmpeg_thread)
ffmpeg_thread.start()
self.threads_count += 1I want to make progress bar, based on conversion, but ffmpeg always updates last string in his output (when conversion in progress).
Here is an example of ffmpeg output while files are converting :user@host$ ffmpeg -i '/home/user/001.mp3' -c:a aac -b:a 128k -vn '/home/user/test.m4a'
ffmpeg version n4.2.1 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 9.2.0 (GCC)
configuration: --prefix=/usr --disable-debug --disable-static --disable-stripping --enable-fontconfig --enable-gmp --enable-gnutls --enable-gpl --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libdav1d --enable-libdrm --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libiec61883 --enable-libjack --enable-libmodplug --enable-libmp3lame --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libv4l2 --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxcb --enable-libxml2 --enable-libxvid --enable-nvdec --enable-nvenc --enable-omx --enable-shared --enable-version3
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
Input #0, mp3, from '/home/user/001.mp3':
Metadata:
encoder : Lavf57.41.100
title : test
artist : test
album_artist : test
album : test
composer : test
genre : test
date : 2018
Duration: 00:12:38.02, start: 0.025056, bitrate: 192 kb/s
Stream #0:0: Audio: mp3, 44100 Hz, stereo, fltp, 192 kb/s
Metadata:
encoder : Lavc57.48
Stream #0:1: Video: mjpeg (Baseline), yuvj420p(pc, bt470bg/unknown/unknown), 500x500 [SAR 1:1 DAR 1:1], 90k tbr, 90k tbn, 90k tbc (attached pic)
Metadata:
comment : Cover (front)
Stream mapping:
Stream #0:0 -> #0:0 (mp3 (mp3float) -> aac (native))
Press [q] to stop, [?] for help
Output #0, ipod, to '/home/user/test.m4a':
Metadata:
date : test
title : test
artist : test
album_artist : test
album : test
composer : test
genre : test
encoder : Lavf58.29.100
Stream #0:0: Audio: aac (LC) (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 128 kb/s
Metadata:
encoder : Lavc58.54.100 aac
size= 12107kB time=00:12:38.01 bitrate= 130.8kbits/s speed=79.2xHow can I receive this data (string, that begins from "size=...") from my parallel QThreads to calculate overall progress ?
-
iOS switching between audio & subtitle tracks added using ffmpeg
27 décembre 2019, par Tony MEdit : Title altered to reflect that the answer and comments by @llogan cover switching between both audio and subtitle tracks.
I have an
m.mp4
with English audio and want to add a second audio stream in Italian so that I can play either language using the iPhone. When I used this command :ffmpeg -i m.mp4 -i ita.mp3 -c copy -map 0 -map 1 out.mp4
the output from
ffmpeg -i out.mp4
(see below) shows that a new audio stream is added, and I can switch between audio streams using the VLC player. Yet when I transfer the video to the TV app and play it on either MacOS or iOS it only plays the original English and I see no options to play other languages.How do I get it to be able to switch between either audio on iOS ?
Here is the output from
ffmpeg -i out.mp4:
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 400x300 [SAR 1:1 DAR 4:3], q=2-31, 482 kb/s, 23.98 fps, 23.98 tbr, 24k tbn, 24k tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 102 kb/s (default)
Metadata:
handler_name : SoundHandler
Stream #0:2: Audio: mp3 (mp4a / 0x6134706D), 44100 Hz, stereo, fltp, 152 kb/s
Metadata:
encoder : LAME3.100
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:1 -> #0:1 (copy)
Stream #1:0 -> #0:2 (copy) -
Windows - FFmpeg - How to map a jpg file to video stream 0:0 and include only audio stream 0:2 and not stream 0:1 and 0:2 together
21 juin 2020, par slyfox1186I am trying to write a batch script that begins by extracting a thumbnail "Cover.jpg" from an mkv video. My end goal is to have this script recursively loop a folder full of videos to encode them all in one go.



:: create cover art jpg
for %%G in (*.mkv) do (
%FF% -hide_banner -ss 30 -y -i "%%G" -vframes 1 -an Cover.jpg
)




Then I am trying to encode the 4K mkv video that I got the jpg thumbnail from to 1920x1080 resolution instead of it's native 4K to make it easier to play back on my home plex server.



I have surround sound 6 channel speaker system so I want to take audio stream 0:2 which is Dolby DTS 6 channel and save some HDD space by converting it to
-c:a ac3 -b:a 640k -ac 6
.


I have gotten stuck because I can achieve everything I want except I keep encoding 2 of the 4 audio streams available in the end. I only want to keep 1 audio stream to maximize my space savings.



Here is the entire script so far.



@echo off
setlocal enabledelayedexpansion
prompt $g
color 0a

pushd "%~dp0"

set FF=C:\MAB\local64\bin-video\ffmpeg.exe
set TITLE=MOVIETITLE

:: create cover art jpg file
for %%G in (*.mkv) do (
%FF% -hide_banner -ss 30 -y -i "%%G" -vframes 1 -an Cover.jpg
)

:: run ffmpeg x265
for %%I in (*.mkv) do (
set fname="%%~nxI"
set fout="%%~nI-temp.mkv"
call :runff !fname! !fout!
del /s /q *.jpg
pause
goto:eof
)

:runff
%FF% -ss 0 ^
-y ^
-i "%~1" ^
-attach "Cover.jpg" ^
-map_metadata 0 ^
-map_chapters 0 ^
-metadata title="%TITLE%" ^
-map 0:0 -metadata:s:v:0 language=eng ^
-map 0:2 -metadata:s:a:0 language=eng -metadata:s:a:0 title="Surround 5.1 (DTS)" ^
-map 0:3 -metadata:s:s:0 language=eng -metadata:s:s:0 title="English" -metadata:s:t:0 filename="Cover.jpg" -metadata:s:t:0 mimetype="image/jpeg" ^
-c:v libx265 -preset medium ^
-x265-params crf=18:qcomp=0.8:aq-mode=1:aq_strength=1.0:qg-size=16:psy-rd=0.7:psy-rdoq=5.0:rdoq-level=1:merange=44 ^
-c:a ac3 -b:a 640k -ac 6 ^
-t 3 ^
"%~2"
exit /b




Here are the output logs.
https://pastebin.com/hVMy3VJW



You can see towards the bottom that it is encoding both audio streams.



Any ideas guys ?