
Recherche avancée
Médias (91)
-
Collections - Formulaire de création rapide
19 février 2013, par
Mis à jour : Février 2013
Langue : français
Type : Image
-
Les Miserables
4 juin 2012, par
Mis à jour : Février 2013
Langue : English
Type : Texte
-
Ne pas afficher certaines informations : page d’accueil
23 novembre 2011, par
Mis à jour : Novembre 2011
Langue : français
Type : Image
-
The Great Big Beautiful Tomorrow
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
-
Richard Stallman et la révolution du logiciel libre - Une biographie autorisée (version epub)
28 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Texte
-
Rennes Emotion Map 2010-11
19 octobre 2011, par
Mis à jour : Juillet 2013
Langue : français
Type : Texte
Autres articles (78)
-
MediaSPIP v0.2
21 juin 2013, parMediaSPIP 0.2 est la première version de MediaSPIP stable.
Sa date de sortie officielle est le 21 juin 2013 et est annoncée ici.
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Comme pour la version précédente, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
MediaSPIP version 0.1 Beta
16 avril 2011, parMediaSPIP 0.1 beta est la première version de MediaSPIP décrétée comme "utilisable".
Le fichier zip ici présent contient uniquement les sources de MediaSPIP en version standalone.
Pour avoir une installation fonctionnelle, il est nécessaire d’installer manuellement l’ensemble des dépendances logicielles sur le serveur.
Si vous souhaitez utiliser cette archive pour une installation en mode ferme, il vous faudra également procéder à d’autres modifications (...) -
Script d’installation automatique de MediaSPIP
25 avril 2011, parAfin de palier aux difficultés d’installation dues principalement aux dépendances logicielles coté serveur, un script d’installation "tout en un" en bash a été créé afin de faciliter cette étape sur un serveur doté d’une distribution Linux compatible.
Vous devez bénéficier d’un accès SSH à votre serveur et d’un compte "root" afin de l’utiliser, ce qui permettra d’installer les dépendances. Contactez votre hébergeur si vous ne disposez pas de cela.
La documentation de l’utilisation du script d’installation (...)
Sur d’autres sites (6027)
-
Anomalie #4543 (Nouveau) : Accessibilité des chargements ajax (live regions)
2 septembre 2020, par nicod _Suite à un audit de site par Temesis, il remonte que les attributs aria qu’on utilise sont mal placés.
Je cite :
Il semble qu’il y a un problème plus global avec l’utilisation des live region :
Je rencontre à nouveau le div englobant div.ariaformprop qui possèdent les attributsaria-live
aria-atomic
aria-relevantCette utilisation de ces attributs est erronée :
elle ne donne pas le résultat probablement attendu
le support d’aria-relevant dans les assistances technologiques n’est pas assuréIl est donc nécessaire de ne pas utiliser de live region sur une div englobante comme là.
Il faut supprimer ces attributs et utiliser aria-live et aria-atomic avec parcimonie.J’ai regardé l’exemple que tu donnes sur spip.net également.
L’exemple était : https://www.spip.net/spip.php?page=recherche&recherche=plugin&debut_articles=0#pagination_articles
Cette prolifération d’aria-live + aria-atomic part probablement d’un bon sentiment, mais comme parfois avec l’accessibilité, le mieux est l’ennemi du bien.
En positionnant ces attributs, avec ces valeurs, sur des div englobantes, cela génère dans les lecteurs d’écran la lecture automatique des contenus qui ont été mis à jour.
Certes la lecture peut être interrompue par l’utilisateur, mais cela revient, à mon avis à imposer quelque chose qui n’a pas été forcément souhaité. De cette manière le propriétaire du site impose une expérience différente aux utilisateurs de lecteur d’écran.
Ensuite, il faut bien entendu prendre en compte le contexte. Il pourrait arriver que ce comportement soit pertinent. Ce n’est pas le cas ici.Dans le cas de rechargement ajax, il faut étudier chaque cas et son contexte, mais le plus souvent le principe est :
Ne pas utiliser ces attributs lorsqu’il n’y a pas d’interactions / rechargement ajax . Exemple sur un formulaire, cela n’a pas de sens : on rempli un form et puis on valide le form. A priori (si j’ai bien compris le fonctionnement) il n ’y a aucune raison d’utiliser de live region. En théorie, la présence de ces attributs s’il n’y a pas de rechargement ne devrait pas gêner. Mais certains lecteurs d’écran peuvent prendre des libertés par rapport aux spécifications et vocaliser des contenus tout de même. C’est pourquoi il faut être parcimonieux.
Lorsqu’ils sont utiles et nécessaires, utiliser ces attributs pour informer d’un changement. Exemple : donner le nouveau nombre de résultats après utilisation de filtre. Mais il faut bien penser que dans plusieurs cas ils ne sont pas nécessaires, en effet, un bouton d’action doit être explicite avant qu’on appuie dessus. Donc par exemple : lorsque je demande à afficher la page 2 dans une pagination de résultat, il n’y a pas d’info à vocaliser automatiquement, le fait que le bouton dise "afficher la page 2" est suffisant, il serait superflu, voire gênant d’aller plus loin dans ce qui est vocalisé.
Enfin, il faut gérer le focus clavier. Cet aspect est essentiel dès qu’il y a des interactions ajax, mais il dépend totalement du contexte. Et cet aspect est indépendant de la nécessité d’utiliser les live regions. Exemple : dans une série de filtre on va laisser le focus sur le filtre pour que l’utilisateur puisse parcourir la série de filtre. A contrario, dans une pagination (ou quand on a un bouton de type "afficher plus d’articles", dans des news ou dans une page de produits pour un site de e-commerce) on va déplacer le focus sur le 1er nouveau élément qui vient de s’afficher (la zone qui a été mise à jour).
-
SOX got nothing from SoundFlower
12 septembre 2016, par xiaoseFor some reason on some comps SoundFlower does not catch audio.
I.e. there are SoundFlower but when I switch input\output to the SoundFlower I cannot get any sound. I have got only not empty file without any sound.Okay, how I try to get the sound...
Just FYI :
$ system_profiler SPSoftwareDataType
Software:
System Software Overview:
System Version: OS X 10.10.5 (14F1912)
Kernel Version: Darwin 14.5.0
Boot Volume: Macintosh HD
Boot Mode: Normal
Computer Name: Craig Computer
User Name: Craig (craigm)
Secure Virtual Memory: Enabled
Time since boot: 1 day22:12Gonna check is AVFoundation works :
$ ./ffmpeg -h demuxer=avfoundation
Demuxer avfoundation [AVFoundation input device]:
AVFoundation input device AVOptions:
-list_devices <int> .D...... list available devices (from 0 to 1) (default false)
true .D......
false .D......
-video_device_index <int> .D...... select video device by index for devices with same name (starts at 0) (from -1 to INT_MAX) (default -1)
-audio_device_index <int> .D...... select audio device by index for devices with same name (starts at 0) (from -1 to INT_MAX) (default -1)
-pixel_format .D...... set pixel format (default yuv420p)
-framerate .D...... set frame rate (default "ntsc")
-video_size .D...... set video size
-capture_cursor <int> .D...... capture the screen cursor (from 0 to 1) (default 0)
-capture_mouse_clicks <int> .D...... capture the screen mouse clicks (from 0 to 1) (default 0)
</int></int></int></int></int>Gonna get list of AVFoundation audio devices :
$ ./ffmpeg -f avfoundation -list_devices true -i ’’
ffmpeg version 3.1.1-tessus Copyright (c) 2000-2016 the FFmpeg developers
built with Apple LLVM version 6.0 (clang-600.0.57) (based on LLVM 3.5svn)
configuration: --cc=/usr/bin/clang --prefix=/opt/ffmpeg --as=yasm --extra-version=tessus --enable-avisynth --enable-fontconfig --enable-gpl --enable-libass --enable-libbluray --enable-libfreetype --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopus --enable-libschroedinger --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzmq --enable-version3 --disable-ffplay --disable-indev=qtkit --disable-indev=x11grab_xcb
libavutil 55. 28.100 / 55. 28.100
libavcodec 57. 48.101 / 57. 48.101
libavformat 57. 41.100 / 57. 41.100
libavdevice 57. 0.101 / 57. 0.101
libavfilter 6. 47.100 / 6. 47.100
libswscale 4. 1.100 / 4. 1.100
libswresample 2. 1.100 / 2. 1.100
libpostproc 54. 0.100 / 54. 0.100
[AVFoundation input device @ 0x7fda40421000] AVFoundation video devices:
[AVFoundation input device @ 0x7fda40421000] [0] Built-in iSight
[AVFoundation input device @ 0x7fda40421000] [1] Capture screen 0
[AVFoundation input device @ 0x7fda40421000] AVFoundation audio devices:
[AVFoundation input device @ 0x7fda40421000] [0] Soundflower (64ch)
[AVFoundation input device @ 0x7fda40421000] [1] Built-in Microphone
[AVFoundation input device @ 0x7fda40421000] [2] Soundflower (2ch)
[AVFoundation input device @ 0x7fda40421000] [3] Built-in Input
: Input/output errorOkay, we have SoundFlower in devices :
[AVFoundation input device @ 0x7fda40421000] [2] Soundflower (2ch)
Then I run AppleScript which gonna switch to the "SoundFlower (2ch)" :
enableSF("input")
enableSF("output")
Where enableSF(stdname) is :
on enableSF(stdname)
tell application "System Preferences"
-- activate
tell anchor stdname of pane "com.apple.preference.sound" to reveal
tell application "System Events"
tell application process "System Preferences"
tell tab group 1 of window 1
delay 2
set rowslist to selected of row of table 1 of scroll area 1
set counter to 0
repeat with id in rowslist
set counter to counter + 1
set rowName to (value of text field 1 of row counter of table 1 of scroll area 1)
set output to stdname & " " & rowName
set scrpt to "echo \"" & output & "\" >> ~/Desktop/ds.log"
do shell script scrpt
if (rowName is equal to "Soundflower (2ch)") then
set selected of row counter of table 1 of scroll area 1 to true
set output to "
!!! FOUND SF for " & stdname & " " & rowName
set scrpt to "echo \"" & output & "\" >> ~/Desktop/ds.log"
log output
do shell script scrpt
exit repeat
end if
end repeat
end tell
end tell
end tell
end tell
end enableSFIn result I have got this :
input Internal Microphone
input Line In
input Digi CoreAudio Device
input Soundflower (2ch)
!!! FOUND SF for input Soundflower (2ch)
output Headphones
output Digi CoreAudio Device
output Soundflower (2ch)
!!! FOUND SF for output Soundflower (2ch)It means that we switch to the SoundFlower. Actually the same can be done by hands, but the script is more reliable as for me.
Okay, next we can try to save some audio via SOX :
$ /Applications/sox-14.3.2/sox -d /Desktop/out.wav
Input File : 'default' (coreaudio)
Channels : 2
Sample Rate : 44100
Precision : 32-bit
Sample Encoding: 32-bit Signed Integer PCM
In:0.00% 00:00:00.00 [00:00:00.00] Out:0 [ | ] Clip:0
...
...
...
In:0.00% 00:00:02.51 [00:00:00.00] Out:106k [ | ] Clip:0
...
...
...
In:0.00% 00:00:11.80 [00:00:00.00] Out:516k [ | ] Clip:0 /Applications/sox-14.3.2/sox WARN coreaudio: coreaudio: unhandled buffer overrun. Data discarded.
...
...
...
In:0.00% 00:00:12.35 [00:00:00.00] Out:545k [ | ] Clip:0 /Applications/sox-14.3.2/sox WARN coreaudio: coreaudio: unhandled buffer overrun. Data discarded.
...
...
...
In:0.00% 00:00:13.28 [00:00:00.00] Out:582k [ | ] Clip:0
Aborted.And, as you can see, the SOX gives me an empty file. Rather, it gives the data, but there is no sound.
This happens on all OS from 10.10 to 10.11.6. Normal output should be this type :
In:0.00% 00:00:00.28 [00:00:00.00] Out:8.19k [======|======] Clip:0
...
...
...
In:0.00% 00:00:04.37 [00:00:00.00] Out:188k [ -====|===== ] Hd:1.1 Clip:0
...
...
...
In:0.00% 00:00:08.82 [00:00:00.00] Out:385k [======|=====-] Hd:1.1 Clip:0
In:0.00% 00:00:09.01 [00:00:00.00] Out:393k [-=====|=====-] Hd:1.1 Clip:0
In:0.00% 00:00:09.20 [00:00:00.00] Out:401k [======|======] Hd:1.1 Clip:0 -
Combine Audio and Images in Stream
19 décembre 2017, par SenorContentoI would like to be able to create images on the fly and also create audio on the fly too and be able to combine them together into an rtmp stream (for Twitch or YouTube). The goal is to accomplish this in Python 3 as that is the language my bot is written in. Bonus points for not having to save to disk.
So far, I have figured out how to stream to rtmp servers using ffmpeg by loading a PNG image and playing it on loop as well as loading a mp3 and then combining them together in the stream. The problem is I have to load at least one of them from file.
I know I can use Moviepy to create videos, but I cannot figure out whether or not I can stream the video from Moviepy to ffmpeg or directly to rtmp. I think that I have to generate a lot of really short clips and send them, but I want to know if there’s an existing solution.
There’s also OpenCV which I hear can stream to rtmp, but cannot handle audio.
A redacted version of an ffmpeg command I have successfully tested with is
ffmpeg -loop 1 -framerate 15 -i ScreenRover.png -i "Song-Stereo.mp3" -c:v libx264 -preset fast -pix_fmt yuv420p -threads 0 -f flv rtmp://SITE-SUCH-AS-TWITCH/.../STREAM-KEY
or
cat Song-Stereo.mp3 | ffmpeg -loop 1 -framerate 15 -i ScreenRover.png -i - -c:v libx264 -preset fast -pix_fmt yuv420p -threads 0 -f flv rtmp://SITE-SUCH-AS-TWITCH/.../STREAM-KEY
I know these commands are not set up properly for smooth streaming, the result manages to screw up both Twitch’s and Youtube’s player and I will have to figure out how to fix that.
The problem with this is I don’t think I can stream both the image and the audio at once when creating them on the spot. I have to load one of them from the hard drive. This becomes a problem when trying to react to a command or user chat or anything else that requires live reactions. I also do not want to destroy my hard drive by constantly saving to it.
As for the python code, what I have tried so far in order to create a video is the following code. This still saves to the HD and is not responsive in realtime, so this is not very useful to me. The video itself is okay, with the one exception that as time passes on, the clock the qr code says versus the video’s clock start to spread apart farther and farther as the video gets closer to the end. I can work around that limitation if it shows up while live streaming.
def make_frame(t):
img = qrcode.make("Hello! The second is %s!" % t)
return numpy.array(img.convert("RGB"))
clip = mpy.VideoClip(make_frame, duration=120)
clip.write_gif("test.gif",fps=15)
gifclip = mpy.VideoFileClip("test.gif")
gifclip.set_duration(120).write_videofile("test.mp4",fps=15)My goal is to be able to produce something along the psuedo-code of
original_video = qrcode_generator("I don't know, a clock, pyotp, today's news sources, just anything that can be generated on the fly!")
original_video.overlay_text(0,0,"This is some sample text, the left two are coordinates, the right three are font, size, and color", Times_New_Roman, 12, Blue)
original_video.add_audio(sine_wave_generator(0,180,2)) # frequency min-max, seconds
# NOTICE - I did not add any time measurements to the actual video itself. The whole point is this is a live stream and not a video clip, so the time frame would be now. The 2 seconds list above is for our psuedo sine wave generator to know how long the audio clip should be, not for the actual streaming library.
stream.send_to_rtmp_server(original_video) # Doesn't matter if ffmpeg or some native libraryThe above example is what I am looking for in terms of video creation in Python and then streaming. I am not trying to create a clip and then stream it later, I am trying to have the program be able to respond to outside events and then update it’s stream to do whatever it wants. It is sort of like a chat bot, but with video instead of text.
def track_movement(...):
...
return ...
original_video = user_submitted_clip(chat.lastVideoMessage)
original_video.overlay_text(0,0,"The robot watches the user's movements and puts a blue square around it.", Times_New_Roman, 12, Blue)
original_video.add_audio(sine_wave_generator(0,180,2)) # frequency min-max, seconds
# It would be awesome if I could also figure out how to perform advance actions such as tracking movements or pulling a face out of a clip and then applying effects to it on the fly. I know OpenCV can track movements and I hear that it can work with streams, but I cannot figure out how that works. Any help would be appreciated! Thanks!Because I forgot to add the imports, here are some useful imports I have in my file !
import pyotp
import qrcode
from io import BytesIO
from moviepy import editor as mpyThe library, pyotp, is for generating one time pad authenticator codes, qrcode is for the qr codes, BytesIO is used for virtual files, and moviepy is what I used to generate the GIF and MP4. I believe BytesIO might be useful for piping data to the streaming service, but how that happens, depends entirely on how data is sent to the service, whether it be ffmpeg over command line (from subprocess import Popen, PIPE) or it be a native library.