
Recherche avancée
Médias (1)
-
Revolution of Open-source and film making towards open film making
6 octobre 2011, par
Mis à jour : Juillet 2013
Langue : English
Type : Texte
Autres articles (7)
-
Emballe médias : à quoi cela sert ?
4 février 2011, parCe plugin vise à gérer des sites de mise en ligne de documents de tous types.
Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ; -
Déploiements possibles
31 janvier 2010, parDeux types de déploiements sont envisageable dépendant de deux aspects : La méthode d’installation envisagée (en standalone ou en ferme) ; Le nombre d’encodages journaliers et la fréquentation envisagés ;
L’encodage de vidéos est un processus lourd consommant énormément de ressources système (CPU et RAM), il est nécessaire de prendre tout cela en considération. Ce système n’est donc possible que sur un ou plusieurs serveurs dédiés.
Version mono serveur
La version mono serveur consiste à n’utiliser qu’une (...) -
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 (3768)
-
ffmpeg Unrecognized option 'vcodec libx264'
8 septembre 2021, par MikeI have a lambda that is trying to transcode webm files to mp4. It his the lambda using the following code to do the conversion :


const args = [
 "-i",
 inputFilename,
 "-vcodec libx264",
 "-r 30",
 "-y",
 mp4Filename,
];


try {
 const { error, output } = spawnSync(ffmpeg, args);
 console.log(`output: ${output}`);
 console.log(`error: ${error}`);
} catch (error) {
 console.log("ffmpeg failed...");
 console.log(error);
}



In my lambda, I'm seeing the following error :


output: ,,ffmpeg version 4.2.2-static https://johnvansickle.com/ffmpeg/ Copyright (c) 2000-2019 the FFmpeg developers
 built with gcc 8 (Debian 8.3.0-6)
 configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-libgme --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
 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
Unrecognized option 'vcodec libx264'.
Error splitting the argument list: Option not found

2021-09-08T15:19:46.644Z 9477062f-6afa-4a94-9900-6b28337d8c2a INFO output: ,,ffmpeg version 4.2.2-static https://johnvansickle.com/ffmpeg/ Copyright (c) 2000-2019 the FFmpeg developers built with gcc 8 (Debian 8.3.0-6) configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-libgme --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg 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 Unrecognized option 'vcodec libx264'. Error splitting the argument list: Option not found



I'm using ffmpeg-4.2.2-amd64-static


-
Can't convert .ts files that downloaded with from .m3u8 file to mp4
28 juillet 2022, par smartnimaI Have This Files :


001.ts 014.ts 027.ts 040.ts 053.ts 066.ts 079.ts 092.ts 105.ts 118.ts 131.ts 144.ts 157.ts 170.ts 183.ts 196.ts 209.ts 222.ts 235.ts 248.ts 261.ts 274.ts 287.ts 300.ts 313.ts 326.ts
002.ts 015.ts 028.ts 041.ts 054.ts 067.ts 080.ts 093.ts 106.ts 119.ts 132.ts 145.ts 158.ts 171.ts 184.ts 197.ts 210.ts 223.ts 236.ts 249.ts 262.ts 275.ts 288.ts 301.ts 314.ts 327.ts
003.ts 016.ts 029.ts 042.ts 055.ts 068.ts 081.ts 094.ts 107.ts 120.ts 133.ts 146.ts 159.ts 172.ts 185.ts 198.ts 211.ts 224.ts 237.ts 250.ts 263.ts 276.ts 289.ts 302.ts 315.ts 328.ts
004.ts 017.ts 030.ts 043.ts 056.ts 069.ts 082.ts 095.ts 108.ts 121.ts 134.ts 147.ts 160.ts 173.ts 186.ts 199.ts 212.ts 225.ts 238.ts 251.ts 264.ts 277.ts 290.ts 303.ts 316.ts 329.ts
005.ts 018.ts 031.ts 044.ts 057.ts 070.ts 083.ts 096.ts 109.ts 122.ts 135.ts 148.ts 161.ts 174.ts 187.ts 200.ts 213.ts 226.ts 239.ts 252.ts 265.ts 278.ts 291.ts 304.ts 317.ts 330.ts
006.ts 019.ts 032.ts 045.ts 058.ts 071.ts 084.ts 097.ts 110.ts 123.ts 136.ts 149.ts 162.ts 175.ts 188.ts 201.ts 214.ts 227.ts 240.ts 253.ts 266.ts 279.ts 292.ts 305.ts 318.ts 331.ts
007.ts 020.ts 033.ts 046.ts 059.ts 072.ts 085.ts 098.ts 111.ts 124.ts 137.ts 150.ts 163.ts 176.ts 189.ts 202.ts 215.ts 228.ts 241.ts 254.ts 267.ts 280.ts 293.ts 306.ts 319.ts 332.ts
008.ts 021.ts 034.ts 047.ts 060.ts 073.ts 086.ts 099.ts 112.ts 125.ts 138.ts 151.ts 164.ts 177.ts 190.ts 203.ts 216.ts 229.ts 242.ts 255.ts 268.ts 281.ts 294.ts 307.ts 320.ts 333.ts
009.ts 022.ts 035.ts 048.ts 061.ts 074.ts 087.ts 100.ts 113.ts 126.ts 139.ts 152.ts 165.ts 178.ts 191.ts 204.ts 217.ts 230.ts 243.ts 256.ts 269.ts 282.ts 295.ts 308.ts 321.ts 334.ts
010.ts 023.ts 036.ts 049.ts 062.ts 075.ts 088.ts 101.ts 114.ts 127.ts 140.ts 153.ts 166.ts 179.ts 192.ts 205.ts 218.ts 231.ts 244.ts 257.ts 270.ts 283.ts 296.ts 309.ts 322.ts
011.ts 024.ts 037.ts 050.ts 063.ts 076.ts 089.ts 102.ts 115.ts 128.ts 141.ts 154.ts 167.ts 180.ts 193.ts 206.ts 219.ts 232.ts 245.ts 258.ts 271.ts 284.ts 297.ts 310.ts 323.ts
012.ts 025.ts 038.ts 051.ts 064.ts 077.ts 090.ts 103.ts 116.ts 129.ts 142.ts 155.ts 168.ts 181.ts 194.ts 207.ts 220.ts 233.ts 246.ts 259.ts 272.ts 285.ts 298.ts 311.ts 324.ts
013.ts 026.ts 039.ts 052.ts 065.ts 078.ts 091.ts 104.ts 117.ts 130.ts 143.ts 156.ts 169.ts 182.ts 195.ts 208.ts 221.ts 234.ts 247.ts 260.ts 273.ts 286.ts 299.ts 312.ts 325.ts



