
Recherche avancée
Autres articles (18)
-
Encoding and processing into web-friendly formats
13 avril 2011, parMediaSPIP automatically converts uploaded files to internet-compatible formats.
Video files are encoded in MP4, Ogv and WebM (supported by HTML5) and MP4 (supported by Flash).
Audio files are encoded in MP3 and Ogg (supported by HTML5) and MP3 (supported by Flash).
Where possible, text is analyzed in order to retrieve the data needed for search engine detection, and then exported as a series of image files.
All uploaded files are stored online in their original format, so you can (...) -
Demande de création d’un canal
12 mars 2010, parEn fonction de la configuration de la plateforme, l’utilisateur peu avoir à sa disposition deux méthodes différentes de demande de création de canal. La première est au moment de son inscription, la seconde, après son inscription en remplissant un formulaire de demande.
Les deux manières demandent les mêmes choses fonctionnent à peu près de la même manière, le futur utilisateur doit remplir une série de champ de formulaire permettant tout d’abord aux administrateurs d’avoir des informations quant à (...) -
Installation en mode ferme
4 février 2011, parLe mode ferme permet d’héberger plusieurs sites de type MediaSPIP en n’installant qu’une seule fois son noyau fonctionnel.
C’est la méthode que nous utilisons sur cette même plateforme.
L’utilisation en mode ferme nécessite de connaïtre un peu le mécanisme de SPIP contrairement à la version standalone qui ne nécessite pas réellement de connaissances spécifique puisque l’espace privé habituel de SPIP n’est plus utilisé.
Dans un premier temps, vous devez avoir installé les mêmes fichiers que l’installation (...)
Sur d’autres sites (4123)
-
Celery to process task and modify the model fields
15 juillet 2015, par RobinI would like to convert video into mp4 using
ffmpeg
andcelery
for the asynchronous task. When user uploads a video, it will be for theoriginal_video
and save it. After that I want celery to convert it into a different version for themp4_720
field. However I am confused on how to apply that logic using celery.app.models.py :
class Video(models.Model):
title = models.CharField(max_length=75)
pubdate = models.DateTimeField(default=timezone.now)
original_video = models.FileField(upload_to=get_upload_file_name)
mp4_720 = models.FileField(upload_to=get_upload_file_name, blank=True, null=True)
converted = models.BooleanField(default=False)app.views.py :
def upload_video(request):
if request.POST:
form = VideoForm(request.POST, request.FILES)
if form.is_valid():
video = form.save(commit=False)
video.save()
// Celery to convert the video
convert_video.delay(video)
return HttpResponseRedirect('/')
else:
form = VideoForm()
return render(request, 'upload_video.html', {
'form':form
})app.tasks.py :
@app.task
def convert_video(video):
// Convert the original video into required format and save it in the mp4_720 field using the following command:
//subprocess.call('ffmpeg -i (path of the original_video) (video for mp4_720)')
// Change the converted boolean field to True
// SaveBasically my question is how to save the converted video in mp4_720. Your help and guidance will be very much appreciated. Thank you.
** update **
What I want that method to do is first convert the video.original_video and then save the converted video in the video.mp4_720 field. If all has been done correctly, change the video.converted to True. How do I define the method to do so ?
-
movtextenc.c : Reorganize the code for easier maintenance
20 juillet 2015, par Niklesh -
How to add watermark to video in Flutter using Flutter_ffmpeg
14 mai 2021, par user433575I cannot figure out why my ffmpeg commands aren't working...


Future<void> watermark(filePath, width, height) async {

final String outPath = 'watermarked.mp4';
final String inputVideo =
 await rootBundle.loadString('assets/ffmpeg/demo.mov');
final String inputWatermark = await rootBundle
 .loadString('assets/ffmpeg/video_overlay.png');
final arguments =
 '-i $inputVideo -i $inputWatermark -filter_complex overlay=10:10 -codec:a copy $outPath';


final int rc = await FlutterFFmpeg().execute(arguments);
assert(rc == 0);
print("outPath $outPath");

uploadFile(outPath, "gallery");
</void>


}


Thanks