
Recherche avancée
Médias (91)
-
Richard Stallman et le logiciel libre
19 octobre 2011, par
Mis à jour : Mai 2013
Langue : français
Type : Texte
-
Stereo master soundtrack
17 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Audio
-
Elephants Dream - Cover of the soundtrack
17 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Image
-
#7 Ambience
16 octobre 2011, par
Mis à jour : Juin 2015
Langue : English
Type : Audio
-
#6 Teaser Music
16 octobre 2011, par
Mis à jour : Février 2013
Langue : English
Type : Audio
-
#5 End Title
16 octobre 2011, par
Mis à jour : Février 2013
Langue : English
Type : Audio
Autres articles (95)
-
Mise à jour de la version 0.1 vers 0.2
24 juin 2013, parExplications des différents changements notables lors du passage de la version 0.1 de MediaSPIP à la version 0.3. Quelles sont les nouveautés
Au niveau des dépendances logicielles Utilisation des dernières versions de FFMpeg (>= v1.2.1) ; Installation des dépendances pour Smush ; Installation de MediaInfo et FFprobe pour la récupération des métadonnées ; On n’utilise plus ffmpeg2theora ; On n’installe plus flvtool2 au profit de flvtool++ ; On n’installe plus ffmpeg-php qui n’est plus maintenu au (...) -
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 (...) -
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 (...)
Sur d’autres sites (12946)
-
Latest FFmpeg fails to create a good MP4 out of JPG file (Windows 10)
30 décembre 2023, par mengrieI am using FFmpeg to create an MP4 file out of several JPG files. The command to accomplish this