That I Downloaded With This Python Program (m3u8 File Does Not Work !) :


import requests
import shutil
import os
import subprocess


def strip_end(text, suffix):
 if not text.endswith(suffix):
 return text
 return text[:len(text)-len(suffix)]


def download_file(url):
 cwd = os.getcwd()
 command = f"wget -O {cwd}/ts_files/{url.split('/')[-1]} {url}"
 subprocess.call(command, shell=True)


base_url = "https://stream.example.com/video/2021/example/720p_{}.ts"

if not os.path.exists('ts_files'):
 print('ts_file folder is not found, creating the folder.')
 os.makedirs('ts_files')

i = 1
while True:
 if len(str(i)) == 1:
 num = f"00{i}"
 elif len(str(i)) == 2:
 num = f"0{i}"
 else:
 num = str(i)
 url = base_url.replace("{}", num)
 r = requests.get(url, stream=True)
 print(f'downloading {i}')
 if r.status_code != 404:
 download_file(url) # comment out this line to download ts files.
 else:
 print("404")
 break
 i = i+1

cwd = os.getcwd() # Get the current working directory (cwd)
TS_DIR = 'ts_files'
with open('merged.ts', 'wb') as merged:
 for ts_file in os.listdir(f'{cwd}/{TS_DIR}'):
 with open(f'{cwd}/{TS_DIR}/{ts_file}', 'rb') as mergefile:
 shutil.copyfileobj(mergefile, merged)




My Problem Is When I Want To Convert All This Files To One .ts File And Then An MP4 File With ffmpeg, I Get An Error :


