
Recherche avancée
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 (7492)
-
Anomalie #4543 : Accessibilité des chargements ajax (live regions)
4 septembre 2020, par RastaPopoulos ♥Moi j’ai pas participé à ces ajouts hein mais j’essaye de comprendre.
On est d’accord que aria-live=polite, ça fait que lorsque l’utilisateur ne fait rien d’important (le polite), alors ça va relire le morceau qui a été "actualisé en live", s’il a changé ? c’est bien ça ?
Ce que je dis c’est que 99% des utilisations de l’ajax de SPIP, concernent effectivement un cas où l’utilisateurice a cliqué volontairement et s’attend donc à ce que ça lui lise ce qui vient de changer (et c’est bien le bloc parent entier que SPIP recharge, quel est le problème ?).
Si sur le site de cette région, ya pas mal d’ajax qui se recharge "tout seul" sans interaction, possible oui ça va pas du tout, mais ce n’est vraiment pas le plus courant dans l’utilisation classique de SPIP, et il me semblait que vu la proportion, c’était plutôt bien si par défaut ça relisait le bloc rechargé (volontairement par un clic, dans l’immense majorité des cas).
Mais du coup on parle que théoriquement, et sûrement que je pige pas du tout oui… il faudrait plutôt parler sur des cas concrets (genre tel bloc ajax de telle page avec une pagination qu’on clique volontairement et qui recharge alors telle portion de la page).
En tout cas cette utilisation (majoritaire encore une fois) semblait correspondre à la doc de base (sur MozDev par ex) :
Normalement, seul aria-live="polite" est utilisé. Toute zone recevant une mise à jour qu’il est important de faire suivre à l’utilisateur, mais pas au point de le déranger dans sa navigation, devrait recevoir cet attribut. Le lecteur d’écran lira les changements dès que l’utilisateur sera inoccupé.
Si ça reste par défaut, peut-être qu’il faudrait un critère pour ne pas générer ces attributs quand on sait qu’il va s’agir d’un bloc ajax rechargé automatiquement, non volontairement ?
-
Command failed ffmpeg in Lambda function (Node js)
14 février 2019, par ArunI am trying to convert a video file to an audio file inside the lambda function. But I keep getting FFmpeg command failed error. I put FFmpeg binary exe file inside the project directory. but still, I am getting the same error. I tried this ( Lambda not connecting to ffmpeg ) but my issue is not solving yet. Any helps ?? thanks,
Here is my lambda function code
process.env.PATH = process.env.PATH + ':/tmp/';
process.env['FFMPEG_PATH'] = '/tmp/ffmpeg';
const BIN_PATH = process.env['LAMBDA_TASK_ROOT'];
process.env['PATH'] = process.env['PATH'] + ':' + BIN_PATH;
const fs = require('fs');
const AWS = require('aws-sdk');
AWS.config.update({
region : 'us-east-2'
});
const s3 = new AWS.S3({apiVersion: '2006-03-01'});
exports.handler = (event, context, callback) => {
require('child_process').exec(
'cp /var/task/ffmpeg /tmp/.; chmod 755 /tmp/ffmpeg;',
function (error, stdout, stderr) {
if (error) {
console.log('Erro occured',error);
} else {
var ffmpeg = require('ffmpeg');
var params = {
Bucket: "bucket_name",
Key: event.Records[0].s3.object.key
};
s3.getObject(params, function(err, data) {
if (err) {
console.log("Error", err);
}
fs.writeFile("/tmp/vid.mp4", data.Body, function (err) {
if (err) console.log(err.code, "-", err.message);
return callback(err);
}, function() {
try {
var stats = fs.statSync("/tmp/vid.mp4");
console.log("size of the file1 ", stats["size"]);
try {
console.log("Yeah");
var process = new ffmpeg('/tmp/vid.mp4');
process.then(function (video) {
// Callback mode
console.log("video function ", video);
video.fnExtractSoundToMP3('/tmp/video.mp3', function (error, file) {
if (!error)
console.log('Audio file: ' + file);
else console.log('error video ', error);
});
}, function (err) {
console.log('Error: ' + err);
});
} catch (e) {
console.log(e.code);
console.log(e.msg);
}
} catch (e) {
console.log("file is not complete", e);
}
});
return callback(err);
});
}
}
)
}Error message
{ Error: Command failed: ffmpeg -i /tmp/vid.mp4 -vn -ar 44100 -ac 2 -ab 192 -f mp3 /tmp/video.mp3
at ChildProcess.exithandler (child_process.js:275:12)
at emitTwo (events.js:126:13)
at ChildProcess.emit (events.js:214:7)
at maybeClose (internal/child_process.js:925:16)
at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
killed: false,
code: null,
signal: 'SIGSEGV',
cmd: 'ffmpeg -i /tmp/vid.mp4 -vn -ar 44100 -ac 2 -ab 192 -f mp3 /tmp/video.mp3' } -
How to force A/V sync using mkvmerge and external time-codes ?
19 avril 2017, par b..Background
I’m working on a project where video and audio are algorithmic interpretations of an MKV source file where I use ffmpeg -ss and -t to extract a particular region of audio and video to separate files. I use scene changes in the video in the audio process (i.e. the audio changes on video scene change), so sync is crucial.
Audio is 48khz, using 512 sample blocks.
Video is 23.976fps (I also tried 24).I store the frame onset of sceneChanges in a file in terms of cumulative blocks :
blocksPerFrame = (48000 / 512) / 23.976
sceneOnsetBlock = sceneOnsetFrame*blocksPerFrameI use these blocks in my audio code to treat the samples associated with each scene as a group.
When I combine the audio and video back together (currently using ffmpeg to generate mp4(v) mp3(a) in an MKV container), the audio and video start off in sync but increasingly drifts until it ends up being 35 seconds off. The worst part is that the audio lag is nonlinear ! By non-linear, I mean that if I plot the lag against the location of that lag in time, I don’t get a line, but what you see in the image below). I can’t just shift or scale the audio to fit the video because of this nonlinearity. I cannot figure out the cause of this nonlinearly increasing audio delay ; I’ve double and triple checked my math.
Since I know the exact timing of scene changes, I should be able to generate "external timecodes" (from the blocks above) for mkvmerge to perfectly sync the output !
Subquestions :
-
Is this the best approach (beyond trying to figure out what went wrong in the first place) ? As I’m using my video frames as a
reference, if I use the scene changes as timecodes for the audio,
will it force the video to match the audio or vice versa ? I’m much less concerned with the duration than the sync. The video was much more laborious to produce, so I’d rather loose some sound than some frames. -
I’m not clear on what numbers to use in the timecodes file.
According to mkvmerge documentation "For video this is exactly
one frame, for audio this is one packet of the specific audio type."
Since I’m using MP3, what is the packet size ? Ideally, I could specify a packetsize (in the audio-encoder ?) that matches my block size (512) to keep things consistent and simple. Can I do this with ffmpeg ?
Thank you !
-