
Recherche avancée
Médias (1)
-
La conservation du net art au musée. Les stratégies à l’œuvre
26 mai 2011
Mis à jour : Juillet 2013
Langue : français
Type : Texte
Autres articles (97)
-
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 (...) -
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 (...) -
ANNEXE : Les plugins utilisés spécifiquement pour la ferme
5 mars 2010, parLe site central/maître de la ferme a besoin d’utiliser plusieurs plugins supplémentaires vis à vis des canaux pour son bon fonctionnement. le plugin Gestion de la mutualisation ; le plugin inscription3 pour gérer les inscriptions et les demandes de création d’instance de mutualisation dès l’inscription des utilisateurs ; le plugin verifier qui fournit une API de vérification des champs (utilisé par inscription3) ; le plugin champs extras v2 nécessité par inscription3 (...)
Sur d’autres sites (7965)
-
Unable to Play Video Stream on Flask-FFmpeg Media Server on Subsequent Requests
12 juin 2024, par yternalProblem Description :


I am trying to create a media server using Flask and FFmpeg. The server converts an RTSP stream to FLV format for playback in a web browser, and I am testing it using ffplay. The server starts successfully, and the data returned from the first request can be played using ffplay. However, when I interrupt the ffplay request and make it again, ffplay is unable to play the video and displays an "Invalid data found when processing input" error.


I am using the following command to test with ffplay :


ffplay http://127.0.0.1:8000/flv/0



My current Flask code:


import queue
import subprocess
import threading

from flask import Flask, Response, stream_with_context
from gevent import monkey
from gevent.pool import Pool
from gevent.pywsgi import WSGIServer
from geventwebsocket.handler import WebSocketHandler
from loguru import logger

monkey.patch_all()
app = Flask(__name__)

stream_queue = queue.Queue(maxsize=10000)


def update_stream():
 process = subprocess.Popen(
 ['ffmpeg', '-i', 'rtsp://192.168.1.168/0', '-f', 'flv', '-'],
 stdout=subprocess.PIPE,
 stderr=subprocess.PIPE
 )
 while True:
 data = process.stdout.read(4096)
 if not data:
 break
 if stream_queue.full():
 stream_queue.get()
 stream_queue.put(data)
 logger.debug(f"stream_queue size: {stream_queue.qsize()}")


@app.route('/flv/')
def flv_stream(stream_id):
 @stream_with_context
 def generate():

 while True:
 data = stream_queue.get()
 yield data

 return Response(generate(), mimetype='video/x-flv')


if __name__ == '__main__':
 HOST = "0.0.0.0"
 PORT = 8000

 threading.Thread(target=update_stream, daemon=True).start()

 logger.info(f"listen in: {HOST}:{PORT}")
 pool = Pool(10000)
 http_serve = WSGIServer((HOST, PORT), app, handler_class=WebSocketHandler, spawn=pool)
 http_serve.max_accept = 30000
 http_serve.serve_forever()



The error message when attempting to play the stream again with ffplay is :


http://127.0.0.1:8000/flv/0: Invalid data found when processing input



I tried adding some parameters to FFmpeg, such as analyzeduration and probesize, but it had no effect.


-
avcodec/mips/aaccoder_mips : Remove MIPS-specific aaccoder
15 mars 2024, par Andreas Rheinhardtavcodec/mips/aaccoder_mips : Remove MIPS-specific aaccoder
ff_aac_coder_init_mips() modifies a static const structure of
function pointers. This will crash if the binary uses relro
and is a data race in any case.Furthermore it points to a maintainability issue : The
AACCoefficientsEncoder structures have been constified
in commit fd9212f2edfe9b107c3c08ba2df5fd2cba5ab9e3,
a Libav commit merged in 318778de9ebec276cb9dfc65509231ca56590d13.
Libav did not have the MIPS-specific AAC code and so this was
fine for them ; yet FFmpeg had them, but this was not recognized.Commit 75a099fc734a4ee2b1347d0a3d8c53d883b95174 points to another
maintainability issue : Contrary to ordinary DSP code, this code
here is way more complex and needs to be constantly kept in sync
with the ordinary code which it mimicks and replaces. Said commit
is the only commit actually changing aaccoder.c in the last few
years and the same change has not been performed for the MIPS
clone ; before that, it even happened several times that the mips
code was broken due to changes of the generic code (see commits
97437bd17a8c5d4135b2f3b1b299bd7bb72ce02c and
de262d018d7d7d9c967af1dfd1b861c4b9eb2a60 or
860dbe0275e57cbf4228f3f653f872ff66ca596b or
933309a6ca0f18bf1d40e917fff455221f57fb4b or
b65ffa316e377213c29736929beba584d0d80d7c). This might even lead
to scenarios where someone changing non-dsp aacenc code would
have to modify mips inline asm in order to keep them in sync.
This is obviously a significant burden (if the AAC encoder were
actively developed).Finally, the code does not even compile here due to errors like
"Error : float register should be even, was 1".Reviewed-by : Lynne <dev@lynne.ee>
Reviewed-by : Jean-Baptiste Kempf <jb@videolan.org>
Signed-off-by : Andreas Rheinhardt <andreas.rheinhardt@outlook.com> -
avcodec/ffv1dec : Switch to ProgressFrames
2 septembre 2022, par Andreas Rheinhardtavcodec/ffv1dec : Switch to ProgressFrames
Avoids implicit av_frame_ref() and therefore allocations
and error checks. It also avoids explicitly allocating
the AVFrames (done implicitly when getting the buffer).It also fixes a data race : The AVFrame's sample_aspect_ratio
is currently updated after ff_thread_finish_setup()
and this write is unsynchronized with the read in av_frame_ref().
Removing the implicit av_frame_ref() fixed this.Signed-off-by : Andreas Rheinhardt <andreas.rheinhardt@outlook.com>