nima@funlife:~/ts_files$ cat ./*.ts > all.ts
nima@funlife:~/ts_files$ ffmpeg -i all.ts -acodec copy -vcodec copy all.mp4
ffmpeg version 5.0.1-3+b1 Copyright (c) 2000-2022 the FFmpeg developers
 built with gcc 11 (Debian 11.3.0-4)
 configuration: --prefix=/usr --extra-version=3+b1 --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --arch=amd64 --enable-gpl --disable-stripping --enable-gnutls --enable-ladspa --enable-libaom --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libcodec2 --enable-libdav1d --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libglslang --enable-libgme --enable-libgsm --enable-libjack --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librabbitmq --enable-librist --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libsrt --enable-libssh --enable-libsvtav1 --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzimg --enable-libzmq --enable-libzvbi --enable-lv2 --enable-omx --enable-openal --enable-opencl --enable-opengl --enable-sdl2 --disable-sndio --enable-pocketsphinx --enable-librsvg --enable-libmfx --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libplacebo --enable-libx264 --enable-shared
 libavutil 57. 17.100 / 57. 17.100
 libavcodec 59. 18.100 / 59. 18.100
 libavformat 59. 16.100 / 59. 16.100
 libavdevice 59. 4.100 / 59. 4.100
 libavfilter 8. 24.100 / 8. 24.100
 libswscale 6. 4.100 / 6. 4.100
 libswresample 4. 3.100 / 4. 3.100
 libpostproc 56. 3.100 / 56. 3.100
all.ts: Invalid data found when processing input



.ts Files Content Is Like This :


}��,.g���}��
 �����c����Ww�c���c���eo��m�����ŧ� 䱉
�b(+��D�FG�zPe��7�&#bz�1ɶ��� C
�`,��>Ϲc4J��̀��T�I}�"��ކ�R�1��w͋� "� <�#B`ƪ�̸�co
 �9���+��W�
P���N���w��T\5g��
\�E�N�E�v��͑4f��U�@]�ΩX�U�x�E��bwm=ְ�iA�����p���M�����\=�_�I3C�hL�h����0)�ο��*��`���eZ� �ؗ4To�0V��S,�+�>�8_]�W�lNJD�|7e�2s�1X)̃5�0h�������~8ߩg���?e��EK�>۷�L
 ��:6|������>\ �N�WW��,�w
bk��1?*��/��/�5��k����~�� Lޕ}�a���2�{��l��$�d=����g�{a2��L�����
 jҫַ��ʿ�"1`ZZ.he)�=�x��E_4:Vg�����H=���x1�����}��W::y�



Are They Encrypted Or Something ?
I'm Trying To Do This Works With Debian 11.3.0-4, Python 3.10.5


-
FFmpeg - Convert video changing resolution and bitrates
8 avril 2021, par parvaresI’m trying to convert a video and change these parameters :


resolution : from 1.280x720 to 640x360 pixels


average bitrate : from 1.410 to 300 kb/s


maximum bitrate : from 1.680 to 2500 kb/s


Sampling rate : from 48.0 to 44.1 kHz


Bit rate audio : 128 kb/s


I used this string with ffmpeg vers. 4.3.2-2021-02-20 full build :


ffmpeg -i input.mp4 -c:v -vf scale=640:360 libx264 -b:v 300k -maxrate 2500k -bufsize 2500k -crf 25 -c:a -ar 44100 libfdk_aac -b:a 128k output.mp4



I get the error : “ffmpeg unable to find a suitable output format for scale ‘640:360’ scale 640:360 : invalid argument”. Could you help me please ?


Below is the original file analyzed by MediaInfo, thanks !


General


Complete name : C :\Users\parvares\Desktop\input.mp4
Format : MPEG-4
Format profile : Base Media
Codec ID : isom (isom/iso2/avc1/mp41)
File size : 424 MiB
Duration : 38 min 21 s
Overall bit rate : 1 545 kb/s
Writing application : Lavf58.64.100


Video


ID : 1
Format : AVC
Format/Info : Advanced Video Codec
Format profile : High@L3.1
Format settings : CABAC / 4 Ref Frames
Format settings, CABAC : Yes
Format settings, Reference frames : 4 frames
Codec ID : avc1
Codec ID/Info : Advanced Video Coding
Duration : 38 min 21 s
Bit rate : 1 410 kb/s
Maximum bit rate : 1 680 kb/s
Width : 1 280 pixels
Height : 720 pixels
Display aspect ratio : 16:9
Frame rate mode : Constant
Frame rate : 25.000 FPS
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Bits/(Pixel*Frame) : 0.061
Stream size : 387 MiB (91%)
Writing library : x264 core 161 r3027 4121277
Encoding settings : cabac=1 / ref=2 / deblock=1:0:0 / analyse=0x3:0x113 / me=hex / subme=6 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=1 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=-2 / threads=12 / lookahead_threads=2 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=1 / b_bias=0 / direct=1 / weightb=1 / open_gop=0 / weightp=1 / keyint=250 / keyint_min=125 / scenecut=40 / intra_refresh=0 / rc_lookahead=125 / rc=crf / mbtree=1 / crf=20.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / vbv_maxrate=1680 / vbv_bufsize=8400 / crf_max=0.0 / nal_hrd=none / filler=0 / ip_ratio=1.40 / aq=1:1.00
Color range : Limited
Color primaries : BT.709
Transfer characteristics : BT.709
Matrix coefficients : BT.709
Codec configuration box : avcC


Audio


ID : 2
Format : AAC LC
Format/Info : Advanced Audio Codec Low Complexity
Codec ID : mp4a-40-2
Duration : 38 min 21 s
Bit rate mode : Constant
Bit rate : 129 kb/s
Channel(s) : 2 channels
Channel layout : L R
Sampling rate : 48.0 kHz
Frame rate : 46.875 FPS (1024 SPF)
Compression mode : Lossy
Stream size : 35.3 MiB (8%)
Default : Yes
Alternate group : 1