
Recherche avancée
Autres articles (89)
-
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
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 (...) -
Support de tous types de médias
10 avril 2011Contrairement à beaucoup de logiciels et autres plate-formes modernes de partage de documents, MediaSPIP a l’ambition de gérer un maximum de formats de documents différents qu’ils soient de type : images (png, gif, jpg, bmp et autres...) ; audio (MP3, Ogg, Wav et autres...) ; vidéo (Avi, MP4, Ogv, mpg, mov, wmv et autres...) ; contenu textuel, code ou autres (open office, microsoft office (tableur, présentation), web (html, css), LaTeX, Google Earth) (...)
Sur d’autres sites (15256)
-
Raspberry / Nginx RTMP video streaming player
28 mai 2016, par Emmanuel BrunetI’ve set up a Nginx RTMP server that receives a flv stream from a raspberry cam using raspivid and avconv (ffmpeg)
on the pi side I run
/opt/vc/bin/raspivid -n -fl -mm matrix -w 800 -h 600 -fps 25 -g 80 -t 0 -b 6000000 -o - | avconv -re -i - -nostats -c copy -f flv rtmp://mercure/cam/live
note : the target host is called mercure
the Nginx rtmp module on mercure is set like bellow
rtmp {
server {
listen 1935;
# chunk_size 8192; # This might positively affect CPU load
chunk_size 4096;
application cam {
# max_connections 100;
live on;
# meta copy;
allow play all;
record all;
record_path /var/CCTV;
record_interval 1800s;
record_suffix -%Y-%m-%d-%T.flv;
hls on;
# hls_nested on;
hls_path /tmp/HLS;
}
}in the http section I’ve defined a hls location
location /hls {
root /tmp/HLS;
types {
video/MP2T ts;
application/vnd.apple.mpegurl m3u8;
}
}when I run
ffplay rtmp://mercure/cam/live
it works like a charm but I can’t get it working with Vlc using the same url.
Any idea ?
otherwise I’m also trying to install a javascript rtmp / hls video player does anybody succeed or experienced using an open source component like flowplayer ? I’ve read a lot of doc about that but each time installs fail or some components are missing.
please help me getting this stream available thru a web broser. thanks in advance
-
ffmpeg can't work via nginx + nginx-rtmp-module
2 mai 2018, par Ubunkunnginx version : nginx/1.12.2
ffmpeg version 3.4.2I’m trying to below.
-> nginx -> ffmpeg multi encode -> HLS publishnginx configration is below (nginx.conf)
worker_processes 1;
events {
worker_connections 1024;
}
http {
include mime.types;
default_type application/octet-stream;
sendfile on;
keepalive_timeout 65;
server {
listen 80;
server_name localhost;
location / {
root html;
index index.html index.htm index.php;
}
location ~ \.php$ {
root html;
fastcgi_pass unix:/var/run/php-fpm/php-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
}
}
rtmp {
server {
listen 1935;
application hls {
live on;
exec /usr/local/sbin/ffscript.sh $name;
}
application hls2 {
live on;
hls on;
hls_path /usr/local/nginx/html;
hls_nested on;
hls_fragment 9s;
hls_variant _low BANDWIDTH=300000;
hls_variant _mid BANDWIDTH=700000;
hls_variant _high BANDWIDTH=1200000;
}
}
}(/usr/local/sbin/ffscript.sh)
export LIBVA_DRIVERS_PATH=/opt/intel/mediasdk/lib64
export LIBVA_DRIVER_NAME=iHD
export MFX_HOME=/opt/intel/mediasdk
export PKG_CONFIG_PATH=/opt/intel/opencl:
/usr/local/bin/ffmpeg -i rtmp://localhost/hls/${1} -vcodec h264_qsv -init_hw
_device qsv:hw -b:v 128K -c:a aac -ar 44100 -ac 2 -r 30 -f flv rtmp://localhost/
hls2/${1}_low -b:v 512k -c:a aac -ar 44100 -ac 2 -r 30 -f flv rtmp://localhost/h
ls2/${1}_mid -b:v 1024k -c:a aac -ar 44100 -ac 2 -r 30 -f flv rtmp://localhost/h
ls2/${1}_highBut it can’t work. The access.log appears just one line.
192.168.1.121 [02/May/2018:21:52:39 +0900] PUBLISH "hls" "test2" "" - 580840 753 "" "FMLE/3.0 (compatible; Lavf57.55" (21s)
There is no "hls2" PUBLISH on access log.
When I tried to run the ffmpeg command line while nginx is running, it was succeed.
Why ffmpeg called by nginx doesn’t work ? If you have any solution, let me know.
Bests,
-
Traceback error with Python when using ffmpeg to convert a video
16 mai 2013, par TheMickeyNickThe simple way my script runs is the user provides a folder location and a filetype and glob.glob() finds the files with the filetype provided and adds them to a list. It then uses a for loop and goes through the list and converts each video. But it doesn't like when I try to run my ffmpeg command. Any help would be awesome. I'm also using Win 7 64 bit with 64 bit ffmpeg and Python 3.3
Here's the error :OS Error
Traceback (most recent call last):
File "C:\Python33\lib\subprocess.py", line 1106, in _execute_child
startupinfo)
FileNotFoundError: [WinError 2] The system cannot find the file specified
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\user\Workspace\PythonConverter\HTMLandPythonConverter\Converter.py", line 77, in <module>
massConvert(fileNames)
File "C:\Users\user\Workspace\PythonConverter\HTMLandPythonConverter\Converter.py", line 47, in massConvert
convertVideotoNewFormat('.mp4', x)
File "C:\Users\user\Workspace\PythonConverter\HTMLandPythonConverter\Converter.py", line 61, in convertVideotoNewFormat
myFile = subprocess.Popen(ffmpegString)#, stdout=subprocess.PIPE, stderr=subprocess.PIPE
File "C:\Python33\lib\subprocess.py", line 820, in __init__
restore_signals, start_new_session)
File "C:\Python33\lib\subprocess.py", line 1112, in _execute_child
raise WindowsError(*e.args)
FileNotFoundError: [WinError 2] The system cannot find the file specified
</module>Here is my code :
import subprocess
from subprocess import call
import glob
fileNames = []
fileLocation = {}
filetype = {}
def convertString(location):
s = list(location)
for i in range(len(s)):
if s[i] in '\\':
s[i] = '/'
if s[len(s)-1] != '/':
s.append('/')
location = "".join(s)
return location
def convertStringBack(stringTo):
s = list(stringTo)
for i in range(len(s)):
if s[i] in '/':
s[i] = '\\'
stringTo = "".join(s)
return stringTo
def fileTypeTester():
FieldType = '*' + input('What\'s the file type we are converting from?')
typeSplit = list(FieldType)
if typeSplit[1] != '.':
typeSplit.insert(1,'.')
FieldType = "".join(typeSplit)
if FieldType not in ['*.flv','*.kdb']:
print('Not a valid file type')
else:
return FieldType
return None
def massConvert(listOfFiles):
print('Starting Conversion')
for x in listOfFiles:
#x = convertStringBack(x)
print('Converting ' + x + ' to .mp4')
convertVideotoNewFormat('.mp4', x)
print('Finished File Conversion')
def convertVideotoNewFormat(newFormat, fileLoc):
newFilePath = fileLoc[0:len(fileLoc)-4]
ffmpegString = ["ffmpeg64","-i", fileLoc,"-qscale","0","-ar","22050","-vcodec","libx264",newFilePath,newFormat]
try:
subprocess.check_call(newFilePath)
except OSError:
print('OS Error')
except subprocess.CalledProcessError:
print('Subprocess Error')
myFile = subprocess.Popen(ffmpegString)
print(myFile)
#This will replace old HTML flv object tag with new video tag, but it is yet to be implemented
def replaceHTML():
pass
fileLocation = input('What is the path of the files you\'d like to convert?')
fileLocation = convertString(fileLocation)
fileType = fileTypeTester()
fileNames = glob.glob(fileLocation + fileType)
massConvert(fileNames)I've looked around and most of the tutorials are in 2.7 the code is 3.3 and I can't find a tutorial to use ffmpeg for 3.3. My ffmpeg is set to 'ffmpeg64' on my PATH.
Thanks !