
Recherche avancée
Autres articles (72)
-
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 (...) -
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 ; (...) -
Gestion de la ferme
2 mars 2010, parLa ferme est gérée dans son ensemble par des "super admins".
Certains réglages peuvent être fais afin de réguler les besoins des différents canaux.
Dans un premier temps il utilise le plugin "Gestion de mutualisation"
Sur d’autres sites (11620)
-
Moov atom in android MeidaRecorder recorded data
11 mars 2013, par mmmaaakI have a problem :
I record data from camera using MediaRecorder in my Android app. I save it in socket, not in file. This data's length may be different. At the other side of socket connection, I save it in file. Connection may be interrupted at any unexpected moment. So after android socket disconnection I try to decode received data using ffmpeg. But as I understood, it cant find moov atom in this file. I've read some info about moov, so I think that MediaRecorder puts moov atom in the end of file. But if recording was interrupted, writing moov atom was skipped.
I also have read that for data with unknown length (progressive loading, streaming) it is possible to write moov atom at the begining of the file.
How to write my own moov data into the stream ? May I use MediaRecorder for this ? Or it is neccessary to do it manualy ? How to generate valid moov data ? If anybody has already solved this problem, please give me advice..
-
Save a partial video file locally using NodeJS
25 octobre 2017, par SamiI have a serverless web application that is deployed on
AWS
and I have to take a screenshot from an uploaded video toS3
. I am usingffmpeg
to extract the screenshot but the only drawback is that I have to download the video file first in order to letffmpeg
work with it.
Knowing the fact I am usingAWS Lambda
and I don’t have limits for video length users might upload large files which makesAWS Lambda
to hit the storage limit.
To overcome this I thought of downloading a small chunk of the video and use it withffmpeg
to extract the thumbnail so using theS3.getOjbect
method with range params I was able to download a chunk of the file butffmpeg
couldn’t understand it.
Here is my code :s3.getObject({
Bucket: bucketName,
Key: key,
Range: 'bytes=0-1048576'
}, (err, data) => {
fs.writeFile(fileName, data.Body, error => {
if (error)
console.log(error)
else
console.log('File saved');
})
})And the code to extract the thumbnail :
const ffmpeg = require('fluent-ffmpeg');
new ffmpeg(fileName).screenshots({
timestamps: [0],
filename: 'thumb.png',
folder: '.'
})And I am getting this error from
ffmpeg
Error: ffmpeg exited with code 1: ./test.mp4: Invalid data found when processing input
I know there is a problem in saving the file like this but I couldn’t find any solution that solves my problem. If anybody has one that would be much appreciated.
UPDATE :
It turns out thatffmpeg
does this for me, I just gave it theurl
and it downloaded what it needs to render the screenshot without the need to download the file locally and the code looks like this :const ffmpeg = require('fluent-ffmpeg');
new ffmpeg(url).screenshots({
timestamps: [0],
filename: 'thumb.png',
folder: '.'
}) -
avcodec/mpeg4videodec : Use union to save space
21 mai, par Andreas Rheinhardt