Recherche avancée

Médias (0)

Mot : - Tags -/xmlrpc

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (71)

  • MediaSPIP Core : La Configuration

    9 novembre 2010, par

    MediaSPIP Core fournit par défaut trois pages différentes de configuration (ces pages utilisent le plugin de configuration CFG pour fonctionner) : une page spécifique à la configuration générale du squelettes ; une page spécifique à la configuration de la page d’accueil du site ; une page spécifique à la configuration des secteurs ;
    Il fournit également une page supplémentaire qui n’apparait que lorsque certains plugins sont activés permettant de contrôler l’affichage et les fonctionnalités spécifiques (...)

  • Participer à sa traduction

    10 avril 2011

    Vous pouvez nous aider à améliorer les locutions utilisées dans le logiciel ou à traduire celui-ci dans n’importe qu’elle nouvelle langue permettant sa diffusion à de nouvelles communautés linguistiques.
    Pour ce faire, on utilise l’interface de traduction de SPIP où l’ensemble des modules de langue de MediaSPIP sont à disposition. ll vous suffit de vous inscrire sur la liste de discussion des traducteurs pour demander plus d’informations.
    Actuellement MediaSPIP n’est disponible qu’en français et (...)

  • Creating farms of unique websites

    13 avril 2011, par

    MediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
    This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...)