ffmpeg.exe ^
-hide_banner -nostats -loglevel error -y ^
-loop 1 -t 6 -i 001.jpg ^
-loop 1 -t 6 -i 002.jpg ^
-loop 1 -t 6 -i 003.jpg ^
-loop 1 -t 6 -i 004.jpg ^
-loop 1 -t 6 -i 005.jpg ^
-loop 1 -t 6 -i 006.jpg ^
-filter_complex ^
"[0:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1,fade=t=out:st=5:d=1[v0]; ^
[1:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1,fade=t=in:st=0:d=1,fade=t=out:st=5:d=1[v1]; ^
[2:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1,fade=t=in:st=0:d=1,fade=t=out:st=5:d=1[v2]; ^
[3:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1,fade=t=in:st=0:d=1,fade=t=out:st=5:d=1[v3]; ^
[4:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1,fade=t=in:st=0:d=1,fade=t=out:st=5:d=1[v4]; ^
[5:v]scale=1920:1080:force_original_aspect_ratio=decrease,pad=1920:1080:(ow-iw)/2:(oh-ih)/2,setsar=1,fade=t=in:st=0:d=1,fade=t=out:st=5:d=1[v5]; ^
[v0][v1][v2][v3][v4][v5]concat=n=6:v=1:a=0,format=yuv420p[v]" -map "[v]" -r 30 006.mp4



Using "ffmpeg version 2022-12-25-git-eeb280f351-full_build-www.gyan.dev Copyright (c) 2000-2022 the FFmpeg developers built with gcc 12.1.0 (Rev2, Built by MSYS2 project)" does the job as expected.


However, yesterdag I downloaded (from gyan.dev - Windows - ffmpeg-git-full.7z) the latest version and upgrade the tool. "ffmpeg version 2023-12-28-git-c1340f3439-full_build-www.gyan.dev Copyright (c) 2000-2023 the FFmpeg developers built with gcc 12.2.0 (Rev10, Built by MSYS2 project)"


Using this version, the MP4 contains only a few JPGs and timing is also messed up, resulting in a useless MP4.


Has something changed or are these parameters causing a new behaviour ?


Thx


In meanwhile I went back to older version


-
FFmpeg batchfile to compress images JPG JPEGs and keep EXIF (metadata)
24 novembre 2023, par esdoublelefI tried searching everywhere for a possible solution but I really can't find it. Hope someone can help me out here.


I have written a batch file to use FFmpeg to compress and sharpen JPGs in a folder.


@ECHO ON
 FOR %%a in (*.jpg) DO (ffmpeg -i "%%a" -q:v 8 -vf unsharp=5:5:1.0:5:5:0.0 "2022 01 22 %%~na".jpg)
PAUSE



The new file comes out smaller in size, but is missing all the EXIF information that the original photo has.


I tried to add in the command
-metadata
but apparently it works for MP4 only. I have an existing solution with ImageMagick but I'm hoping to solve this via FFmpeg.

Or is there a way to integrate exiftool into the batch file ?


Thank you and I really appreciate any help here.


-
memcpy to av_malloc's memory crash
26 octobre 2023, par PeacefulWindyI use the code in x64 windows :


#include<iostream>
#include<memory>
#include<vector>
extern "C"
{
#include <libavcodec></libavcodec>avcodec.h>
#include<libavformat></libavformat>avformat.h>
#include <libavutil></libavutil>imgutils.h>
#include<libswscale></libswscale>swscale.h>
#include<libswresample></libswresample>swresample.h>
}

struct BufferData
{
 uint8_t* ptr;
 size_t size;
 size_t file_size;
};

int main()
{
 auto file=fopen("E:/test.jpg", "rb");
 fseek(file, 0, SEEK_END);
 auto fileSize = ftell(file);
 fseek(file, 0, SEEK_SET);
 auto data = std::vector(fileSize);
 fread(data.data(), sizeof(uint8_t), fileSize, file);
 fclose(file);

 auto test = BufferData();
 test.ptr = data.data();
 test.size = data.size();
 test.file_size = data.size();
 auto buffer = (uint8_t*)av_malloc(4096 * 10);
 char errStr[128] = { 0 };

 auto avformatContext = avformat_alloc_context();
 auto avioContext = avio_alloc_context(buffer, 4096, 0, &test, [](void* opaque, uint8_t* buf, int buf_size)
 {
 BufferData* bd = (BufferData*)opaque;
 auto size = std::min(bd->size, (size_t)buf_size);

 if (!size)
 {
 return -1;
 }

 memcpy(buf, bd->ptr, size);
 bd->ptr += size;
 bd->size -= size;
 return (int)size;
 }, NULL, NULL);
 avformatContext->pb = avioContext;
 avformatContext->flags = AVFMT_FLAG_CUSTOM_IO;

 auto ret = avformat_open_input(&avformatContext, nullptr, nullptr, nullptr);
 if (ret != 0)
 {
 av_strerror(ret, errStr, sizeof(errStr));
 std::cout << errStr << std::endl;
 av_free(buffer);
 avformat_close_input(&avformatContext);
 return 0;
 }

 ret = avformat_find_stream_info(avformatContext, nullptr);
 if (ret < 0)
 {
 av_strerror(ret, errStr, sizeof(errStr));
 std::cout << errStr << std::endl;
 av_free(buffer);
 avformat_close_input(&avformatContext);
 return 0;
 }

 av_dump_format(avformatContext, 0, nullptr, 0);

 auto videoIndex = av_find_best_stream(avformatContext, AVMEDIA_TYPE_VIDEO, -1, -1, nullptr, 0);
 if (videoIndex == AVERROR_STREAM_NOT_FOUND)
 {
 av_free(buffer);
 avformat_close_input(&avformatContext);
 return 0;
 }
 else if (videoIndex == AVERROR_DECODER_NOT_FOUND)
 {
 av_free(buffer);
 avformat_close_input(&avformatContext);
 return 0;
 }

 auto videoCodecPar = avformatContext->streams[videoIndex]->codecpar;
 auto videoCodec = avcodec_find_decoder(videoCodecPar->codec_id);
 if (!videoCodec)
 {
 av_free(buffer);
 avformat_close_input(&avformatContext);
 return 0;
 }

 av_free(buffer);
 avformat_close_input(&avformatContext);
}
</vector></memory></iostream>


I use memcpy to copy data to buffer,it run to av_free(buffer) get crash.
ffmpeg version is 6.0.
Visual Studio version is 2022 with CMake.


Use fread replace memcpy,it can work !But I need to resolve load from std::vector memory,not fread.
I think maybe memory-align problem when run av_free,but I no way to find the cause.