Recherche avancée

Médias (1)

Mot : - Tags -/epub

Autres articles (94)

  • Les vidéos

    21 avril 2011, par

    Comme les documents de type "audio", Mediaspip affiche dans la mesure du possible les vidéos grâce à la balise html5 .
    Un des inconvénients de cette balise est qu’elle n’est pas reconnue correctement par certains navigateurs (Internet Explorer pour ne pas le nommer) et que chaque navigateur ne gère en natif que certains formats de vidéos.
    Son avantage principal quant à lui est de bénéficier de la prise en charge native de vidéos dans les navigateur et donc de se passer de l’utilisation de Flash et (...)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-je poster des contenus à partir d’une tablette Ipad ?
    Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir

  • Emballe médias : à quoi cela sert ?

    4 février 2011, par

    Ce plugin vise à gérer des sites de mise en ligne de documents de tous types.
    Il crée des "médias", à savoir : un "média" est un article au sens SPIP créé automatiquement lors du téléversement d’un document qu’il soit audio, vidéo, image ou textuel ; un seul document ne peut être lié à un article dit "média" ;

Sur d’autres sites (7615)

  • Trying to merge two videos from my photo roll with Flutter ffmpeg without success

    4 avril 2023, par Stéphane de Luca

    My goal is to merge too video I pick from my photo roll.
My code starts as follows :

    


    // videos[0] contains: "content://media/external/video/media/2779"
 final v1 = await videos[0].getMediaUrl();
    if (v1 == null) return;
    final v1Path = await LecleFlutterAbsolutePath.getAbsolutePath(uri: v1);


    


    But printing v1Pathgive a path with jpeg extension :
/data/user/0/com.example.shokaze/cache/OutputFile_1669939088711.jpeg' which I though would have bear mp4` as it is a video.

    


    Why is it so ?

    


    Another question I have is how can I make a relevant path so that the ffmpeg video appears in my roll after its creation ? Should I do the following and provide outputPathto the code ?

    


    The command it executes is :
-i /data/user/0/com.example.shokaze/cache/OutputFile_1669940421875.jpeg -i /data/user/0/com.example.shokaze/cache/OutputFile_1669940428723.jpeg -filter_complex '[0:0][1:0]concat=n=2:v=1:a=0[out]' -map '[out]' /data/user/0/com.example.shokaze/app_flutter/output.mp4

    


    And I get an error :
I/flutter (30190): error 1

    


    My code is as follows :

    


        String output = "content://media/external/video/media/output";
    final outputPath = await LecleFlutterAbsolutePath.getAbsolutePath(uri: output);
    if (outputPath == null) return;


    


    The full code is as follows :

    


    // Makes the final video by merging all videos from the mixing table
  void makeFinalVideo() async {
    if (videos.length < 2) return;

    final v1 = await videos[0].getMediaUrl();
    if (v1 == null) return;
    final v1Path = await LecleFlutterAbsolutePath.getAbsolutePath(uri: v1);
    if (v1Path == null) return;
    //String v1 = "";
    final v2 = await videos[1].getMediaUrl();
    if (v2 == null) return;
    final v2Path = await LecleFlutterAbsolutePath.getAbsolutePath(uri: v2);
    if (v2Path == null) return;
    String output = "content://media/external/video/media/output";
    final outputPath = "";
    // await LecleFlutterAbsolutePath.getAbsolutePath(uri: output);
    // if (outputPath == null) return;

    Video.merge(v1Path, v2Path, outputPath);
  }



class Video {
  /// Merges the video [v1] with [v2] as [output] video located in app doc path
  static void merge(String v1, String v2, String output) async {
    final appDocDir = await getApplicationDocumentsDirectory();

    //final appDir = await syspaths.getApplicationDocumentsDirectory();
    String rawDocumentPath = appDocDir.path;
    final outputPath = '$rawDocumentPath/output.mp4';

    final command =
        '-i $v1 -i $v2 -filter_complex \'[0:0][1:0]concat=n=2:v=1:a=0[out]\' -map \'[out]\' $outputPath';
    //await execute(command);
    try {
      final r = await FFmpegKit.execute(command);

      //.then((rc) => print("FFmpeg process exited with rc $rc"));
      print("Result: $r");
    } catch (e) {
      print("Exception: $e");
    }
  }
}


    


  • ffmpeg boxblur filter takes too long

    12 juin 2020, par Prashant_Sarin

    I am using below command to blur a video but it is very slow. Can anyone please help if i can improve the speed somehow.

    



    "ffmpeg -i $inputPath -lavfi [0:v]split=2[original][copy];[copy]scale=ih*16/9:-1,crop=h=iw*9/16,boxblur=luma_radius=50:chroma_radius=25:luma_power=2[blurred];[blurred][original]overlay=(main_w-overlay_w)/2:(main_h-overlay_h)/2[final] -map [final] -map a:0 -g 2 -preset ultrafast $outputPath -y"


    


  • Black overlay appears when merging a transparent video to another video

    13 juin 2012, par RakeshS

    This is what I have done so far :

    Command to create a transparent PNG image :

    convert -size 640x480 -background transparent -fill blue \
    -gravity South label:ROCK image1-0.png

    Command to create a transparent video :

    ffmpeg -loop 1 -f image2 -i image1-0.png -r 20 -vframes 100 \
    -vcodec png -pix_fmt bgra mov-1.mov

    (as per this post) - I expect this video to be a transparent video.

    Command to overlay a video with another :

    ffmpeg -i final-video.mov -sameq -ar 44100 \
    -vf "movie=mov-1.mov [logo];[in][logo] overlay=0:0 [out]" \
    -strict experimental final-video.mov

    Above commands works perfect and I have not faced any problem, but I don't get what I expect which is kinda watermarking effect, I want mov-1.mov to be transparent with final-video.mov.

    Questions :

    1. Is there any way to verify if the generated video is transparent ? other than merging ?
    2. Not sure why the above mov-1.mov is not transparent when it is merged with final-video.mov, any info to solve this problem would be great.

    Please help.