Sur d’autres sites (11356)

  • Install ffmpeg-light with cabal

    20 septembre 2016, par WirflBirfl

    I want to install the ffmpeg-light library from hackage via cabal on Windows 10 (64 bit). So I downloaded ffmpeg and extracted it to C :\FFmpeg.

    At first pkg-config was complaining that it could not find various packages. I solved this problem with .pc files.

    When I tried to use the command : cabal install ffmpeg-light cabal complained about missing C-libraries, being exactly those for which I created the .pc files.

    Then I tried the command : cabal install ffmpeg-light --extra-lib-dirs=C:\FFmpeg\lib. Now I have a different error message, which says :

    Enums.hsc:7:32: fatal error: libavcodec/avcodec.h: No such file or directory

    Edit :
    Then I tried the following command :

    cabal install ffmpeg-light --extra-lib-dirs=C:\FFmpeg\lib \
                              --extra-include-dirs=C:\FFmpeg\include

    Now first the compiler gives some warnings about deprecated functions in ffmpeg and redundant imports in ffmpeg-light, but compiles 11 of 11. But the build is still not successfull.

    In-place registering ffmpeg-light-0.11.1...
    setup-Simple-Cabal-1.22.5.0-x86_64-windows-ghc-7.10.3.exe:
    'C:\Haskell\bin\ghc-pkg.exe' exited with an error:
    ffmpeg-light-0.11.1: Warning: haddock-interfaces:
    C:\Users\HOLEYC~1\AppData\Local\Temp\cabal-tmp-2824\ffmpeg-light-0.11.1\dist\doc\html\ffmpeg-light\ffmpeg-light.haddock
    doesn't exist or isn't a file
    ffmpeg-light-0.11.1: Warning: haddock-html:
    C:\Users\HOLEYC~1\AppData\Local\Temp\cabal-tmp-2824\ffmpeg-light-0.11.1\dist\doc\html\ffmpeg-light
    doesn't exist or isn't a directory
    ffmpeg-light-0.11.1: library-dirs: C:FFmpeglib is a relative path which makes
    no sense (as there is nothing for it to be relative to). You can make paths
    relative to the package database itself by using ${pkgroot}. (use --force to
    override)
    ffmpeg-light-0.11.1: include-dirs: C:FFmpeginclude is a relative path which
    makes no sense (as there is nothing for it to be relative to). You can make
    paths relative to the package database itself by using ${pkgroot}. (use
    --force to override)
    cabal: Error: some packages failed to install:
    ffmpeg-light-0.11.1 failed during the building phase. The exception was:
    ExitFailure 1

    Some additional information :

    cabal version: cabal-install version 1.22.6.0
    using version 1.22.5.0 of the Cabal library
    gcc version of my installed Haskell platform: 5.2.0

    Example .pc file I used for pkg-config :

    Name: libavcodec
    Description: Library for ffmpeg
    Version: 57
    Cflags: -IC:\FFmpeg\include
    Libs: -LC:\FFmpeg\lib -llibavcodec
  • Using openCV library with Java works well on Linux but not on Windows

    6 août 2016, par user3586330

    I have a method that takes screenshots on absolute intervals (25%, 50%, 75% and 100%) from a video-file and save each of them to a separate .png-file. I use openCV with the JavaCV-Wrapper library to do that. The class/method of interest is :

    package de.stal.videoreporter;

    import org.bytedeco.javacpp.opencv_core;
    import static org.bytedeco.javacpp.opencv_imgcodecs.cvSaveImage;
    import org.bytedeco.javacv.FFmpegFrameGrabber;
    import org.bytedeco.javacv.Frame;
    import org.bytedeco.javacv.FrameGrabber;
    import org.bytedeco.javacv.OpenCVFrameConverter;

    class VideoThumbnailer {
    public void createThumbnails(String videoname) throws FrameGrabber.Exception {

       FFmpegFrameGrabber g = new FFmpegFrameGrabber("videos/" + videoname);
       g.start();
       OpenCVFrameConverter.ToIplImage converterToIplImage = new OpenCVFrameConverter.ToIplImage();
       int length = g.getLengthInFrames();
       int fifty = length / 2;
       int twentyfive = fifty / 2;
       int seventyfive = fifty + twentyfive;
       int hundred = length - 1;

       //each frame of video
       for (int j = 0; j < length; j++) {

           if (j == twentyfive || j == fifty || j == seventyfive || j == hundred) {
               String ss = "";
               if (j == twentyfive) {
                   ss = "25";
               } else if (j == fifty) {
                   ss = "50";
               } else if (j == seventyfive) {
                   ss = "75";
               } else if (j == hundred) {
                   ss = "100";
               }

               g.setFrameNumber(j);

               Frame f = g.grabImage();

               opencv_core.IplImage image = converterToIplImage.convert(f);
               String img_path = "thumbnails/" + videoname + "." + ss + ".png";
               cvSaveImage(img_path, image);
           }

       }
       g.stop();
    }
    }

    That works fine on environment : Ubuntu 15.10 x64, Java v.1.7.0_101 and Netbeans 8.0.2 with Maven. So I exported the project to a runnable jar-file(with all dependencies included) and tried to start it on Windows 10 x64 via :

    java -jar VideoReporter-1.0-SNAPSHOT-jar-with-dependencies.jar

    On Windows an exception will be thrown when executing the .jar-file :

    Error putting member offsets for class org/bytedeco/javacpp/avutil$Pool_free_Pointer.
    Exception in thread "main" java.lang.NoClassDefFoundError: Could not initialize class org.bytedeco.javacpp.avutil
       at java.lang.Class.forName0(Native Method)
       at java.lang.Class.forName(Unknown Source)
       at org.bytedeco.javacpp.Loader.load(Loader.java:472)
       at org.bytedeco.javacpp.Loader.load(Loader.java:417)
       at org.bytedeco.javacpp.avformat$AVFormatContext.<clinit>(avformat.java:2719)
       at org.bytedeco.javacv.FFmpegFrameGrabber.startUnsafe(FFmpegFrameGrabber.java:391)
       at org.bytedeco.javacv.FFmpegFrameGrabber.start(FFmpegFrameGrabber.java:385)
       at de.stal.videoreporter.VideoThumbnailer.createThumbnails(VideoThumbnailer.java:15)
       at de.stal.videoreporter.MetaReader.slurpMetadata(MetaReader.java:67)
       at de.stal.videoreporter.VideoReporter.main(VideoReporter.java:19)
    </clinit>

    My pom.xml is :

    &lt;?xml version="1.0" encoding="UTF-8"?>
    <project xmlns="http://maven.apache.org/POM/4.0.0">
    <modelversion>4.0.0</modelversion>
    <groupid>de.stal</groupid>
    <artifactid>VideoReporter</artifactid>
    <version>1.0-SNAPSHOT</version>
    <packaging>jar</packaging>
    <properties>
       UTF-8
       1.7
       1.7
    </properties>
    <build>
       <plugins>
           <plugin>
               <artifactid>maven-assembly-plugin</artifactid>
               <configuration>
                   <archive>
                       <manifest>
                           <mainclass>de.stal.videoreporter.VideoReporter</mainclass>
                       </manifest>
                   </archive>
                   <descriptorrefs>
                       <descriptorref>jar-with-dependencies</descriptorref>
                   </descriptorrefs>
               </configuration>
               <executions>
                   <execution>
                       <id>make-assembly</id>
                       <phase>package</phase>
                       <goals>
                           <goal>single</goal>
                       </goals>
                   </execution>
               </executions>
           </plugin>
       </plugins>
    </build>
    <dependencies>
       <dependency>
           <groupid>org.apache.commons</groupid>
           <artifactid>commons-csv</artifactid>
           <version>1.1</version>
       </dependency>
       <dependency>
           <groupid>org.bytedeco</groupid>
           <artifactid>javacpp</artifactid>
           <version>1.2.1</version>
       </dependency>
       <dependency>
           <groupid>org.bytedeco</groupid>
           <artifactid>javacv</artifactid>
           <version>1.2</version>
       </dependency>
       <dependency>
           <groupid>com.fasterxml.jackson.dataformat</groupid>
           <artifactid>jackson-dataformat-csv</artifactid>
           <version>2.8.0.rc2</version>
       </dependency>
       <dependency>
           <groupid>javassist</groupid>
           <artifactid>javassist</artifactid>
           <version>3.12.1.GA</version>
       </dependency>
       <dependency>
           <groupid>commons-collections</groupid>
           <artifactid>commons-collections</artifactid>
           <version>3.2.1</version>
       </dependency>
       <dependency>
           <groupid>com.opencsv</groupid>
           <artifactid>opencsv</artifactid>
           <version>3.3</version>
       </dependency>
    </dependencies>
    </project>

    What might be the problem on Windows ? In my opinion there shouldn’t be a problem with access to openCV/FFMPEG-classes because they all have been included the .jar-file ? Is this a problem with the classpath ?

    Thanks, Peter

  • How can I run command line FFMPEG and accept multiple pipes (video and audio) without blocking on the first input ?

    18 février 2016, par Version135b

    I’m trying to mux h264 and aac created with MediaCodec using FFMPEG, and also use FFMPEG’s RTMP support to send to youtube. I’ve created two pipes, and am writing from java (android) through WriteableByteChannels. I can send to one pipe just fine (accepting null audio) like this :

    ./ffmpeg -f lavfi -i aevalsrc=0 -i "files/camera-test.h264" -acodec aac -vcodec copy -bufsize 512k -f flv "rtmp://a.rtmp.youtube.com/live2/XXXX"

    YouTube streaming works perfectly (but I have no audio). Using two pipes this is my command :

    ./ffmpeg \
    -i "files/camera-test.h264" \
    -i "files/audio-test.aac" \
    -vcodec copy \
    -acodec copy \
    -map 0:v:0 -map 1:a:0 \
    -f flv "rtmp://a.rtmp.youtube.com/live2/XXXX""

    The pipes are created with mkfifo , and opened from java like this :

    pipeWriterVideo = Channels.newChannel(new FileOutputStream(outputFileVideo.toString()));

    The order of execution (for now in my test phase) is creation of the files, starting ffmpeg (through adb shell) and then starting recording which opens the channels. ffmpeg will immediately open the h264 stream and then wait, since it is reading from the pipe the first channel open (for video) will successfully run. When it comes to trying to open the audio the same way, it fails because ffmpeg has not actually started reading from the pipe. I can open a second terminal window and cat the audio file and my app spits out what i hope is encoded aac, but ffmpeg fails, usually just sitting there waiting. Here is the verbose output :

    ffmpeg version N-78385-g855d9d2 Copyright (c) 2000-2016 the FFmpeg
    developers
     built with gcc 4.8 (GCC)
     configuration: --prefix=/home/dev/svn/android-ffmpeg-with-rtmp/src/ffmpeg/android/arm
       --enable-shared --disable-static --disable-doc --disable-ffplay
       --disable-ffprobe --disable-ffserver --disable-symver
       --cross-prefix=/home/dev/dev/android-ndk-r10e/toolchains/arm-linux-androideabi-4.8/prebuilt/linux-x86_64/bin/arm-linux-androideabi-
       --target-os=linux --arch=arm --enable-cross-compile
       --enable-librtmp --enable-pic --enable-decoder=h264
       --sysroot=/home/dev/dev/android-ndk-r10e/platforms/android-19/arch-arm
       --extra-cflags='-Os -fpic -marm'
       --extra-ldflags='-L/home/dev/svn/android-ffmpeg-with-rtmp/src/openssl-android/libs/armeabi '
       --extra-ldexeflags=-pie --pkg-config=/usr/bin/pkg-config
     libavutil      55. 17.100 / 55. 17.100
     libavcodec     57. 24.102 / 57. 24.102
     libavformat    57. 25.100 / 57. 25.100
     libavdevice    57.  0.101 / 57.  0.101
     libavfilter     6. 31.100 /  6. 31.100
     libswscale      4.  0.100 /  4.  0.100
     libswresample   2.  0.101 /  2.  0.101
    matched as AVOption 'debug' with argument 'verbose'.
    Trailing options were found on the commandline.
    Finished splitting the commandline.
    Parsing a group of options: global .
    Applying option async (audio sync method) with argument 1.
    Successfully parsed a group of options.
    Parsing a group of options: input file files/camera-test.h264.
    Successfully parsed a group of options.
    Opening an input file: files/camera-test.h264.
    [file @ 0xb503b100] Setting default whitelist 'file'

    I think if I could just get ffmpeg to start listening to both pipes, the rest would work out !

    Thanks for your time.

    EDIT :
    I’ve made progress by decoupling the audio pipe connection and encoding, but now as soon as the video stream has been passed it errors on audio. I started a separate thread to create the WriteableByteChannel for audio and it never gets passed the FileOutputStream creation.

    matched as AVOption 'debug' with argument 'verbose'.
    Trailing options were found on the commandline.
    Finished splitting the commandline.
    Parsing a group of options: global .
    Successfully parsed a group of options.
    Parsing a group of options: input file files/camera-test.h264.
    Successfully parsed a group of options.
    Opening an input file: files/camera-test.h264.
    [file @ 0xb503b100] Setting default whitelist 'file'
    [h264 @ 0xb503c400] Format h264 probed with size=2048 and score=51
    [h264 @ 0xb503c400] Before avformat_find_stream_info() pos: 0 bytes read:15719 seeks:0
    [h264 @ 0xb5027400] Current profile doesn't provide more RBSP data in PPS, skipping
    [h264 @ 0xb503c400] max_analyze_duration 5000000 reached at 5000000 microseconds st:0
    [h264 @ 0xb503c400] After avformat_find_stream_info() pos: 545242 bytes read:546928 seeks:0 frames:127
    Input #0, h264, from 'files/camera-test.h264':
     Duration: N/A, bitrate: N/A
       Stream #0:0, 127, 1/1200000: Video: h264 (Baseline), 1 reference frame, yuv420p(left), 854x480 (864x480), 1/50, 25 fps, 25 tbr, 1200k tbn, 50 tbc
    Successfully opened the file.
    Parsing a group of options: input file files/audio-test.aac.
    Applying option vcodec (force video codec ('copy' to copy stream)) with argument copy.
    Successfully parsed a group of options.
    Opening an input file: files/audio-test.aac.
    Unknown decoder 'copy'
    [AVIOContext @ 0xb5054020] Statistics: 546928 bytes read, 0 seeks

    Here is where I attempt to open the audio pipe.

    new Thread(){
        public void run(){
             Log.d("Audio", "pre thread");
             FileOutputStream fs = null;
             try {
                  fs = new FileOutputStream("/data/data/android.com.android.grafika/files/audio-test.aac");
             } catch (FileNotFoundException e) {
                  e.printStackTrace();
             }
             Log.d("Audio", "made fileoutputstream");  //never hits here
             mVideoEncoder.pipeWriterAudio = Channels.newChannel(fs);
             Log.d("Audio", "made it past opening audio pipe");
        }
    }.start();

    Thanks.